all repos — mgba @ 52875a082eb5ab3c9cdc94c62b1102e476ead347

mGBA Game Boy Advance Emulator

LR35902: Fix timing on BIT
Jeffrey Pfau jeffrey@endrift.com
Fri, 22 Jan 2016 20:21:54 -0800
commit

52875a082eb5ab3c9cdc94c62b1102e476ead347

parent

862e41ad6bfd084cbd5afd7b48144aa34f6de66d

1 files changed, 1 insertions(+), 1 deletions(-)

jump to
M src/lr35902/isa-lr35902.csrc/lr35902/isa-lr35902.c

@@ -677,7 +677,7 @@ DEFINE_CB_2_INSTRUCTION_LR35902(NAME ## 5, WB, uint8_t bit = 32; BODY) \

DEFINE_CB_2_INSTRUCTION_LR35902(NAME ## 6, WB, uint8_t bit = 64; BODY) \ DEFINE_CB_2_INSTRUCTION_LR35902(NAME ## 7, WB, uint8_t bit = 128; BODY) -DEFINE_CB_INSTRUCTION_LR35902(BIT, LR35902_CORE_STALL, cpu->f.n = 0; cpu->f.h = 1; cpu->f.z = !(reg & bit)) +DEFINE_CB_INSTRUCTION_LR35902(BIT, LR35902_CORE_FETCH, cpu->f.n = 0; cpu->f.h = 1; cpu->f.z = !(reg & bit)) DEFINE_CB_INSTRUCTION_LR35902(RES, LR35902_CORE_MEMORY_STORE, reg &= ~bit) DEFINE_CB_INSTRUCTION_LR35902(SET, LR35902_CORE_MEMORY_STORE, reg |= bit)