Amazon.com
If you're writing a Java bytecode interpreter--or a compiler that generates binary files for such an interpreter--The Java Virtual Machine Specification has the information you need. It's the definitive document on Java compilers and runtime environments.
The first part of The Java Virtual Machine Specification discusses the relationships among Java program elements like objects, variables, data types, arrays, exceptions and threads, and compile and run time. Implementers of Java compilers and interpreters need to understand this stuff, but it also makes fascinating reading for Java programmers--it'll help with writing more efficient applications.
From there, the authors dig into the binary .class file format. They provide information on creating such a file as output from a Java compiler, and also give lots of data on how a Java interpreter should examine a .class file to verify its validity and trustworthiness. The authors explain how to carry out loading and linking operations on the objects a .class file defines.
The latter half of The Java Virtual Machine Specification is pure reference--it's a list of all Java opcodes, their purposes, formats, and accepted operands. There's also information about the exceptions each opcode can throw during compilation and execution.
Helpfully, the authors provide a peek at how Sun's Java compiler (javac) and Java interpreter (java) work, complete with source code. These examples promise to provide developers with hints as they implement their own compilers and runtime environments. --David Wall/p>
Reviews From AMAZON.COM
pretty bad
the authors simply don't know how to present their stuff in an orderly fashion. looks like a rushed job.
go look at John Gough's "Compiling for the .NET Common Language Runtime", which treats a similar topic, and you see the difference. or if you prefer a formal style, look at "Java and the Java Virtual Machine: Definition, Verification, Validation".
Know Thy JVM
the pace is a little stilted, and the plot is quite worn-out, but I love the wildly surrealistic sections...

ISBN:0201432943