Interpreter: Set the FPCC bits correctly for ordered/unordered FP compares
Setting the whole FPRF is slightly incorrect, this should only modify the FPCC bits; the class bit should be preserved.
This commit is contained in:
parent
09319a1e11
commit
bfa5dcc891
|
@ -52,7 +52,9 @@ void Interpreter::Helper_FloatCompareOrdered(UGeckoInstruction _inst, double fa,
|
|||
compareResult = FPCC::FE;
|
||||
}
|
||||
|
||||
FPSCR.FPRF = compareResult;
|
||||
// Clear and set the FPCC bits accordingly.
|
||||
FPSCR.FPRF = (FPSCR.FPRF & ~0xF) | compareResult;
|
||||
|
||||
SetCRField(_inst.CRFD, compareResult);
|
||||
}
|
||||
|
||||
|
@ -83,7 +85,9 @@ void Interpreter::Helper_FloatCompareUnordered(UGeckoInstruction _inst, double f
|
|||
compareResult = FPCC::FE;
|
||||
}
|
||||
|
||||
FPSCR.FPRF = compareResult;
|
||||
// Clear and set the FPCC bits accordingly.
|
||||
FPSCR.FPRF = (FPSCR.FPRF & ~0xF) | compareResult;
|
||||
|
||||
SetCRField(_inst.CRFD, compareResult);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue