CACAO is a replacement for the interpreter java of the JDK from SUN. How to invoke CACAO is described in the CACAO manual page.
The beta version of CACAO 0.2b with the new faster JIT and support for multithreading is available for the Alpha processor with Digital Unix. The Linux version will follow very soon. Version 0.1 supports the Alpha processor under Linux and Digital Unix. It can be used with the class library of the JDK 1.0.2. CACAO version 0.1 does not support AWT, it only supports java/lang, java/io and java/util. Class archives in zip format are not supported. CACAO is distributed free of charge. Currently only binary versions are distributed. The source will be available in the future (under GNU licence requirements). The CACAO installation page describes how to download and install CACAO.
CACAO is a research prototype under development. The next version will include a new garbage collector and will support the net library and additional processors (planned for christmas 98). Code generators for the MIPS, PowerPC and Sparc processors are under development. We also started working on the integration of the BISS-AWT libarary. We will increase the speed of the generated code by instruction scheduling and the speed of the compiler by using faster algorithms. It is quite likely that CACAO contains bugs. Please send bug reports to cacao@complang.tuwien.ac.at. If you want to participate in the development of CACAO or have urgent questions send mail to andi@complang.tuwien.ac.at.
To evaluate the performance of CACAO we compared it with Sun's JDK and with kaffe version 0.8 and the newest version of the Digital JIT 1.1.1 of November 6th 1997. We also compared it with two other JavaVM to native code compilers for the SPARC processor:
The benchmark programs and the run time data for Guava and Toba are taken from the Toba homepage. We tested CACAO with exactly the same programs and the same data. JavaLex is a scanner generator, javac is the Java compiler from the JDK compiling the Toba sources, espresso is another Java compiler, Toba is a JavaVM to C compiler and java_cup is a parser generator.
Table 1 gives the run time and for CACAO additionally the load time and the compile time for the benchmarks on a SparcStation 20 and an Alpha workstation with 300MHz 21064a processor. The CACAO system is in nearly all cases faster than Guava and Toba, only where the compile time is high the Toba system is faster.
JavaLex javac espresso Toba java_cup
runtime on SparcStation 20 (in seconds)
JDK 176.3 45.0 24.9 59.8 8.3
GUAVA 80.8 17.8 - 36.8 6.2
TOBA 38.8 12.8 4.9 20.1 2.9
runtime on 21064A 300MHz (in seconds)
JDK 29.8 18.5 8.7 32.1 3.5
Digital Interpr. 98.9 56.4 17.9 - 9.2
Digital JIT 84.4 47.6 14.1 - 9.8
kaffe 9.9 17.8 12.5 - 2.98
CACAO total 2.65 4.74 3.17 4.58 1.52
load 0.18 0.61 0.38 0.18 0.21
compile 0.39 1.21 0.91 0.55 0.81
run 2.08 2.92 1.88 3.85 0.50
number of compiled JavaVM instrucions
13412 34759 27281 14430 17489
speedup with respect to interpreter
speedup JDK/DEC-JIT 0.35 0.38 0.48 - 0.36
speedup JDK/GUAVA 2.18 2.53 - 1.62 1.34
speedup JDK/TOBA 4.54 3.51 5.08 2.98 2.86
speedup JDK/kaffe 3.01 1.04 0.7 - 1.17
speedup JDK/CACAO 11.24 3.90 2.74 7.01 2.30
Table 1
Table 2 compares the CACAO system with a C compiler and the newest version
of the Digital JIT 1.1.1 of November 6th 1997. sieve is the
well known prime number computation program, addition is a loop
with a simple addition and linpack is a floating point intensive
program. The option -cbnf of CACAO disables array bound checks and
precise floating point exceptions. Since C does not do these checks it is
fair to do the comparison without checks. The CACAO system is only a factor
of 1.7 slower than C and up to 7 times faster than kaffe.
runtime on 21064A 300MHz (in seconds)
sieve addition linpack
JDK 83.2 138.76 1.6
Digital interpr. 70.3 124.4 2.0
kaffe 9.14 4.75 0.34
Digital JIT 6.27 5.33 0.9
GCC -O3 2.0 1.40 -
CACAO total 4.80 1.69 0.81
run 4.58 1.42 0.58
CACAO -cbnf total 3.46 1.64 0.33
run 3.31 1.42 0.13
relation of runtime
speedup JDK/kaffe 9.10 11.8 4.7
speedup JDK/DEC-JIT 13.3 29.2 1.7
speedup JDK/CACAO 17.3 82.1 2.0
speedup JDK/CACAO -cbnf 24.1 85.7 4.8
speedup JDK/GCC 41.6 99.1 -
CACAO -cbnf run/GCC 1.66 1.01 -
Table 2