8086 Virtual Machine
github.com/thebigroomxxlThis is a learning project built for the Performance-Aware Programming course by Casey Muratori. A major focus of the course is understanding how your code is actually executed at the hardware level and how that impacts performance. Consequently, one of the first steps in the course is to build an 8086 emulator to better understand the structure behind assembly instructions and how they are processed.
The 8086 microprocessor, introduced in 1978, is the foundation of the x86 instruction set, making it an excellent candidate for learning microcode from first principles. While its instruction set is fairly limited compared to modern versions (being only 16-bit, after all), it is actually quite complex compared to modern instruction sets like RISC-V as many clever hacks were used to maximize byte compactness, which was essential given the hardware limitations of the time.
This project was a great learning experience and made me realize that while microcode seems like a difficult and highly specialized topic, it’s actually quite approachable. Since then, I’ve found low-level topics much more accessible and have developed a deeper curiosity about them.