JVM : Java Glossary

*0-9ABCDEFGHIJKLMNOPQRSTUVWXYZ (all)

JVM
JVM (Java Virtual Machine). The specification is available
or by
.

The machine code for an ideal Java CPU (Central Processing Unit). Sun is working on silicon CPU for this set of op-codes. The multi-platform universal *.class files are the machine code for such an ideal machine due out in 1997. Mitsubishi has also announced one. JVMs (Java Virtual Machines) can be interpreters, JITS, Hotspots or native code. See compiler for details. It is possible to write code for the JVM more or less directly with a JVM assembler. JVM also refers to the platform-specific program that can interpret JVM byte codes and execute them.

The JVM could be thought of as just the java.exe program, a part of the JRE and JDK distributions.

I know of only four books that cover the JVM and the binary codes, the classfile format etc.

book cover recommend book⇒The Java Virtual Machineto book home
by Joshua Engel 978-1-56592-194-8 paperback
publisher O’Reilly recommended
published 1997-04
Known known as the goldfish bowl book because of its cover. The book is frustrating because it spends so much time with the irrelevant Jasmin assembler and its syntax. You are interested in generating byte codes directly, not assembler. It leaves out much you must discover by experiment looking at generated class files, such as whether offsets are signed or absolute, where the base is etc. In its next revision, it should set the Jasmin aside in an appendix, and include examples and more precise documentation on the binary formats. The book is still valuable because it gives a fair bit of background exposition you will not find in the vmspec itself. You would use this book to understand the VM, then the vmspec to actually write code that generated or modified class files. Out of print. You might want to read 9780201432947 Java(TM) Virtual Machine Specification, The second edition or the version for Java 7 online instead.
Australian flag abe books anz abe books.co.uk UK flag
Chinese flag amazon.cn amazon.co.uk UK flag
German flag abe books.de abe books.ca Canadian flag
German flag amazon.de amazon.ca Canadian flag
Spanish flag amazon.es Chapters Indigo Canadian flag
Spanish flag iberlibro.com abe books.com American flag
French flag abe books.fr amazon.com American flag
French flag amazon.fr Barnes & Noble American flag
Italian flag abe books.it Google play American flag
Italian flag amazon.it O’Reilly Safari American flag
India flag junglee.com Powells American flag
UN flag Kobo other stores UN flag
Greyed out stores probably do not have the item in stock. Try looking for it with a bookfinder.
book cover recommend book⇒Programming For The Java Virtual Machineto book home
by Joshua Engel 978-0-201-30972-0 paperback
publisher Addison-Wesley
published 1999-07-02
From the reviews it looks like it too gets hung up on a proprietary assembler called Oolong. He does provide a code-generating class and spends one chapter on using it. I think the book would have been more useful if all the examples were in code-generator code, rather than an obscure dialect of assembler.
Australian flag abe books anz abe books.co.uk UK flag
Chinese flag amazon.cn amazon.co.uk UK flag
German flag abe books.de abe books.ca Canadian flag
German flag amazon.de amazon.ca Canadian flag
Spanish flag amazon.es Chapters Indigo Canadian flag
Spanish flag iberlibro.com abe books.com American flag
French flag abe books.fr amazon.com American flag
French flag amazon.fr Barnes & Noble American flag
Italian flag abe books.it Google play American flag
Italian flag amazon.it O’Reilly Safari American flag
India flag junglee.com Powells American flag
UN flag Kobo other stores UN flag
Greyed out stores probably do not have the item in stock. Try looking for it with a bookfinder.
book cover recommend book⇒Java(TM) Virtual Machine Specification, The second editionto book home
by Tim Lindholm and Frank Yellin 978-0-201-43294-7 paperback
publisher Prentice Hall
published 1999-04-24
Make sure you get the second edition. This book has an unusual copyright notice. You might want to read a different book if you plan to write a clean-room JVM. Read the version for Java 7 online.
Australian flag abe books anz abe books.co.uk UK flag
Chinese flag amazon.cn amazon.co.uk UK flag
German flag abe books.de abe books.ca Canadian flag
German flag amazon.de amazon.ca Canadian flag
Spanish flag amazon.es Chapters Indigo Canadian flag
Spanish flag iberlibro.com abe books.com American flag
French flag abe books.fr amazon.com American flag
French flag amazon.fr Barnes & Noble American flag
Italian flag abe books.it Google play American flag
Italian flag amazon.it O’Reilly Safari American flag
India flag junglee.com Powells American flag
UN flag Kobo other stores UN flag
Greyed out stores probably do not have the item in stock. Try looking for it with a bookfinder.
book cover recommend book⇒Inside The Java Virtual Machineto book home
by Bill Venners 978-0-07-135093-8 paperback
publisher McGraw-Hill
published 2000-01-06
Covers Java 2 JVM internals.
ISBN of first edition was 0-07-913248-0.
See the blurb.
Australian flag abe books anz abe books.co.uk UK flag
Chinese flag amazon.cn amazon.co.uk UK flag
German flag abe books.de abe books.ca Canadian flag
German flag amazon.de amazon.ca Canadian flag
Spanish flag amazon.es Chapters Indigo Canadian flag
Spanish flag iberlibro.com abe books.com American flag
French flag abe books.fr amazon.com American flag
French flag amazon.fr Barnes & Noble American flag
Italian flag abe books.it Google play American flag
Italian flag amazon.it O’Reilly Safari American flag
India flag junglee.com Powells American flag
UN flag Kobo other stores UN flag
Greyed out stores probably do not have the item in stock. Try looking for it with a bookfinder.
You can view the Oracle’s Java Virtual Machine Specification:
or you can

There are about 60 compilers that convert languages other than Java to JVM byte codes. They include: Tcl, BASIC, Scheme, Eiffel, COBOL, Ada, Python and Forth, as well as others less well known such as Pizza and Fiji. Robert Tolksdorf complied the list.

The standard JVM can only run one program at a time. However Echidna lets you run many. It is a set of pure Java classes that will work with any JVM.

Roughly speaking, here is how a JVM works: the JVM has a heap that is managed by an automatic a garbage collector. On it are class objects, hunks of code (either in byte code format or natively compiled), ordinary objects and thread stacks. Each thread has its own 32-bit stack, typically about 1 MB of virtual RAM (Random Access Memory) (quite a bit more overhead that most people would expect from a thread). The stack is broken into frames, once for each level of procedure call. A method can only see its frame, not those of its calling ancestors. The frame contains the parms passed to the method. Local references, local primitives and workspace are also stored on the stack.

The heap is typically broken into subheaps with various categories of objects collected together by size, age, class etc. For example, stack frames might typically be collected together since they are all the same length, and all large. This makes finding a suitable sized free slot faster, and avoids fragmentation. It also allows garbage collection to proceed incrementally on just one subheap at a time, rather than stopping everything to collect the entire heap.

If you want to peek under the covers and see in detail how the JVM works, you are out of luck. Sun does not disclose that. However. there are some other JVM implementations. The Kaffe VM is open source. There is Japhar, LGPLd, and Electrical Fire, which is a part of Mozilla.

Learning More



This page is posted
on the web at:

http://mindprod.com/jgloss/jvm.html

Optional Replicator mirror
of mindprod.com
on local hard disk J:

J:\mindprod\jgloss\jvm.html
logo
Please the feedback from other visitors, or your own feedback about the site.
Contact Roedy. Please feel free to link to this page without explicit permission.
Blog
IP:[65.110.21.43]
Your face IP:[54.91.120.148]
You are visitor number