Nuked-MD-FPGA icon indicating copy to clipboard operation
Nuked-MD-FPGA copied to clipboard

Add standalone testbench for z80 core; run Patrik Rak tests on it

Open lvd2 opened this issue 9 months ago • 1 comments

Patrik Rak's tests (https://github.com/raxoft/z80test) are mainly targeted to the weird behaviour of F3/F5 flags during or after SCF/CCF commands. Here I've made a testbench to run them and collect logs.

These tests pass on real CMOS and NMOS Z80s, but not on this core, so it probably needs bugfixing.

More on SCF/CCF/F3/F5 could be found here: https://github.com/hoglet67/Z80Decoder/wiki/Undocumented-Flags#scfccf

A software library that is able to accurately emulate Z80 (all tests are passing) https://github.com/redcode/Z80

lvd2 avatar Mar 08 '25 20:03 lvd2

It's UB, unlikely to do nicely in a synthesised core

ogamespec avatar Mar 09 '25 04:03 ogamespec