Overview Virtual Machine Compilers Downloads

Solutions

Television Handheld Cellphone Networking

Compilation Technologies

There are three different future compilation options for CEE-J. They work by compiling an application's bytecodes into native machine code, dramatically speeding up program execution. The three options have different size, memory and performance characteristics and are appropriate for different target devices.

Ahead-Of-Time (AOT) Compiler

A static compiler compiles classes off the target device. These classes are stored in a linkable file format. When the VM runs on the target device, any pre-compiled classes are loaded. Because the compilation doesn't take place on the target device, more time and memory can be spent on optimizing the generated native code. Unlike with JIT compilation, a device using static compilation does not require additional space or memory to execute.

Skelmir's static compiler is ideal for the resource constrained device, especially in those situations where a large number of classes are known ahead of time.

Dynamic Adaptive (DAR) Recompiler

Skelmir's Dynamic Adaptive Recompiler is similar to a JIT in that it compiles bytecode at runtime. It differs from a JIT in what it compiles, when it decides to compile and how it compiles.

The recompiler is a relatively straightforward bytecode-to-native code translator. It is based on a proprietary architecture from Skelmir that minimizes the time spent compiling and the overall code size the compiler adds to the VM. This architecture also enables the recompiler to be easily ported to new chips.

The recompiler gives performance similar to a traditional JIT, with better performance achieved when more memory is allocated to it.

Just-in-Time (JIT) Compiler

A JIT is a common compilation option for a virtual machine. It works by compiling some or all of a class' methods when the class is loaded. CEE-J's JIT translates a method's bytecodes into native machine code equivalents and optimizes the resulting code. Because the bytecodes are no longer interpreted, a speed increase of 10X can be realized.

JITs increase the size and memory requirements of a VM. The compiler code increases the static footprint of the VM. In addition, the JIT uses memory to compile methods, and these generated methods generally take up more RAM than the original bytecode. On a system with a medium to high amount of resources (i.e. a desktop machine) these additional size and memory requirements are more than justified by the resulting speed increase.

 

»Contact Sales