Don't waste time looking up the block if enableBlocklink is off anyway.

This commit is contained in:
comex 2013-10-08 19:07:30 -04:00
parent 0dd32986b8
commit d5e40bfb01

View File

@ -298,18 +298,19 @@ void Jit64::WriteExit(u32 destination, int exit_num)
b->exitPtrs[exit_num] = GetWritableCodePtr(); b->exitPtrs[exit_num] = GetWritableCodePtr();
// Link opportunity! // Link opportunity!
int block = blocks.GetBlockNumberFromStartAddress(destination); if (jo.enableBlocklink)
if (block >= 0 && jo.enableBlocklink)
{ {
// It exists! Joy of joy! int block = blocks.GetBlockNumberFromStartAddress(destination);
JMP(blocks.GetBlock(block)->checkedEntry, true); if (block >= 0)
b->linkStatus[exit_num] = true; {
} // It exists! Joy of joy!
else JMP(blocks.GetBlock(block)->checkedEntry, true);
{ b->linkStatus[exit_num] = true;
MOV(32, M(&PC), Imm32(destination)); return;
JMP(asm_routines.dispatcher, true); }
} }
MOV(32, M(&PC), Imm32(destination));
JMP(asm_routines.dispatcher, true);
} }
void Jit64::WriteExitDestInEAX() void Jit64::WriteExitDestInEAX()