2 ms·
> An "offline" compiler can't use things like the type information gathered at runtime. This isn't true. At run-time you only need to pay the cost of dispatchi
by geocar 10y ago
> An "offline" compiler can't use things like the type information gathered at runtime.
This isn't true. At run-time you only need to pay the cost of dispatching once per (type of) input variable.
C++-style templates are popular enough that this concept should be readily understood by now: You pay with heavy compile times (IIRC Crystal takes almost a GB of ram to compile its compiler).
> Benchmarks should be provided before making performance claims!
Yes, absolutely. And reproducible.
- munificent 10y ago> At run-time you only need to pay the cost of dispatching once per (type of) input variable. That also means you can't inline (potentially) polymorphic calls. Inlining is the great big hammer when it comes to optimization.