Merge pull request #2107 from Sonicadvance1/aarch64_fix_lha

[AArch64] Fix fastmem lha/lhax.
This commit is contained in:
Ryan Houdek 2015-02-23 15:08:42 -06:00
commit 7a61bd5519
1 changed files with 9 additions and 3 deletions

View File

@ -101,10 +101,16 @@ bool JitArm64::DisasmLoadStore(const u8* ptr, u32* flags, ARM64Reg* reg)
{ {
*flags |= BackPatchInfo::FLAG_LOAD; *flags |= BackPatchInfo::FLAG_LOAD;
*reg = (ARM64Reg)(inst & 0x1F); *reg = (ARM64Reg)(inst & 0x1F);
if ((next_inst & 0x7FFFF000) != 0x5AC00000) // REV if ((next_inst & 0x7FFFF000) == 0x5AC00000) // REV
*flags |= BackPatchInfo::FLAG_REVERSE; {
if ((next_inst & 0x7F800000) == 0x13000000) // SXTH u32 sxth_inst = *(u32*)(ptr + 8);
if ((sxth_inst & 0x7F800000) == 0x13000000) // SXTH
*flags |= BackPatchInfo::FLAG_EXTEND; *flags |= BackPatchInfo::FLAG_EXTEND;
}
else
{
*flags |= BackPatchInfo::FLAG_REVERSE;
}
return true; return true;
} }
else if (op == 0xE4) // Store else if (op == 0xE4) // Store