Middle-End: LLVM IR to LLVM IR
After getting an overview of the LLVM infrastructure, this part dives into what comes to most people’s minds when thinking about LLVM: the middle-end and the LLVM intermediate representation (IR).
The middle-end is the backbone of the optimizing compilers based on LLVM. It encompasses an IR that optimizations work on and a set of readily available optimizations and analyses that you can reuse to build your own compiler.
In this part, we focus on four aspects:
- Giving you the tools to understand the LLVM IR and how it maps to a high-level language such as C++. This knowledge will both allow you to better manipulate the IR and give you an idea of how language frontends work.
- Presenting the main optimizations that the LLVM middle-end has to offer.
- Demonstrating how target-specific constructs fit in the middle-end.
- Teaching you how to debug LLVM passes.
By the end of this part, we will have uncovered the...