detecting jit compilation

Volker Simonis volker.simonis at
Tue Sep 2 18:36:39 UTC 2014

Depending on your use case you could perhaps use JVMTI and the
JVMTI_EVENT_DYNAMIC_CODE_GENERATED events although the result may be
not what you actually expect because of inlining.You'd also had to do
you own bookkeeping of what was compiled so this is probably not
exactly what you want.

I think in general your question is not so easy to answer because of
inlining. It may be that a certain method was never compiled stand
alone but it may very well have been inlined into several other
methods. So it always depends on the call site.


On Tue, Sep 2, 2014 at 8:12 PM, Deneau, Tom <tom.deneau at> wrote:
> Hi All --
> I was directed to this list for the following question which I asked on the jmh-dev list
>     Is there a way thru Management Beans that I can find out from the Java
>     side whether a particular method has been JIT compiled?
> Aleksey Shipilev mentioned the WhiteBox API which I am not familiar with.  Is this something that can be used today from Java 8?
> -- Tom

More information about the hotspot-dev mailing list