MateVM is i686 (i.e. 32-Bit) only at the moment.
Visit us at
#MateVM on OFTC!
hs-java to parse Java Classfiles in order to get a Java Bytecode
representation. Afterwards we perform a basic-block analysis and generate a
control-flow-graph (CFG). We apply several program-analyses, transformations
and optimizations. Given the annotated CFG we emit native code for a method with
Harpy (i686) in an on demand manner.
At the moment we try to minimize effort, by focusing on essential features of the JVM, for example there is no support for threads yet.
Install GHC via your distro manager. Make sure you install it with shared libaries. On Ubuntu 12.04 LTS that is:
$ sudo apt-get install ghc-dynamic ghc-prof \ cabal-install libzip-dev libgc-dev
For an easy installation of the remaining packages, you can use
PLEASE NOTE: it deletes your
~/.ghc directory first in
order to get a fresh cabal install!
mate executable with (building with
cabal isn't supported yet)
it also builds a simple base library for the Java Runtime, so be sure
There are some working examples in
./tests/, you can execute
one with the given Makefile; assume you want to execute
$ make tests/Fib
or without the Makefile
$ javac tests/Fib.java $ ./mate tests.Fib
you can compare the output with your Java JVM (
java in your
$ make tests/Fib.test
we also have a build bot which
checks for broken cabal dependencies every night, and it also checks the build
Unfortunately, we can't use GNU Classpath yet, but we're working on it, so stay tuned!