Apparently it's possible to see the assembly instructions if you're running
a debug VM [1].

-XX:+PrintOptoAssembly dumps to the console a log of all assembly being
generated for JITed methods. The instructions are basically x86 assembly
with a few Hotspot-specific instruction names that get replaced with
hardware-specific instructions during the final assembly phase. In addition
to the JITed assembly, this flag also shows how registers are being
allocated, the probability of various branches being followed (along with
multiple assembly blocks for the different paths), and information about
calls back into the JVM.

[1] http://blog.headius.com/2009/01/my-favorite-hotspot-jvm-flags.html


2009/7/16 Bradbev <brad.beveri...@gmail.com>

>
> I see lots of discussion on this list about Clojure performance & how
> to get it to Java speed.  I am also interested in the next steps that
> happen, how does the JVM convert byte code down to machine code and
> how does one examine that?
> The profiling tools I use for C code let me look at what the compiler
> has done with my C/C++ code & where the machine is running slow (cache
> misses, pipeline stalls, etc).
> JVM apps obviously have another layer of indirection, the first layer
> is the quality of the byte code that has been generated, and then how
> hotspot compiles that into machine code.
> What tools are out there that let you examine the bytecode & JVM
> machine code output?  It would also be really nice if there were tools
> that told you why the JVM did or did not manage to optimize a block of
> code.
>
> I'm just curious here really, but it does seem like there are many
> knowledgeable people on this list that might be able to offer some
> tips.
>
> Thanks,
> Brad
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to