What is Compiler Bootstrapping?

Compiler bootstrapping is the process of writing a compiler for a programming language in that same language. A language whose compiler can compile itself is called self-hosting.

How Bootstrapping Works

To bootstrap a compiler, you first write a simple initial compiler (called a "stage 0" or "seed" compiler) in an existing language. This compiler may not support all language features. Then you use it to compile a richer compiler written in the new language itself.

The process typically follows these stages:

Why Bootstrap?

Self-hosting is a meaningful milestone because it proves the language is expressive enough to implement a real-world systems program. It also means the compiler can be improved using the language's own features.

Examples from the Dataset

Languages in the Language Lineage dataset with documented bootstrap chains include Rust, Go, Haskell, OCaml, and many others. See all bootstrap relationships for the complete list.

Explore Bootstrap Chains in Graph →