RegTest: Fix build on Mac

This commit is contained in:
Stenzek
2023-11-20 20:56:21 +10:00
parent e6d29a0028
commit 20de40a597
7 changed files with 21 additions and 13 deletions

View File

@ -991,6 +991,7 @@ bool CPU::NewRec::Compiler::TryRenameMIPSReg(Reg to, Reg from, u32 fromhost, Reg
// remove all references to renamed-to register
DeleteMIPSReg(to, false);
CancelLoadDelaysToReg(to);
// and do the actual rename, new register has been modified.
m_host_regs[fromhost].reg = to;

View File

@ -972,6 +972,10 @@ void CodeGenerator::GenerateExceptionExit(Instruction instruction, const CodeCac
void CodeGenerator::BlockPrologue()
{
#if 0
EmitFunctionCall(nullptr, &CodeCache::LogCurrentState);
#endif
InitSpeculativeRegs();
if (m_block->protection == CodeCache::PageProtectionMode::ManualCheck)
@ -992,10 +996,6 @@ void CodeGenerator::BlockPrologue()
EmitFunctionCall(nullptr, &CPU::HandleB0Syscall);
}
#if 0
EmitFunctionCall(nullptr, &CodeCache::LogCurrentState);
#endif
if (m_block->uncached_fetch_ticks > 0 || m_block->icache_line_count > 0)
EmitICacheCheckAndUpdate();
@ -2745,7 +2745,8 @@ bool CodeGenerator::Compile_cop0(Instruction instruction, const CodeCache::Instr
EmitBranch(GetCurrentFarCodePointer());
SwitchToFarCode();
m_register_cache.PushState();
WriteNewPC(CalculatePC(), false);
if (!info.is_last_instruction)
WriteNewPC(CalculatePC(), false);
EmitStoreCPUStructField(offsetof(State, downcount), Value::FromConstantU32(0));
EmitExceptionExit();
m_register_cache.PopState();

View File

@ -134,7 +134,7 @@ ALWAYS_INLINE_RELEASE void MaskValidate(PGXP_value* pV, u32 psxV, u32 mask, u32
ALWAYS_INLINE_RELEASE double f16Sign(double in)
{
const s32 s = static_cast<s32>(static_cast<u64>(in * (USHRT_MAX + 1)));
const s32 s = static_cast<s32>(static_cast<s64>(in * (USHRT_MAX + 1)));
return static_cast<double>(s) / static_cast<double>(USHRT_MAX + 1);
}
ALWAYS_INLINE_RELEASE double f16Unsign(double in)