Skip to main content

An efficient implementation of a micro virtual machine


Yi Lin

Australia; The Australian National University


Implementing a managed language efficiently is hard, and it is becoming more difficult as the complexity of both language-level design and machines is increasing.

To make things worse, current approaches to language implementations make them prone to inefficiency as well. A high-quality monolithic language implementation demands extensive expertise and resources, but most language implementers do not have those available so their implementations suffer from poor performance. Alternatively, implementers may build on existing frameworks. However, the back-end frameworks often offer abstractions that are mismatched to the language, which either bounces back the complexity to the implementers or results in inefficiency.

Wang et al. proposed micro virtual machines as a solution to address this issue. Micro VMs are explicitly minimal and efficient. Micro VMs support high-performance implementation of managed languages by providing key abstractions, i.e. code exe cution, garbage collection, and concurrency. The abstractions are neutral across client languages, and general and flexible to different implementation strategies. These constraints impose interesting challenges on a micro VM implementation. Prior to this work, no attempt had been made to efficiently implement a micro VM.

My thesis is that key abstractions provided by a micro virtual machine can be implemented efficiently to support client languages.

By exploring the efficient implementation of micro virtual machines, we present a concrete implementation, Zebu VM, which implements the Mu micro VM specification. The thesis addresses three critical designs in Zebu, each mapping to a key abstraction that micro virtual machines provide, and establishes their efficiency:

  1. demonstrating the benefits of utilizing a modern language that focuses on safety to implement a high performance garbage collector,
  2. analysing the design space of yieldpoint mechanism for thread synchronization, and
  3. building a micro compiler under the specific constraints imposed by micro virtual machines, i.e. minimalism, efficiency and flexibility.

This thesis is a proof of concept and an initial proof of performance to establish micro virtual machines as an efficient substrate for managed language implementation. It encourages the approach of building language implementations with micro virtual machines, and reinforces the hope that Mu will be a suitable back-end target.

The thesis discusses the efficient implementation for micro virtual machines, but illustrates broader topics useful in general virtual machine design and construction.

BibTeX Entry

    month            = mar,
    school           = {The Australian National University},
    note             = {Available from publications page at \url{}},
    paperurl         = {},
    author           = {Yi Lin},
    title            = {An Efficient Implementation of a Micro Virtual Machine},
    year             = {2019}