BEAMJIT: Exploration and Implementation of JIT (Just In Time) Compilation for Erlang

Every cool VM-based language seems to have a just-in-time compiler. With the availability of a powerful compiler infrastructure in the form of LLVM, Erlang is close to getting a just-in-time compiler of its own. Using LLVM together with automated source-to-source transformations it is possible to generate a JIT-capable Erlang VM which automatically stays in sync with the basic VM.

SICS is developing a prototype of a just-in-time compiling Erlang runtime which uses the LLVM just-in-time compilation framework. A non-exhaustive list of research questions (as they apply to Erlang) we explore as part of this development are: Automatic extraction of byte-code semantics from an interpreter implementation for the
synthesizing a JIT code generator; Strategies for selecting code sequences which are candidates for just-in-time-compilation; At what granularity the code-generation should be performed, i.e. per instruction, per clause, per function or per module; Whether just-in-time compilation can simplify tracing and hot code update; Whether idle (or less loaded) processor cores of a multi-core system can be exploited to mask the overhead of just-in-time compilation.