mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-09 23:59:27 +01:00
Merge pull request #12566 from JosJuice/arm64-add-imm-sp
Arm64Emitter: Don't optimize ADD to MOV for SP
This commit is contained in:
commit
a50ab40a5f
@ -4222,9 +4222,15 @@ void ARM64XEmitter::ADDI2R_internal(ARM64Reg Rd, ARM64Reg Rn, u64 imm, bool nega
|
||||
// Special path for zeroes
|
||||
if (imm == 0 && !flags)
|
||||
{
|
||||
if (Rd != Rn)
|
||||
if (Rd == Rn)
|
||||
{
|
||||
return;
|
||||
}
|
||||
else if (DecodeReg(Rd) != DecodeReg(ARM64Reg::SP) && DecodeReg(Rn) != DecodeReg(ARM64Reg::SP))
|
||||
{
|
||||
MOV(Rd, Rn);
|
||||
return;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
// Regular fast paths, aarch64 immediate instructions
|
||||
|
Loading…
x
Reference in New Issue
Block a user