what is llvm

11 months ago 28
Nature

LLVM is a set of compiler and toolchain technologies that can be used to develop a frontend for any programming language and a backend for any instruction set architecture. LLVM stands for Low Level Virtual Machine, but the project has expanded and the name is no longer officially an initialism. LLVM is written in C++ and is designed for compile-time, link-time, runtime, and "idle-time" optimization. LLVM is a library used to construct, optimize, and produce intermediate and/or binary machine code. It is a compiler infrastructure designed for compile-time, link-time, run-time, and "idle-time" optimization of programs written in arbitrary programming languages. LLVM provides tools for automating many of the most thankless parts of creating a new language, such as developing a compiler, porting the outputted code to multiple platforms and architectures, generating architecture-specific optimizations such as vectorization, and writing code to handle common language metaphors like exceptions. LLVM is used to produce compilers for many general-purpose languages, but it’s also useful for producing languages that are highly vertical or exclusive to a problem domain. The primary sub-projects of LLVM are the LLVM Core libraries, Clang, and LLDB. LLVM is used to build and optimize compilers, and it helps build new computer languages and improve existing languages. LLVM is different from GCC in that GCC supports a number of programming languages while LLVM isn’t a compiler for any given language. LLVM is a framework to generate object code from any kind of input language.