Trace-based compilation and method-based compilation are two major compilation strategies in JIT compilers. In general, the former excels in compiling programs with more in-depth method calls and more dynamic branches, while the latter is a suitable wide range of applications.
This project aims at developing a fundamental mechanism for compiling with both trace-based and method-based strategies. Instead of developing a compiler for one particular language, we provide such a mechanism in a meta-compilation framework that generates a virtual machine with a JIT compiler from an interpreter definition of a programming language.
We are developing the BacCamel meta-compiler framework as a proof-of-concept, which is based on the MinCaml compiler.
- Linux operating system
- OCaml >= 4.10.0+32bit
To set up BacCaml, plese follow these instructions:
$ opam switch create 4.10.0+32bit
$ opam install -y ppx_deriving ppx_inline_test
Next, write your own interpreter with BacCaml. For reference, please see the implementation of the PMinCaml language.
If you cite this work, please use the DLS'20 paper on "Amalgamating Different JIT Compilations in a Meta-tracing JIT Compiler Framework"