aboutsummaryrefslogtreecommitdiff
path: root/src/ARMJIT_A64
diff options
context:
space:
mode:
authorRSDuck <RSDuck@users.noreply.github.com>2021-04-29 15:15:16 +0200
committerRSDuck <RSDuck@users.noreply.github.com>2021-04-29 15:15:16 +0200
commit0a3a2ad00909fa14f6ab85229b94b17ff257fa5b (patch)
tree9bc9bf5504c6740e03fad0455862f7c2a8863aa0 /src/ARMJIT_A64
parenteae42fb9f85ed45df5d1d885088539acf1f7c785 (diff)
fix aarch64 build with gcc 11
Diffstat (limited to 'src/ARMJIT_A64')
-rw-r--r--src/ARMJIT_A64/ARMJIT_Compiler.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ARMJIT_A64/ARMJIT_Compiler.cpp b/src/ARMJIT_A64/ARMJIT_Compiler.cpp
index ef93905..4fbb804 100644
--- a/src/ARMJIT_A64/ARMJIT_Compiler.cpp
+++ b/src/ARMJIT_A64/ARMJIT_Compiler.cpp
@@ -483,12 +483,12 @@ void Compiler::LoadReg(int reg, ARM64Reg nativeReg)
if (reg == 15)
MOVI2R(nativeReg, R15);
else
- LDR(INDEX_UNSIGNED, nativeReg, RCPU, offsetof(ARM, R[reg]));
+ LDR(INDEX_UNSIGNED, nativeReg, RCPU, offsetof(ARM, R) + reg*4);
}
void Compiler::SaveReg(int reg, ARM64Reg nativeReg)
{
- STR(INDEX_UNSIGNED, nativeReg, RCPU, offsetof(ARM, R[reg]));
+ STR(INDEX_UNSIGNED, nativeReg, RCPU, offsetof(ARM, R) + reg*4);
}
void Compiler::LoadCPSR()