Figure 1 - uploaded by Stephen T. Gilmore
Content may be subject to copyright.
The Java Virtual Machine Environment  

The Java Virtual Machine Environment  

Source publication
Article
Full-text available
This thesis describes the MLJVM, a Java Virtual Machine written in the impure functional language Standard ML. Being the first of its kind in this functional approach, my thesis provides not only a detailed description of the implementation of the MLJVM, but also some insight into the pros and cons of a functional JVM.

Contexts in source publication

Context 1
... Parser.parseTypes) Figure 10 shows the part of Parser.sig containing these parser types. ...
Context 2
... basic datatype Int32.int however, has remained constructor function called Int32.fromBytes makes sure this vector always has length 4. To have a range of both positive and negative integers, Int32.sml has adopted the scale shown in Figure 11. ...
Context 3
... addition function itself is not extremely complicated. One simply folds an addition function with carry over the bytevector ( Figure 12). The subtract function first flips the sign of its second argument and then adds it to the first. ...
Context 4
... a transformer for producing the MLJVM's run-time representation of a class (Transform.file2run) Figure 13 shows the part of Transform.sig containing these two transformer types. ...
Context 5
... RuntimePool.sml which allow for this swift information retrieval to take place: ¢ a constant pool designed to facilitate efficient information retrieval ¢ a combined lookup-hash and data-array for fields, methods and classes ¢ a pre-defined attribute-array for fast attribute retrieval Figure 17 shows the type of the combined lookup hashes and data arrays for fields, methods and classes (method area). Each record consists of an array part and a hash part. ...
Context 6
... the hash's find-call will provide an integer which, if used as an index into the array, will reveal the actual data. See Figure 14 and Figure 15 for a graphical representation of lookup-by-name and lookup-by-index. ...
Context 7
... the hash's find-call will provide an integer which, if used as an index into the array, will reveal the actual data. See Figure 14 and Figure 15 for a graphical representation of lookup-by-name and lookup-by-index. ...
Context 8
... Figure 16 for an overview of all attributes and their positions. ...
Context 9
... the format of the output of the pretty printer, we chose Jasmin because it provides a readable way of representing class files and can be re-assembled into a binary class file. Figure 18 shows the input of pretty print to be MyClassFile.class file, which we re- member to be the output of Parser.parse. ...
Context 10
... illustration of this design is shown in Figure 19. ...
Context 11
... since the object area will be represented by an array, we will also need a placeholder to occupy those spaces in the object area that have not been claimed yet. The complete object datatype with all three constructors and the placeholder is shown in Figure 21. The figure also shows all the other parts of the heap datatype. ...
Context 12
... making sure the requested class is available in the MLJVM's method area, the first of these two -the new instruction -has to create an object in the heap and push a reference to this object onto the current frame stack. For this purpose, the heap keeps track of a counter which holds an index into the intermediate area of the object to be created next (see also Figure 21). The first thing the MLJVM will do is extract the value of this counter and push it onto the frame stack as a reference to the object it is about to create. ...
Context 13
... fields and methods all have attributes and therefore an attribute array. We saw in Sec- tion 3.6 and Figure 16 that each attribute has a pre-defined place in this attribute array. However, some attributes only occur in the attribute arrays of methods (e.g. ...
Context 14
... example of a negative branching instruction is given in Figure 31. Note that the output ...