Fig. 01
Try it
AI-generated voice and avatar
01
Problem & approach
The problem
Run E20 programs end to end: turn assembly source into machine code, execute it instruction by instruction, and model the cache between processor and memory.
The approach
Three pieces in C++: a two-pass assembler, an instruction-set simulator, and an L1/L2 cache simulator with an LRU eviction policy.
02
How it works
- AssembleA two-pass assembler: regex parsing, label resolution and bit-field machine-code encoding.
- SimulateAn object-oriented simulator implements the full ISA with sign extension and 16-bit register and memory masking.
- ValidateValidated against 40+ test scenarios.
- CacheA configurable two-level (L1/L2) cache: direct-mapped, n-way set-associative or fully associative, with LRU eviction and per-access hit/miss logs.
03
Results & stack
- 40+
- test scenarios
- L1/L2
- cache with LRU
- C++
- Assembly
- Computer architecture
