(01-16-2011, 09:13 PM)gid15 Wrote:ok, I had a similar issue with the static recompiler (for pcsp) when I tried to output a big switch code using addresses to execute small basic blocks in every case block. VC2008 and gcc failed to compile the big result. I guess even having small methods may help because JIT would probably inlines them at the end.(01-16-2011, 06:42 PM)hlide Wrote: I guess you have some "Step" methods to call periodically. The longest the compiled block is the slowest responsiveness is. It's kinda logical.
The calls to "Step" methods are left unchanged, it's just that the Java JIT doesn't like to compile large Java methods.
[...]
The java JIT compiler usually decides to compile the smaller methods, resulting in a faster code execution even with the overhead of the additional method calls...
There is probably some threshold in the JIT compiler based on the code size...
I don't know how the details, but if by responsiveness you were spoken about faster loading because of smaller java methods compiling, "responsiveness" was a little abused term ^^.