From: Toni Wilen Date: Sat, 14 Jul 2018 18:48:58 +0000 (+0300) Subject: STOP tracing update. X-Git-Tag: 4010~3 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=7353ed02d9d4ddb68f2ba7a0e64c6fe96bd51d17;p=francis%2Fwinuae.git STOP tracing update. --- diff --git a/newcpu.cpp b/newcpu.cpp index 018ad399..6176bf73 100644 --- a/newcpu.cpp +++ b/newcpu.cpp @@ -4690,6 +4690,8 @@ void doint (void) static int do_specialties (int cycles) { + bool stopped_debug = false; + if (regs.spcflags & SPCFLAG_MODE_CHANGE) return 1; @@ -4888,13 +4890,23 @@ static int do_specialties (int cycles) set_special (SPCFLAG_INT); } - if (regs.spcflags & SPCFLAG_BRK) { + if ((regs.spcflags & SPCFLAG_BRK) || stopped_debug) { unset_special(SPCFLAG_BRK); #ifdef DEBUGGER + if (stopped_debug && !regs.stopped) { + debugger_active = 1; + stopped_debug = false; + } if (debugging) { - debug(); - if (regs.stopped) + if (!stopped_debug) + debug(); + if (regs.stopped) { + stopped_debug = true; + if (debugging) { + debugger_active = 0; + } goto isstopped; + } } #endif }