Re: thinking about proper implementation of tail calls

2012-09-02 Thread Mark Roos
So then the issue is making the methods small enough for HotSpot to compile and not fall back to the interpreter. If that is the case why not find the means to have Hotspot not do that? It seems that would be less effort than adding hard tail calls to the jvm. In other words is this really the t

Re: thinking about proper implementation of tail calls

2012-09-02 Thread BGB
On 9/1/2012 6:30 PM, Mark Roos wrote: I am looking to learn something here that I haven't seen in my code yet. John mentioned Suppose you are compiling your favorite high-level language to the JVM, and you start running into the various size limits in class files To which ther

Re: thinking about proper implementation of tail calls

2012-09-02 Thread Charles Oliver Nutter
The classfile limit is only part of the problem. In JRuby we frequently have larger Ruby methods fall over in the compilation process because Hotspot bails out on the whole thing. If we could easily break it up, we would at least get things to compile, even if they needed a CALL here and there to s