From: beeanyew Date: Tue, 8 Jun 2021 20:23:26 +0000 (+0200) Subject: Reduce lag of repeatedly triggered interrupts a bit X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=f77e1715a67295b0cbb8942a5541c4024efe90a9;p=pistorm Reduce lag of repeatedly triggered interrupts a bit Please tell me if this breaks everything. --- diff --git a/emulator.c b/emulator.c index 23247fe..b72c243 100644 --- a/emulator.c +++ b/emulator.c @@ -126,11 +126,13 @@ void *ipl_task(void *args) { value = *(gpio + 13); if (!(value & (1 << PIN_IPL_ZERO))) { - irq = 1; old_irq = irq_delay; //NOP - M68K_END_TIMESLICE; - NOP + if (!irq) { + M68K_END_TIMESLICE; + NOP + irq = 1; + } //usleep(0); } else {