pcsx2: sign compare mismatch 2/3

This commit is contained in:
Gregory Hainaut 2014-04-14 20:14:05 +02:00
parent 88f4d1e3a7
commit 27a4bc5a39
8 changed files with 15 additions and 15 deletions

View File

@ -174,7 +174,7 @@ void DisassemblyManager::analyze(u32 address, u32 size = 1024)
u32 next = symbolMap.GetNextSymbolAddress(address,ST_ALL);
if ((next % 4) && next != -1)
if ((next % 4) && next != 0xFFFFFFFF)
{
u32 alignedNext = next & ~3;

View File

@ -161,7 +161,7 @@ void BreakpointWindow::setDefaultValues()
checkLog->Enable(memory);
wchar_t str[64];
if (address != -1)
if (address != 0xFFFFFFFF)
{
swprintf(str,64,L"0x%08X",address);
editAddress->SetLabel(str);

View File

@ -521,7 +521,7 @@ void CtrlDisassemblyView::onPopupClick(wxCommandEvent& evt)
case ID_DISASM_RENAMEFUNCTION:
{
u32 funcBegin = symbolMap.GetFunctionStart(curAddress);
if (funcBegin != -1)
if (funcBegin != 0xFFFFFFFF)
{
wxString newName = wxGetTextFromUser(L"Enter the new function name",L"New function name",
wxString(symbolMap.GetLabelString(funcBegin).c_str(),wxConvUTF8),this);
@ -543,10 +543,10 @@ void CtrlDisassemblyView::onPopupClick(wxCommandEvent& evt)
case ID_DISASM_REMOVEFUNCTION:
{
u32 funcBegin = symbolMap.GetFunctionStart(curAddress);
if (funcBegin != -1)
if (funcBegin != 0xFFFFFFFF)
{
u32 prevBegin = symbolMap.GetFunctionStart(funcBegin-1);
if (prevBegin != -1)
if (prevBegin != 0xFFFFFFFF)
{
u32 expandedSize = symbolMap.GetFunctionSize(prevBegin)+symbolMap.GetFunctionSize(funcBegin);
symbolMap.SetFunctionSize(prevBegin,expandedSize);
@ -570,7 +570,7 @@ void CtrlDisassemblyView::onPopupClick(wxCommandEvent& evt)
case ID_DISASM_ADDFUNCTION:
{
u32 prevBegin = symbolMap.GetFunctionStart(curAddress);
if (prevBegin != -1)
if (prevBegin != 0xFFFFFFFF)
{
if (prevBegin == curAddress)
{
@ -832,7 +832,7 @@ void CtrlDisassemblyView::updateStatusBarText()
} else if (line.type == DISTYPE_DATA)
{
u32 start = symbolMap.GetDataStart(curAddress);
if (start == -1)
if (start == 0xFFFFFFFF)
start = curAddress;
u32 diff = curAddress-start;

View File

@ -755,7 +755,7 @@ void _deleteFPtoXMMreg(int reg, int flush)
}
}
void _freeXMMreg(int xmmreg)
void _freeXMMreg(u32 xmmreg)
{
pxAssert( xmmreg < iREGCNT_XMM );

View File

@ -177,7 +177,7 @@ void _deleteVFtoXMMreg(int reg, int vu, int flush);
//void _deleteACCtoXMMreg(int vu, int flush);
void _deleteGPRtoXMMreg(int reg, int flush);
void _deleteFPtoXMMreg(int reg, int flush);
void _freeXMMreg(int xmmreg);
void _freeXMMreg(u32 xmmreg);
//void _moveXMMreg(int xmmreg); // instead of freeing, moves it to a diff location
void _flushXMMregs();
u8 _hasFreeXMMreg();
@ -307,7 +307,7 @@ void _addNeededMMXreg(int reg);
int _checkMMXreg(int reg, int mode);
void _clearNeededMMXregs();
void _deleteMMXreg(int reg, int flush);
void _freeMMXreg(int mmxreg);
void _freeMMXreg(u32 mmxreg);
void _moveMMXreg(int mmxreg); // instead of freeing, moves it to a diff location
void _flushMMXregs();
u8 _hasFreeMMXreg();

View File

@ -435,7 +435,7 @@ void _deleteX86reg(int type, int reg, int flush)
void _freeX86reg(int x86reg)
{
pxAssert( x86reg >= 0 && x86reg < iREGCNT_GPR );
pxAssert( x86reg >= 0 && x86reg < (int)iREGCNT_GPR );
if( x86regs[x86reg].inuse && (x86regs[x86reg].mode&MODE_WRITE) ) {
x86regs[x86reg].mode &= ~MODE_WRITE;
@ -760,7 +760,7 @@ u8 _hasFreeMMXreg()
return 0;
}
void _freeMMXreg(int mmxreg)
void _freeMMXreg(u32 mmxreg)
{
pxAssert( mmxreg < iREGCNT_MMX );
if (!mmxregs[mmxreg].inuse) return;

View File

@ -3040,7 +3040,7 @@ void VuBaseBlock::Recompile()
if (!x86regs[s_JumpX86].inuse)
{
pxAssert(x86regs[s_JumpX86].type == X86TYPE_VUJUMP);
s_JumpX86 = 0xffffffff; // notify to jump from g_recWriteback
s_JumpX86 = -1; // notify to jump from g_recWriteback
}
}
@ -3113,7 +3113,7 @@ void VuBaseBlock::Recompile()
SuperVUTestVU0Condition(0);
if (s_JumpX86 == 0xffffffff)
if (s_JumpX86 == -1)
JMP32M((uptr)&g_recWriteback);
else
JMPR(s_JumpX86);

View File

@ -187,7 +187,7 @@ EXPORT_C_(void) GSsetGameCRC(int crc, int options)
{
for (u32 i = 0; i < GAME_INFO_INDEX; i++)
{
if (crc_game_list[i].crc == crc)
if (crc_game_list[i].crc == (u32)crc)
{
ZZLog::WriteLn("Found CRC[%x] in crc game list.", crc);