>
>
>
>> You aren't going to get the ideal degree of inlining, but with virtual
>> functions you wouldn't get that in any case.
>>
>
> Why are virtual functions somehow a limit? Today's JVM and CLR can inline
> across virtual functions using polymorphic inline caching ala Hotspot/SELF.
> (aka, optimistic type-test and inlined code, with a fallback to the slow
> virtual function case) AFAIK, because of the optimistic type-test, this
> technique can be used the same way in AOT as in JIT, because if the inline
> type-test fails it just falls back to the actual virtual method call. It's
> just harder to figure out the actual types that appear via static analysis,
> so that typically needs some type of runtime profiling.
>
>

This is one of the biggest benefits of JIT but it shows up in real programs
 not micro benches . I think on the CLR it was measured at 7% for some real
apps.  Note mono doesnt do this so thats CLR on windows only.
_______________________________________________
bitc-dev mailing list
[email protected]
http://www.coyotos.org/mailman/listinfo/bitc-dev

Reply via email to