Hello dear community,
I got an interesting question, just out of my curiosity... reading a book about jRockit I saw examples how java program is transformed and how it looks (java code -> byte code -> HIR -> MIR -> etc), and all the time authors provided real code, or better to say how that code looks at different stages of transformation. I also saw the same examples in internet (like here: http://ssw.jku.at/Research/Papers/Wimmer04Master/Wimmer04Master.pdf - pages 36, 44, ...)
The question is what should I use (either external dumper or JVM parameters) to see the same for my custom code? I heard that it is possible, but I can't find it in the Internet. Again, I'm asking just to understand better what is done by JVM, how it works etc.
thank you for any hints,
The 'javap' utility (type 'javap -help') that comes with Java can disassemble class files. You can also use Java decompilers that you find on the web: JDGUI, JAD and others.
The Java Virtual Machine Specification (e.g. http://java.sun.com/docs/books/jvms/second_edition/html/VMSpecTOC.doc.html) explains the instruction set and structure.