mirror of https://github.com/PCSX2/pcsx2.git
Fix "Mademan", which triggers an Assert in it's code on bootup.
Handling this via our exception handler crashed the game. git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2634 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
343ccfd3c4
commit
f298f3dd33
|
@ -901,30 +901,46 @@ void PREF( void )
|
|||
{
|
||||
}
|
||||
|
||||
|
||||
// Fixme: The game "Mademan" triggers a trap here, and crashes when we actually handle it.
|
||||
/*********************************************************
|
||||
* Register trap *
|
||||
* Format: OP rs, rt *
|
||||
*********************************************************/
|
||||
|
||||
void TGE() { if (cpuRegs.GPR.r[_Rs_].SD[0] >= cpuRegs.GPR.r[_Rt_].SD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
void TGEU() { if (cpuRegs.GPR.r[_Rs_].UD[0] >= cpuRegs.GPR.r[_Rt_].UD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
void TLT() { if (cpuRegs.GPR.r[_Rs_].SD[0] < cpuRegs.GPR.r[_Rt_].SD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
void TLTU() { if (cpuRegs.GPR.r[_Rs_].UD[0] < cpuRegs.GPR.r[_Rt_].UD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
void TEQ() { if (cpuRegs.GPR.r[_Rs_].SD[0] == cpuRegs.GPR.r[_Rt_].SD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
void TNE() { if (cpuRegs.GPR.r[_Rs_].SD[0] != cpuRegs.GPR.r[_Rt_].SD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
#ifdef PCSX2_DEVBUILD
|
||||
void TGE() { Console.Warning("TGE Trap"); if (cpuRegs.GPR.r[_Rs_].SD[0] >= cpuRegs.GPR.r[_Rt_].SD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
void TGEU() { Console.Warning("TGEU Trap"); if (cpuRegs.GPR.r[_Rs_].UD[0] >= cpuRegs.GPR.r[_Rt_].UD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
void TLT() { Console.Warning("TLT Trap"); if (cpuRegs.GPR.r[_Rs_].SD[0] < cpuRegs.GPR.r[_Rt_].SD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
void TLTU() { Console.Warning("TLTU Trap"); if (cpuRegs.GPR.r[_Rs_].UD[0] < cpuRegs.GPR.r[_Rt_].UD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
void TEQ() { Console.Warning("TEQ Trap"); if (cpuRegs.GPR.r[_Rs_].SD[0] == cpuRegs.GPR.r[_Rt_].SD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
void TNE() { Console.Warning("TNE Trap"); if (cpuRegs.GPR.r[_Rs_].SD[0] != cpuRegs.GPR.r[_Rt_].SD[0]) throw R5900Exception::Trap(_TrapCode_); }
|
||||
#else
|
||||
void TGE() { Console.Warning("TGE Trap"); }
|
||||
void TGEU() { Console.Warning("TGEU Trap"); }
|
||||
void TLT() { Console.Warning("TLT Trap"); }
|
||||
void TLTU() { Console.Warning("TLTU Trap"); }
|
||||
void TEQ() { Console.Warning("TEQ Trap"); }
|
||||
void TNE() { Console.Warning("TNE Trap"); }
|
||||
#endif
|
||||
|
||||
/*********************************************************
|
||||
* Trap with immediate operand *
|
||||
* Format: OP rs, rt *
|
||||
*********************************************************/
|
||||
|
||||
void TGEI() { if (cpuRegs.GPR.r[_Rs_].SD[0] >= _Imm_) throw R5900Exception::Trap(); }
|
||||
void TLTI() { if (cpuRegs.GPR.r[_Rs_].SD[0] < _Imm_) throw R5900Exception::Trap(); }
|
||||
void TEQI() { if (cpuRegs.GPR.r[_Rs_].SD[0] == _Imm_) throw R5900Exception::Trap(); }
|
||||
void TNEI() { if (cpuRegs.GPR.r[_Rs_].SD[0] != _Imm_) throw R5900Exception::Trap(); }
|
||||
void TGEIU() { if (cpuRegs.GPR.r[_Rs_].UD[0] >= (u64)_Imm_) throw R5900Exception::Trap(); }
|
||||
void TLTIU() { if (cpuRegs.GPR.r[_Rs_].UD[0] < (u64)_Imm_) throw R5900Exception::Trap(); }
|
||||
#ifdef PCSX2_DEVBUILD
|
||||
void TGEI() { Console.Warning("TGEI Trap"); if (cpuRegs.GPR.r[_Rs_].SD[0] >= _Imm_) throw R5900Exception::Trap(); }
|
||||
void TLTI() { Console.Warning("TLTI Trap"); if (cpuRegs.GPR.r[_Rs_].SD[0] < _Imm_) throw R5900Exception::Trap(); }
|
||||
void TEQI() { Console.Warning("TEQI Trap"); if (cpuRegs.GPR.r[_Rs_].SD[0] == _Imm_) throw R5900Exception::Trap(); }
|
||||
void TNEI() { Console.Warning("TNEI Trap"); if (cpuRegs.GPR.r[_Rs_].SD[0] != _Imm_) throw R5900Exception::Trap(); }
|
||||
void TGEIU() { Console.Warning("TGEIU Trap"); if (cpuRegs.GPR.r[_Rs_].UD[0] >= (u64)_Imm_) throw R5900Exception::Trap(); }
|
||||
void TLTIU() { Console.Warning("TLTIU Trap"); if (cpuRegs.GPR.r[_Rs_].UD[0] < (u64)_Imm_) throw R5900Exception::Trap(); }
|
||||
#else
|
||||
void TGEI() { Console.Warning("TGEI Trap"); }
|
||||
void TLTI() { Console.Warning("TLTI Trap"); }
|
||||
void TEQI() { Console.Warning("TEQI Trap"); }
|
||||
void TNEI() { Console.Warning("TNEI Trap"); }
|
||||
void TGEIU() { Console.Warning("TGEIU Trap"); }
|
||||
void TLTIU() { Console.Warning("TLTIU Trap"); }
|
||||
#endif
|
||||
|
||||
/*********************************************************
|
||||
* Sa intructions *
|
||||
|
|
Loading…
Reference in New Issue