From: Toni Wilen Date: Sun, 8 Jul 2018 12:34:35 +0000 (+0300) Subject: Make sure MOVE to SR checks interrupts immediately (except if JIT) X-Git-Tag: 4010~25 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=670b3fd65197fc9a115d229e61bbe32f18c5b6bd;p=francis%2Fwinuae.git Make sure MOVE to SR checks interrupts immediately (except if JIT) --- diff --git a/newcpu.cpp b/newcpu.cpp index 9f8a93d1..018ad399 100644 --- a/newcpu.cpp +++ b/newcpu.cpp @@ -2680,6 +2680,14 @@ static void activate_trace(void) set_special (SPCFLAG_DOTRACE); } +// make sure interrupt is checked immediately after current instruction +static void doint_imm(void) +{ + doint(); + if (!currprefs.cachesize && !(regs.spcflags & SPCFLAG_INT) && (regs.spcflags & SPCFLAG_DOINT)) + set_special(SPCFLAG_INT); +} + void REGPARAM2 MakeSR (void) { regs.sr = ((regs.t1 << 15) | (regs.t0 << 14) @@ -2765,7 +2773,7 @@ static void MakeFromSR_x(int t0trace) if (currprefs.mmu_model) mmu_set_super (regs.s != 0); - doint (); + doint_imm(); if (regs.t1 || regs.t0) { set_special (SPCFLAG_TRACE); } else {