mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-08-04 15:19:09 +00:00
JIT: make backpatch handle sign-extend from 8 bits correctly.
I don't think this is actually possible to trigger at the moment... but it matches the implementation of SafeLoadToReg.
This commit is contained in:
parent
010ca048df
commit
2599cd545e
1 changed files with 6 additions and 1 deletions
|
@ -86,7 +86,12 @@ const u8 *TrampolineCache::GetReadTrampoline(const InstructionInfo &info, u32 re
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (dataReg != EAX)
|
if (info.signExtend && info.operandSize == 1)
|
||||||
|
{
|
||||||
|
// Need to sign extend value from Read_U8.
|
||||||
|
MOVSX(32, 8, dataReg, R(EAX));
|
||||||
|
}
|
||||||
|
else if (dataReg != EAX)
|
||||||
{
|
{
|
||||||
MOV(32, R(dataReg), R(EAX));
|
MOV(32, R(dataReg), R(EAX));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue