diff --git a/Source/Core/Core/PowerPC/Interpreter/Interpreter_FloatingPoint.cpp b/Source/Core/Core/PowerPC/Interpreter/Interpreter_FloatingPoint.cpp index 98a5b8a2c0..18a33a1a5e 100644 --- a/Source/Core/Core/PowerPC/Interpreter/Interpreter_FloatingPoint.cpp +++ b/Source/Core/Core/PowerPC/Interpreter/Interpreter_FloatingPoint.cpp @@ -394,7 +394,7 @@ void Interpreter::fdivsx(UGeckoInstruction inst) // Single precision only. void Interpreter::fresx(UGeckoInstruction inst) { - double b = rPS0(inst.FB); + const double b = rPS0(inst.FB); rPS0(inst.FD) = rPS1(inst.FD) = Common::ApproximateReciprocal(b); if (b == 0.0) @@ -402,6 +402,11 @@ void Interpreter::fresx(UGeckoInstruction inst) SetFPException(FPSCR_ZX); } + if (Common::IsSNAN(b)) + { + SetFPException(FPSCR_VXSNAN); + } + PowerPC::UpdateFPRF(rPS0(inst.FD)); if (inst.Rc)