This project contains an 8080 emulator implemented by AOT recompiling the provided rom directly to C# IL.
To validate the cpu implementation it provides two architectures which take advantage of it:
- CP/M - The CP/M machine is implemented in it's most trivial form purely to validate the CPU using the test roms found on the internet
- Space Invaders - It also fully implements the space invaders arcade machine architecture (w/ SDL2 for rendering and shift register etc)
Note: This requires a space invaders rom file (which can be acquired on the internet)
dotnet run -c Release --project SpaceInvadersJIT -- roms/real/invaders.rom
Likewise test roms can be executed with
dotnet run -c Release --project CPMEmulator -- roms/test/8080PRE.COM
c.f. https://blog.davetcode.co.uk/post/jit-8080/
- Dotnet 5.0 SDK - https://dotnet.microsoft.com/download
- Suitable text editor/IDE (VS2019 or vscode suggested)
There is a growing suite of simple per-opcode tests verifying the functionality of all individual opcodes, these can be run with dotnet test
Additionally there are a small set of validation roms for the 8080 which require a basic CP/M style machine. These can be run like this (note the correct response below the command):
dotnet run -c Release --project CPMEmulator -- roms/test/8080PRE.COM
8080 Preliminary tests complete
Note that the 8080TST.COM rom doesn't pass because DAA/AuxCarry is not implemented
- Aux Carry Flag & DAA instruction (not implemented because it's not very important and DAA in JIT IL will be very tedious)
- Audio