From 08b358a829663438d9fef4a2900fe4bef806b4b8 Mon Sep 17 00:00:00 2001 From: JosJuice Date: Thu, 29 Jul 2021 12:27:31 +0200 Subject: [PATCH] Jit64: Fix minor fmaddXX inefficiencies --- .../Core/Core/PowerPC/Jit64/Jit_FloatingPoint.cpp | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/Source/Core/Core/PowerPC/Jit64/Jit_FloatingPoint.cpp b/Source/Core/Core/PowerPC/Jit64/Jit_FloatingPoint.cpp index 1ac8efb214..ace5e193d1 100644 --- a/Source/Core/Core/PowerPC/Jit64/Jit_FloatingPoint.cpp +++ b/Source/Core/Core/PowerPC/Jit64/Jit_FloatingPoint.cpp @@ -421,7 +421,7 @@ void Jit64::fmaddXX(UGeckoInstruction inst) } else { - if (single && round_input) + if (round_input) Force25BitPrecision(result_xmm, Rc, scratch_xmm); else MOVAPD(result_xmm, Rc); @@ -475,20 +475,16 @@ void Jit64::fmaddXX(UGeckoInstruction inst) if (SConfig::GetInstance().bAccurateNaNs && result_xmm == XMM0) { // HandleNaNs needs to clobber XMM0 - MOVAPD(XMM1, R(result_xmm)); - result_xmm = XMM1; + MOVAPD(Rd, R(result_xmm)); + result_xmm = Rd; } + HandleNaNs(inst, result_xmm, result_xmm, XMM0); + if (single) - { - HandleNaNs(inst, result_xmm, result_xmm, XMM0); FinalizeSingleResult(Rd, R(result_xmm), packed, true); - } else - { - HandleNaNs(inst, result_xmm, result_xmm, XMM0); FinalizeDoubleResult(Rd, R(result_xmm)); - } } void Jit64::fsign(UGeckoInstruction inst)