Vajra is a Java Virtual Machine for GNU/Linux (Intel x86) written in C++. It is a 'toy' JVM, in the sense that it is not meant for production use (and is, in fact, no way suited for this). The emphasis here is more on implementing the JVM Specifications in as explicit and easily understood a manner as possible. Therefore, speed considerations did not play a part in the design. Also, the following are some of the present limitations:

  1. Garbage collection is yet to be implemented.
  2. Native methods can take a maximum of 10 parameters (excluding JNIEnv* and jobject).
  3. Though the code is meant to handle multi-threading, this has not yet been tested.
  4. Verification of class files is yet to be implemented.
Vajra was initially developed in the Win32 environment. The code has not been tested in Win32 after porting it to GNU/Linux, but I don't think there will be any issues with this.

Vajra uses Classpath for the platform API implementation.

Acknowledgements

I would like to express my thanks to Arun Sharma for the ziplib utility used for extracting classes from JAR files.

Thanks are also due to the following people for their help and guidance:

    David Hopwood

    Chris Smith

    Steven Buytaert

    Gordon Beaton

Click here to download the latest sources for building Vajra.

Notes
  1. The Win32 version was compiled using Borland C++ Builder 6. gcc 4.0 is being used for the GNU/Linux port.
  2. Vajra is a work-in-progress.The sources will be updated as new features are added and bugs are fixed. Vajra has so far been tested with some simple classes. Code coverage is still only partial. Please bear with me for this.
  3. Please email me at "jrajesh at touchtelindia dot net" for any questions or comments.