Core: Remvoe #ifdef LinkBlocks code block
This commit is contained in:
parent
989827cb77
commit
9743f12b1d
|
@ -9484,103 +9484,7 @@ void CX86RecompilerOps::CompileExit(uint32_t JumpPC, uint32_t TargetPC, CRegInfo
|
|||
CompileSystemCheck((uint32_t)-1, ExitRegSet);
|
||||
}
|
||||
}
|
||||
#ifdef LinkBlocks
|
||||
if (g_SyncSystem)
|
||||
{
|
||||
m_Assembler.CallThis((uint32_t)g_BaseSystem, AddressOf(&CN64System::SyncSystem), "CN64System::SyncSystem", 4);
|
||||
}
|
||||
if (bSMM_ValidFunc == false)
|
||||
{
|
||||
if (LookUpMode() == FuncFind_ChangeMemory)
|
||||
{
|
||||
g_Notify->BreakPoint(__FILE__, __LINE__);
|
||||
// uint8_t * Jump, * Jump2;
|
||||
// if (TargetPC >= 0x80000000 && TargetPC < 0xC0000000) {
|
||||
// uint32_t pAddr = TargetPC & 0x1FFFFFFF;
|
||||
//
|
||||
// m_Assembler.MoveVariableToX86reg(asmjit::x86::eax, (uint8_t *)RDRAM + pAddr,"RDRAM + pAddr");
|
||||
// Jump2 = nullptr;
|
||||
// } else {
|
||||
// m_Assembler.MoveConstToX86reg(asmjit::x86::ecx, (TargetPC >> 12));
|
||||
// m_Assembler.MoveConstToX86reg(asmjit::x86::ebx, TargetPC);
|
||||
// m_Assembler.MoveVariableDispToX86Reg(asmjit::x86::ecx,TLB_ReadMap,"TLB_ReadMap",asmjit::x86::ecx,4);
|
||||
// TestX86RegToX86Reg(asmjit::x86::ecx,asmjit::x86::ecx);
|
||||
// m_Assembler.JeLabel8("NoTlbEntry",0);
|
||||
// Jump2 = *g_RecompPos - 1;
|
||||
// m_Assembler.MoveX86regPointerToX86reg(asmjit::x86::eax,asmjit::x86::ecx, asmjit::x86::ebx);
|
||||
// }
|
||||
// m_Assembler.MoveX86RegToX86Reg(asmjit::x86::ecx, asmjit::x86::eax);
|
||||
// m_Assembler.AndConstToX86Reg(asmjit::x86::ecx,0xFFFF0000);
|
||||
// m_Assembler.CompConstToX86reg(asmjit::x86::ecx,0x7C7C0000);
|
||||
// m_Assembler.JneLabel8("NoCode",0);
|
||||
// Jump = *g_RecompPos - 1;
|
||||
// m_Assembler.AndConstToX86Reg(asmjit::x86::eax,0xFFFF);
|
||||
// m_Assembler.ShiftLeftSignImmed(asmjit::x86::eax,4);
|
||||
// m_Assembler.AddConstToX86Reg(asmjit::x86::eax,0xC);
|
||||
// m_Assembler.MoveVariableDispToX86Reg(asmjit::x86::ecx,OrigMem,"OrigMem",asmjit::x86::eax,1);
|
||||
// JmpDirectReg(asmjit::x86::ecx);
|
||||
// m_CodeBlock.Log(" NoCode:");
|
||||
// *((uint8_t *)(Jump))=(uint8_t)(*g_RecompPos - Jump - 1);
|
||||
// if (Jump2 != nullptr) {
|
||||
// m_CodeBlock.Log(" NoTlbEntry:");
|
||||
// *((uint8_t *)(Jump2))=(uint8_t)(*g_RecompPos - Jump2 - 1);
|
||||
// }
|
||||
}
|
||||
else if (LookUpMode() == FuncFind_VirtualLookup)
|
||||
{
|
||||
m_Assembler.MoveConstToX86reg(asmjit::x86::edx, TargetPC);
|
||||
m_Assembler.MoveConstToX86reg(asmjit::x86::ecx, (uint32_t)&m_Functions);
|
||||
m_Assembler.CallFunc(AddressOf(&CFunctionMap::CompilerFindFunction), "CFunctionMap::CompilerFindFunction");
|
||||
m_Assembler.MoveX86RegToX86Reg(asmjit::x86::ecx, asmjit::x86::eax);
|
||||
JecxzLabel8("NullPointer", 0);
|
||||
uint8_t * Jump = *g_RecompPos - 1;
|
||||
m_Assembler.MoveX86PointerToX86regDisp(asmjit::x86::ebx, asmjit::x86::ecx, 0xC);
|
||||
JmpDirectReg(asmjit::x86::ebx);
|
||||
m_CodeBlock.Log(" NullPointer:");
|
||||
*((uint8_t *)(Jump)) = (uint8_t)(*g_RecompPos - Jump - 1);
|
||||
}
|
||||
else if (LookUpMode() == FuncFind_PhysicalLookup)
|
||||
{
|
||||
uint8_t * Jump2 = nullptr;
|
||||
if (TargetPC >= 0x80000000 && TargetPC < 0x90000000)
|
||||
{
|
||||
uint32_t pAddr = TargetPC & 0x1FFFFFFF;
|
||||
m_Assembler.MoveVariableToX86reg(asmjit::x86::ecx, (uint8_t *)JumpTable + pAddr, "JumpTable + pAddr");
|
||||
}
|
||||
else if (TargetPC >= 0x90000000 && TargetPC < 0xC0000000)
|
||||
{
|
||||
}
|
||||
else
|
||||
{
|
||||
m_Assembler.MoveConstToX86reg(asmjit::x86::ecx, (TargetPC >> 12));
|
||||
m_Assembler.MoveConstToX86reg(asmjit::x86::ebx, TargetPC);
|
||||
m_Assembler.MoveVariableDispToX86Reg(asmjit::x86::ecx, TLB_ReadMap, "TLB_ReadMap", asmjit::x86::ecx, 4);
|
||||
TestX86RegToX86Reg(asmjit::x86::ecx, asmjit::x86::ecx);
|
||||
m_Assembler.JeLabel8("NoTlbEntry", 0);
|
||||
Jump2 = *g_RecompPos - 1;
|
||||
m_Assembler.AddConstToX86Reg(asmjit::x86::ecx, (uint32_t)JumpTable - (uint32_t)RDRAM);
|
||||
m_Assembler.MoveX86regPointerToX86reg(asmjit::x86::ecx, asmjit::x86::ecx, asmjit::x86::ebx);
|
||||
}
|
||||
if (TargetPC < 0x90000000 || TargetPC >= 0xC0000000)
|
||||
{
|
||||
JecxzLabel8("NullPointer", 0);
|
||||
uint8_t * Jump = *g_RecompPos - 1;
|
||||
m_Assembler.MoveX86PointerToX86regDisp(asmjit::x86::eax, asmjit::x86::ecx, 0xC);
|
||||
JmpDirectReg(asmjit::x86::eax);
|
||||
m_CodeBlock.Log(" NullPointer:");
|
||||
*((uint8_t *)(Jump)) = (uint8_t)(*g_RecompPos - Jump - 1);
|
||||
if (Jump2 != nullptr)
|
||||
{
|
||||
m_CodeBlock.Log(" NoTlbEntry:");
|
||||
*((uint8_t *)(Jump2)) = (uint8_t)(*g_RecompPos - Jump2 - 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
ExitCodeBlock();
|
||||
#else
|
||||
ExitCodeBlock();
|
||||
#endif
|
||||
break;
|
||||
case ExitReason_DoCPUAction:
|
||||
m_Assembler.CallThis((uint32_t)g_SystemEvents, AddressOf(&CSystemEvents::ExecuteEvents), "CSystemEvents::ExecuteEvents", 4);
|
||||
|
|
Loading…
Reference in New Issue