Always allocate R15 for LDR_PCREL instruction, even if literal optimizations are enabled

This fixes crashes on some games when accessing an invalid literal through this instruction
This commit is contained in:
Rafael Caetano 2023-08-28 23:51:01 +01:00
parent cbe93c0d60
commit 0c6ed7ca33

View File

@ -386,8 +386,8 @@ Info Decode(bool thumb, u32 num, u32 instr)
{
if (res.Kind == tk_LDR_PCREL)
{
if (!ARMJIT::LiteralOptimizations)
res.SrcRegs |= 1 << 15;
//if (!ARMJIT::LiteralOptimizations)
res.SrcRegs |= 1 << 15;
res.SpecialKind = special_LoadLiteral;
}
else