Porting JamVM to the CVMI

As part of working towards a common VM interface, the conversion of JamVM to a new OpenJDK/CVMI interface is being undertaken. This page lists the changes necessary to JamVM (in comparison with current CVS as of Wednesday, June 4th 2008). The repository was converted to Mercurial from CVS to aid the process of creating changesets and hosting the repository.

Why JamVM?

You may ask why we decided to use JamVM for this task. There are two main reasons:

  1. JamVM currently supports only one class library, GNU Classpath, unlike other VMs such as CACAO and JikesRVM (see approaches to adopting the OpenJDK VM interface). This allows cases where the VM implicitly expects GNU Classpath to be more easily recognised and dealt with. The process is hoped then to also be similar to that required to port other GNU Classpath-only VMs such as GCJ.
  2. JamVM is small and simple. The code base totals roughly twenty C files, and, being a C-based interpreter-only VM, the issues raised are likely to be more manageable and make a more easily understandable test case than porting, for example, GCJ, which is an Ahead-Of-Time (AOT) compiler and needs class library support for this. JamVM also uses an external class library, rather than relying on an integrated copy, which makes swapping Classpath for OpenJDK mainly a case of swapping glibj.zip for rt.jar and using OpenJDK's native libraries instead of GNU Classpath's.

Building the Port

Building the port involves using --with-java-runtime-library=openjdk to select the OpenJDK interface, and --with-java-runtime-library-prefix to point to an OpenJDK CVMI J2SDK image.


Below is a list of the patches we've applied to JamVM to support OpenJDK, and why. You can find copies of the patches by following the links on the titles or by using my patch repository.

Valid XHTML 1.1! Valid CSS!