Machine Language File Format


Machine language program files (with a file extension of "ijvm") can be loaded into memory. Machine language program files have the same format as that used by Ray Ontko and Dan Stone for their simulator. The file is a file of bytes. The first four bytes serve as a header to identify the file as an "ijvm" format machine language program. Treated as a 32-bit integer, this header has the hexadecimal value, 0x1DEADFAD. The high-order byte of the header is the first byte in the file. The rest of the file consists of two blocks: the constant pool contents and the executable instructions. Each block has the following format:

While the file format includes the byte addresses for the constant pool and for the executable code, for all practical purposes they are constants since the Ontko/Stone assembler generates the same addresses for all machine language programs. To simplify things just a little, this simulator ignores the CPP and executable code addresses present in the machine language file and always loads the constant pool at word address 0x3000 and the executable code at byte address 0x0.