Jit64: Add optional argument to GenerateOverflow
This allows setting the overflow flag based on any condition code. Defaults to NO (no overflow).
This commit is contained in:
parent
5f7d935b0a
commit
2454bd5ba6
|
@ -96,7 +96,7 @@ public:
|
|||
|
||||
void GenerateConstantOverflow(bool overflow);
|
||||
void GenerateConstantOverflow(s64 val);
|
||||
void GenerateOverflow();
|
||||
void GenerateOverflow(Gen::CCFlags cond = Gen::CCFlags::CC_NO);
|
||||
void FinalizeCarryOverflow(bool oe, bool inv = false);
|
||||
void FinalizeCarry(Gen::CCFlags cond);
|
||||
void FinalizeCarry(bool ca);
|
||||
|
|
|
@ -42,9 +42,9 @@ void Jit64::GenerateConstantOverflow(bool overflow)
|
|||
}
|
||||
|
||||
// We could do overflow branchlessly, but unlike carry it seems to be quite a bit rarer.
|
||||
void Jit64::GenerateOverflow()
|
||||
void Jit64::GenerateOverflow(Gen::CCFlags cond)
|
||||
{
|
||||
FixupBranch jno = J_CC(CC_NO);
|
||||
FixupBranch jno = J_CC(cond);
|
||||
// XER[OV/SO] = 1
|
||||
MOV(8, PPCSTATE(xer_so_ov), Imm8(XER_OV_MASK | XER_SO_MASK));
|
||||
FixupBranch exit = J();
|
||||
|
|
Loading…
Reference in New Issue