atari2600-wasm icon indicating copy to clipboard operation
atari2600-wasm copied to clipboard

Status register flags

Open raybellis opened this issue 3 years ago • 0 comments

Your generated code for N and Z flag handling is incorrect.

The Z flag should be set if result == 0 after truncating to 8 bits.

The N flag is almost always a copy of bit 7 of the result. I see you have this for some instructions, but not for example with ADC, where it's certainly true.

raybellis avatar Nov 16 '20 20:11 raybellis