Summary
In this chapter, you learned how to develop a JIT compiler. You began with possible applications of JIT compilers, and you explored lli
, the LLVM dynamic compiler and interpreter. Using the predefined LLJIT
class, you built a tool similar to lli
on your own. To be able to take advantage of the layered structure of the ORC API, you implemented an optimizing JIT
class. Having acquired all this knowledge, you explored the possibility of using a JIT compiler inside a static compiler, a feature from which some languages can benefit.
In the next chapter, you will examine how to add a backend for a new CPU architecture to LLVM.