Core: fix up CX86RecompilerOps::COP1_D_FLOOR_W

This commit is contained in:
zilmar 2024-03-21 17:40:14 +10:30
parent 9a9c2e5439
commit 33d2722841
1 changed files with 13 additions and 6 deletions

View File

@ -8620,6 +8620,12 @@ void CX86RecompilerOps::COP1_D_CEIL_W()
} }
void CX86RecompilerOps::COP1_D_FLOOR_W() void CX86RecompilerOps::COP1_D_FLOOR_W()
{
if (FpuExceptionInRecompiler())
{
COP1_S_CVT(CRegInfo::RoundDown, CRegInfo::FPU_Double, CRegInfo::FPU_Dword);
}
else
{ {
CompileCop1Test(); CompileCop1Test();
if (m_RegWorkingSet.RegInStack(m_Opcode.fs, CRegInfo::FPU_Double) || m_RegWorkingSet.RegInStack(m_Opcode.fs, CRegInfo::FPU_Qword)) if (m_RegWorkingSet.RegInStack(m_Opcode.fs, CRegInfo::FPU_Double) || m_RegWorkingSet.RegInStack(m_Opcode.fs, CRegInfo::FPU_Qword))
@ -8632,6 +8638,7 @@ void CX86RecompilerOps::COP1_D_FLOOR_W()
} }
m_RegWorkingSet.ChangeFPURegFormat(m_Opcode.fd, CRegInfo::FPU_Double, CRegInfo::FPU_Dword, CRegInfo::RoundDown); m_RegWorkingSet.ChangeFPURegFormat(m_Opcode.fd, CRegInfo::FPU_Double, CRegInfo::FPU_Dword, CRegInfo::RoundDown);
} }
}
void CX86RecompilerOps::COP1_D_CVT_S() void CX86RecompilerOps::COP1_D_CVT_S()
{ {