git.y1.nz

SameBoy

Accurate GB/GBC emulator
download: https://git.y1.nz/archives/sameboy.tar.gz
README | Files | Log | Refs | LICENSE

commit b032b89457bc1e00a636c26eb5e0968ac77ed1ef
parent 9972ce999dcab913b56f312e8b283172c262f97e
Author: Lior Halphon <LIJI32@gmail.com>
Date:   Sun, 29 Jan 2023 12:41:32 +0200

Banked breakpoints should not affect the boot ROM

Diffstat:
MCore/debugger.c9+++++++++
1 file changed, 9 insertions(+), 0 deletions(-)

diff --git a/Core/debugger.c b/Core/debugger.c @@ -1338,6 +1338,15 @@ static bool _should_break(GB_gameboy_t *gb, value_t addr, bool jump_to) uint32_t key = BP_KEY(addr); if (index < gb->n_breakpoints && gb->breakpoints[index].key == key && gb->breakpoints[index].is_jump_to == jump_to) { + if (addr.has_bank && !gb->boot_rom_finished) { + if (addr.value < 0x100) { + return false; + } + + if (addr.value >= 0x200 && addr.value < 0x900 && GB_is_cgb(gb)) { + return false; + } + } if (!gb->breakpoints[index].condition) { return true; }

This webpage is intended to be an accessible preview of this repository. To get a fuller picture, clone it and use the git CLI.