From ffdfcf8347e3acd204501cd4c67ff98767fe264c Mon Sep 17 00:00:00 2001 From: "Nicolas \"Pixel\" Noble" Date: Tue, 31 Dec 2024 19:39:15 -0800 Subject: [PATCH] Simplifying the computation of lowest-target. --- src/core/r3000a.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/core/r3000a.h b/src/core/r3000a.h index 84bf53e0c..8221a6fd0 100644 --- a/src/core/r3000a.h +++ b/src/core/r3000a.h @@ -321,9 +321,7 @@ class R3000Acpu { uint64_t target = cycle + uint64_t(eCycle * m_interruptScales[interrupt]); m_regs.interrupt |= (1 << interrupt); m_regs.intTargets[interrupt] = target; - int64_t lowest = m_regs.lowestTarget - cycle; - int64_t maybeNewLowest = target - cycle; - if (maybeNewLowest < lowest) m_regs.lowestTarget = target; + if (target < m_regs.lowestTarget) m_regs.lowestTarget = target; } psxRegisters m_regs;