Merge pull request #7005 from lioncash/div
Interpreter_FPUtils: Correct setting the FPSCR's zero divide exception flag in the 0/0 case in NI_div()
This commit is contained in:
commit
dd77ace56a
|
@ -132,9 +132,16 @@ inline double NI_div(double a, double b)
|
|||
|
||||
if (b == 0.0)
|
||||
{
|
||||
SetFPException(FPSCR_ZX);
|
||||
if (a == 0.0)
|
||||
{
|
||||
SetFPException(FPSCR_VXZDZ);
|
||||
}
|
||||
else
|
||||
{
|
||||
SetFPException(FPSCR_ZX);
|
||||
FPSCR.FI = 0;
|
||||
FPSCR.FR = 0;
|
||||
}
|
||||
}
|
||||
else if (std::isinf(a) && std::isinf(b))
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue