: A Compilation Framework for Lifelong Program Analysis & Transformation
1 code representation—RISC-like instruction set. Uses . 2 LLVM is complementary to such machines as JVM and not an alternative to them. 3 Only 31 opcodes, most opcodes overloaded. A function is a set of basic blocks, and each basic block is a sequence of LLVM instructions, ending in exactly one terminator instruction (branches, return, unwind, or invoke). Types: void, bool, integers (signed, unsigned, from 8 to 64 bits), 2 floating point, pointers, arrays, structures, functions. All casts are explicit using cast. getelementptr for pointers arithmetic. 4 LLVM provides an explicit, low-level, machine-independent mechanism to implement exception handling in high-level languages. malloc, alloca, and free for memory allocation. call for functions, invoke and unwind for exceptions.
Sergey Vartanov, 2007–2020