From bb7ac337ebe947fc0e445b44a2d8e281a00f8a3f Mon Sep 17 00:00:00 2001 From: Toni Wilen Date: Sat, 29 Feb 2020 21:46:56 +0200 Subject: [PATCH] Prefetch mode interrupt delays need SPCFLAG_INT or interrupt start would get delayed, especially after MOVE to SR. --- newcpu.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/newcpu.cpp b/newcpu.cpp index 6b1ec345..d64ad64d 100644 --- a/newcpu.cpp +++ b/newcpu.cpp @@ -4204,7 +4204,7 @@ STATIC_INLINE bool time_for_interrupt (void) return regs.ipl > regs.intmask || regs.ipl == 7; } -void doint (void) +void doint(void) { #ifdef WITH_PPC if (ppc_state) { @@ -4214,7 +4214,7 @@ void doint (void) #endif if (m68k_interrupt_delay) { regs.ipl_pin = intlev (); - unset_special (SPCFLAG_INT); + set_special(SPCFLAG_INT); return; } if (currprefs.cpu_compatible && currprefs.cpu_model < 68020) @@ -4362,6 +4362,7 @@ static int do_specialties (int cycles) do_copper (); if (m68k_interrupt_delay) { + unset_special(SPCFLAG_INT); ipl_fetch (); if (time_for_interrupt ()) { do_interrupt (regs.ipl); @@ -4408,6 +4409,7 @@ static int do_specialties (int cycles) } if (m68k_interrupt_delay) { + unset_special(SPCFLAG_INT); if (time_for_interrupt ()) { do_interrupt (regs.ipl); } -- 2.47.3