←back to thread

185 points chhum | 1 comments | | HN request time: 0.207s | source
1. lysace ◴[] No.44010796[source]
The JVM was the first VM I got to know, at uni in like 1996 or so. Had fun building stuff using the Jasmin "assembler". Seems like it's on Github now: https://github.com/davidar/jasmin

> Jasmin was written because, at the time that we wrote the Java Virtual Machine book for O'Reilly, Sun had not published an assembler format for the Java virtual machine.

> Generating a binary Java .class file is pretty fiddly. Its like creating an a.out (or .exe) file by hand. Even using a Java package like JAS (a Java API for creating class files, used internally by Jasmin and written by KB Sriram), you need to know a lot about the philosophy of the Java Virtual Machine before you can write something at the Virtual Machine level and generate a Java class.

> We wanted something that made it very easy for a student or programmer to explore the Java Virtual Machine, or write a new language which targets the VM, without getting into the details of constant pool indices, attribute tables, and so on.