miracle tool: javap

It has been disturbing me for a very long time that how Java byte-code are executed and the organization of heap/stack in JVM:
Now I have a tutorial over steps towards JVM Internals
Today I will introduce the code dissamble tool: javap, which could be great helpfull when dive into JVM

1
2
3
4
5
6
7
8
9
10
11
12
javap  [options]  [classes]
options:
-v #to print additional information
-l #print line number and local variable tables
-c #dissamble method code as opcode
-s #print internal type signatures
-private -p #print all level of fields and methods
-package #print package/protected/public classes and methods
-protected #print protected/public classes and members
-public #print public classes and members only
-sysinfo #print system information
-constants #print static final constants

In default, -public will be set.
So, if you want to print all information of a .class file, you need to execute:
javap -v -s -p name.class


miracle tool: javap
https://rug.al/2014/2014-01-11-miracle-tool-javap/
Author
Rugal Bernstein
Posted on
January 11, 2014
Licensed under