mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2024-11-15 05:47:56 -07:00
DSP: updated condition code
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3099 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
f852ea41c4
commit
1f4c000ae6
@ -89,9 +89,8 @@ int GetMultiplyModifier()
|
|||||||
return 2;
|
return 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
inline bool isSign() {
|
inline bool isSign() {
|
||||||
return ((g_dsp.r[DSP_REG_SR] & 0x02) || (g_dsp.r[DSP_REG_SR] & 0x08));
|
return ((g_dsp.r[DSP_REG_SR] & 0x02) != (g_dsp.r[DSP_REG_SR] & 0x08));
|
||||||
}
|
}
|
||||||
|
|
||||||
inline bool isZero() {
|
inline bool isZero() {
|
||||||
@ -115,7 +114,7 @@ bool CheckCondition(u8 _Condition)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case 0x2: // G - GREATER
|
case 0x2: // G - GREATER
|
||||||
if (! isSign() && ! isZero())
|
if (! isSign() || g_dsp.r[DSP_REG_SR] & SR_CARRY)
|
||||||
taken = true;
|
taken = true;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -137,12 +136,12 @@ bool CheckCondition(u8 _Condition)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case 0x6: // L - LESS
|
case 0x6: // L - LESS
|
||||||
if (isSign())
|
if (g_dsp.r[DSP_REG_SR] & 0x02)
|
||||||
taken = true;
|
taken = true;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 0x7: // GE - GREATER EQUAL
|
case 0x7: // GE - GREATER EQUAL
|
||||||
if (! isSign() || isZero())
|
if (g_dsp.r[DSP_REG_SR] & SR_CARRY)
|
||||||
taken = true;
|
taken = true;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user