Hotspot VM client compiler - are profile driven opt done?
wimmer at ssw.jku.at
Fri May 30 02:32:57 PDT 2008
> I would like to know if there are any "profile driven optimizations"
No, the client compiler does not use profile data (only the server
> That is, will the compiled code for the threshold of 1500 (or better)
> be different than
> the compiled code for the threshold of say 10 ?
Most likely, the code will be the same. You only have to be aware that
class loading and class initialization is done lazily when bytecodes are
executed the first time. So when e.g. a method call was never executed
in the interpreter, the class could still be unloaded and the compiler
must generated complex patching code and cannot inline the method.
Therefore, setting the threshold to 0 will certainly make a difference.
When you reduce the threshold to 10, you will see that the number of
methods that are compiled explodes (use -XX:+PrintCompilation).
More information about the hotspot-dev