[Truffle] Loop count propagation
Stefan Marr
java at stefan-marr.de
Thu May 29 14:26:09 UTC 2014
Hi Chris:
On 28 May 2014, at 15:41, Chris Seaton <chris.seaton at oracle.com> wrote:
> On 28 May 2014, at 14:21, Stefan Marr <java at stefan-marr.de> wrote:
>> Pass loop counts up to the first call target for a method that is not a block.
>> https://github.com/jruby/jruby/commit/74934f06299f896170e37cd538c594f6dd27fb35
>
> This change greatly improved warmup time and generated fewer compiled methods. I’ll illustrate using JavaScript, to avoid any confusion about Ruby or SmallTalk syntax and to make it more accessible to other people reading this:
This indeed has a good impact on warmup time for TruffleSOM as well. For DeltaBlue, warmup time was halved, I think. For the rest it might be even better.
https://github.com/SOM-st/TruffleSOM/commit/e1a47e453f8d4e0db06d03f788d74fbe24763743
Just one more question, does the dynamic traversal of the stack in your solution in `reportLoopCountThroughBlocks()` give you additional benefits? I didn’t do it that way, but instead used only the static lexical context.
Also, depending on how the block is used, if there is any kind of helper method in-between on your stack, the loop count won’t reach the outer method, I think.
Best regards
Stefan
--
Stefan Marr
INRIA Lille - Nord Europe
http://stefan-marr.de/research/
More information about the graal-dev
mailing list