The Great Startup Problem

Thomas Wuerthinger thomas.wuerthinger at oracle.com
Mon Aug 25 14:38:20 UTC 2014


Charlie,

Truffle is such a general-purpose automatic specialization mechanism that works like you say via just writing Java code and without a need to use invokedynamic and without a need to dynamically generate bytecodes.

- thomas

On 25 Aug 2014, at 15:25, Charles Oliver Nutter <headius at headius.com> wrote:

> On Mon, Aug 25, 2014 at 6:59 AM, Fredrik Öhrström <oehrstroem at gmail.com> wrote:
>> Calle Wilund and I implemented such a indy/methodhandle solution for
>> JRockit, so I know it works. You can see a demonstration here:
>> http://medianetwork.oracle.com/video/player/589206011001 That
>> implementations jump to C-code that performed the invoke call, no fancy
>> optimizations. Though the interpreter implementation of invoke can be
>> optimized as well, that was the first half of the talk is about. But its
>> really not that important for speed, because the speed comes from inlining
>> the invoke call chain as early as possible after detecting that an indy is
>> hot.
> 
> But can it work in C2? :-)
> 
> My impression of C2 is that specialization isn't in the list of things
> it does well. If we had a general-purpose specialization mechanism in
> Hotspot, things would definitely be a *lot* easier. We might not even
> need indy...just write Java code that does all your MH translations
> and specialize it to the caller's call site.
> 
> We can certainly get C2 to do these things for us...by generating a
> crapload of mostly-redundant bytecode. Oh wait...
> 
> - Charlie
> _______________________________________________
> mlvm-dev mailing list
> mlvm-dev at openjdk.java.net
> http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev



More information about the mlvm-dev mailing list