diff options
| author | JosJuice <josjuice@gmail.com> | 2022-11-20 10:23:43 +0100 |
|---|---|---|
| committer | JosJuice <josjuice@gmail.com> | 2022-11-20 10:50:25 +0100 |
| commit | 4b6bad2f9e7fdf2b3ef2721167e6087728b5ea5e (patch) | |
| tree | eae274f27f5a70eaba57c437e63b613a99ffe9e2 /Source | |
| parent | d7593dd7215d92ea0b5eb8fa8b592f3ed758b2ea (diff) | |
Jit64: Use MOV instead of ADD for updating imm Ra
The old code would first MOV the old imm into Ra and then do an ADD.
We can skip the ADD and just MOV the new imm.
Diffstat (limited to 'Source')
| -rw-r--r-- | Source/Core/Core/PowerPC/Jit64/Jit_LoadStore.cpp | 4 | ||||
| -rw-r--r-- | Source/Core/Core/PowerPC/Jit64/Jit_LoadStoreFloating.cpp | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/Source/Core/Core/PowerPC/Jit64/Jit_LoadStore.cpp b/Source/Core/Core/PowerPC/Jit64/Jit_LoadStore.cpp index 3bd24baa22..046a0d6d94 100644 --- a/Source/Core/Core/PowerPC/Jit64/Jit_LoadStore.cpp +++ b/Source/Core/Core/PowerPC/Jit64/Jit_LoadStore.cpp @@ -505,10 +505,10 @@ void Jit64::stX(UGeckoInstruction inst) } else { - RCOpArg Ra = gpr.UseNoImm(a, RCMode::ReadWrite); + RCOpArg Ra = gpr.UseNoImm(a, RCMode::Write); RegCache::Realize(Ra); MemoryExceptionCheck(); - ADD(32, Ra, Imm32((u32)offset)); + MOV(32, Ra, Imm32(addr)); } } } diff --git a/Source/Core/Core/PowerPC/Jit64/Jit_LoadStoreFloating.cpp b/Source/Core/Core/PowerPC/Jit64/Jit_LoadStoreFloating.cpp index 44cdd3c125..0af85a9f26 100644 --- a/Source/Core/Core/PowerPC/Jit64/Jit_LoadStoreFloating.cpp +++ b/Source/Core/Core/PowerPC/Jit64/Jit_LoadStoreFloating.cpp @@ -144,10 +144,10 @@ void Jit64::stfXXX(UGeckoInstruction inst) } else { - RCOpArg Ra = gpr.UseNoImm(a, RCMode::ReadWrite); + RCOpArg Ra = gpr.UseNoImm(a, RCMode::Write); RegCache::Realize(Ra); MemoryExceptionCheck(); - ADD(32, Ra, Imm32((u32)imm)); + MOV(32, Ra, Imm32(addr)); } } return; |
