File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
source/Plugins/Process/Utility
unittests/Instruction/ARM64 Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -46,9 +46,9 @@ class RegisterInfoPOSIX_arm64
46
46
47
47
// based on RegisterContextDarwin_arm64.h
48
48
// Pack this so there are no extra bytes, but align its start address to at
49
- // least 4 bytes to prevent alignment errors on Arm 32-bit .
49
+ // least 8 bytes to prevent alignment errors.
50
50
LLVM_PACKED_START
51
- struct alignas (4 ) GPR {
51
+ struct alignas (8 ) GPR {
52
52
uint64_t x[29 ]; // x0-x28
53
53
uint64_t fp; // x29
54
54
uint64_t lr; // x30
Original file line number Diff line number Diff line change @@ -62,7 +62,7 @@ struct Arch64EmulatorTester : public EmulateInstructionARM64 {
62
62
reg_value.SetUInt64 (tester->gpr .pc );
63
63
return true ;
64
64
case gpr_cpsr_arm64:
65
- reg_value.SetUInt64 (tester->gpr .cpsr );
65
+ reg_value.SetUInt32 (tester->gpr .cpsr );
66
66
return true ;
67
67
default :
68
68
return false ;
@@ -97,7 +97,7 @@ struct Arch64EmulatorTester : public EmulateInstructionARM64 {
97
97
tester->gpr .pc = reg_value.GetAsUInt64 ();
98
98
return true ;
99
99
case gpr_cpsr_arm64:
100
- tester->gpr .cpsr = reg_value.GetAsUInt64 ();
100
+ tester->gpr .cpsr = reg_value.GetAsUInt32 ();
101
101
return true ;
102
102
default :
103
103
return false ;
@@ -112,7 +112,7 @@ struct Arch64EmulatorTester : public EmulateInstructionARM64 {
112
112
assert (addr - tester->memory_offset + length <= sizeof (tester->memory ));
113
113
if (addr >= tester->memory_offset &&
114
114
addr - tester->memory_offset + length <= sizeof (tester->memory )) {
115
- memcpy (dst, tester->memory + addr - tester->memory_offset , length);
115
+ memcpy (dst, tester->memory + ( addr - tester->memory_offset ) , length);
116
116
return length;
117
117
}
118
118
return 0 ;
You can’t perform that action at this time.
0 commit comments