Self-hosting (compilers)
In computer programming, self-hosting is the use of a program as part of the toolchain or operating system that produces new versions of that same program—for example, a compiler that can compile its own source code.[src] Self-hosting software is commonplace on personal computers and larger systems.[src] Other programs that are typically self-hosting include kernels, assemblers, command-line interpreters and revision control software.[src]
In computer programming, self-hosting is the use of a program as part of the toolchain or operating system that produces new versions of that same program—for example, a compiler that can compile its own source code.[src] Self-hosting software is commonplace on personal computers and larger systems.[src] Other programs that are typically self-hosting include kernels, assemblers, command-line interpreters and revision control software.[src] ===Advantages=== Self-hosting a compiler has the following advantages: It is a non-trivial test of the language being compiled, and as such is a form of dogfooding.[src] Compiler developers and bug reporters only need to know the language being compiled.[src] Compiler development can be performed in the higher-level language being compiled.[src] Improvements to the compiler's back-end improve not only general-purpose programs but also the compiler itself.[src] It is a comprehensive consistency check as it should be able to reproduce its own object code.[src] Note that some of these points assume that the language runtime is also written in the same language.[src] ==List of languages having self-hosting compilers== The following programming languages have self-hosting compilers:[src]
13 sentences · 13 cited inline · 0 references stored
References
No reference rows published for this article.
Cite this article
MLA
"Self-hosting (compilers)." encyclopegia.org, 2026, https://encyclopegia.org/wiki/self-hosting-compilers. Accessed 28 November 2026.
Chicago
"Self-hosting (compilers)." encyclopegia.org. Accessed November 28, 2026. https://encyclopegia.org/wiki/self-hosting-compilers.
APA
encyclopegia.org. (2026). Self-hosting (compilers). Retrieved November 28, 2026, from https://encyclopegia.org/wiki/self-hosting-compilers
Accessed November 28, 2026 · CC BY-SA 4.0 · citation page · JSON