An educational compiler built from scratch in C++.
This project adopts the bottom-up approach, starting from the ELF object file and ARM64 assembly, then working our way up to the source language.
This project follows along with the blog series:
- BCFS: Building Compiler From Scratch, The Beginning
- BCFS: Object File Generation and the ELF Format Part I
- BCFS: Object File Generation and the ELF Format Part II
cd ch1.1
makeThis will:
- Compile to
genfrommain_hello.cppandobj_writer.cpp - Run
./gento generatehello.o
gcc -o hello hello.o
./helloExpected output:
hello world
make clean