mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-08-03 22:58:50 +00:00
Interpreter: fix carry calculation in srawx
I don't know anything this affected, but it didn't match the manual (or JIT).
This commit is contained in:
parent
84a564a304
commit
9b8cfcdc29
1 changed files with 4 additions and 2 deletions
|
@ -362,8 +362,10 @@ void Interpreter::srawx(UGeckoInstruction _inst)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
m_GPR[_inst.RA] = (u32)((s32)m_GPR[_inst.RS] >> amount);
|
s32 rrs = m_GPR[_inst.RS];
|
||||||
if (m_GPR[_inst.RS] & 0x80000000)
|
m_GPR[_inst.RA] = rrs >> amount;
|
||||||
|
|
||||||
|
if ((rrs < 0) && (rrs << (32 - amount)))
|
||||||
SetCarry(1);
|
SetCarry(1);
|
||||||
else
|
else
|
||||||
SetCarry(0);
|
SetCarry(0);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue