On 12/02/2011 04:46 PM, Xinok wrote:
Reading through the 'Java > Scala' thread, I've realized there are some
benefits to dynamic code generation vs statically compiled code. Things
like unrolling loops, devirtualizing functions, etc.

So it made me wonder, could D benefit from such technology, not from a
feature standpoint, but strictly optimization? I'm not familiar with the
topic, but I imagine there could be a few situations that would benefit
in terms of performance, as long as it doesn't affect interoperability.

There could be cases where it helps somewhat. I don't expect that the benefit in comparison to normal compilation to native code would be very high, because

 - You already got native code.
- The optimizer might have used some advanced dynamic instrumentation, leading to similar performance effects as the use of a tracing JIT optimizer, if the typical tasks stay roughly the same.

Actually getting it to work for comparison certainly would be an interesting experiment though.

Reply via email to