llvm

llvm-project

llvm

The LLVM Project is a collection of modular, reusable compiler and toolchain technologies, including the LLVM core, Clang frontend, LLD linker, libc++ standard library and MLIR.

llvmorg-23.1.4
Published at
8d ago
41,226
Stars
1,511,768
Download
Synced at
15h ago

Latest release

llvmorg-23.1.4Oct 20, 2026, 01:03 PM
Downloads slow? Switch the source anytime above

README

Project Overview

Maintained by the LLVM Foundation community, the LLVM Project is the de facto cornerstone of modern compiler infrastructure — production compilers from Apple, Google and AMD are all built on it. This monorepo holds the source of every subproject: the intermediate representation and optimization core LLVM, the C-family frontend Clang, the C++ standard library libc++, the fast linker LLD, the debugger LLDB, the multi-level IR framework MLIR, the Fortran frontend Flang, the OpenMP runtime and the polyhedral optimizer Polly, among others.

Item Value
Form A collection of compiler and toolchain components (monorepo)
Languages C / C++ / Objective-C / Objective-C++ compiled via Clang
License Apache 2.0 with LLVM exceptions, see LICENSE.TXT
Main dirs llvm / clang / lld / lldb / mlir / flang / libcxx and more
Community Discourse forums, Discord, office hours

Breaking "turning source code into efficient machine code" into reusable modules.

Core Components

  • LLVM core: intermediate representation (bitcode), optimizer and code generation, with an assembler, disassembler and bitcode analysis tools
  • Clang: the C, C++, Objective-C and Objective-C++ frontend that compiles to LLVM bitcode and then object files, known for diagnostics and standards conformance
  • LLD: a fast linker built into LLVM, replacing traditional linkers such as GNU ld
  • libc++ / libc++abi: a high-performance C++ standard library and its runtime
  • LLDB: a debugger sharing expression parsing with Clang
  • MLIR: a multi-level IR foundation for AI compilers and domain-specific DSLs
  • Runtime family: compiler-rt, libunwind, openmp, libc and other execution-environment components

Integration

  • As a toolchain: Clang plus LLD can drop straight into an existing C/C++ build as compiler and linker — cmake -DCMAKE_C_COMPILER=clang is enough to switch
  • As libraries: LLVM ships as a library family; llvm-config --cxxflags --libs prints the flags you need, and ORC JIT can run IR directly in memory
  • As a platform: MLIR custom dialects, Clang plugins and pass plugins are the common third-party extension points

Get and Build

  1. Run git clone https://github.com/llvm/llvm-project (the repo is huge; a shallow clone is recommended)
  2. Build: cmake -G Ninja -S llvm -B build -DCMAKE_BUILD_TYPE=Release && ninja -C build
  3. See the Getting Started and Contributing pages at llvm.org/docs

Use Cases

  • Language and compiler researchers
  • Engineering teams building their own DSLs or AI compilation stacks
  • C/C++ projects pursuing link speed and optimization quality
  • Toolchain distributors and cross-compilation environment maintainers

Requirements

Item Requirement
Build system CMake with Ninja or Make
Language standard C++17
Reference Exact compiler and version requirements are in the official Getting Started guide

Notes

  • The repo is huge: a full clone exceeds 4 GB; prefer --depth 1 or on-demand sparse-checkout
  • Full builds are expensive: building LLVM plus Clang takes tens of minutes to hours; for daily work enable only LLVM_ENABLE_PROJECTS=clang
  • Release cadence: two major releases per year

Release history

Sort