fix setting of cr in jit64 for divwux (when div by 0)

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5244 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Shawn Hoffman 2010-03-27 19:48:34 +00:00
parent ef193f2e95
commit 672132eb84
2 changed files with 3 additions and 3 deletions

View File

@ -505,10 +505,9 @@ void divwux(UGeckoInstruction _inst)
m_GPR[_inst.RD] = 0;
}
else
{
m_GPR[_inst.RD] = a / b;
if (_inst.Rc) Helper_UpdateCR0(m_GPR[_inst.RD]);
}
}
void mulhwx(UGeckoInstruction _inst)

View File

@ -649,6 +649,7 @@ void Jit64::divwux(UGeckoInstruction inst)
// doesn't handle if OE is set, but int doesn't either...
FixupBranch not_div_by_zero = J_CC(CC_NZ);
MOV(32, gpr.R(d), Imm32(0));
MOV(32, R(EAX), gpr.R(d));
FixupBranch end = J();
SetJumpTarget(not_div_by_zero);
DIV(32, gpr.R(b));