[a64] Fix StackLayout

Wrong register index and vector-register size
This commit is contained in:
Wunkolo 2024-05-03 18:07:01 -07:00
parent 10cba8e166
commit defb68eae2
2 changed files with 2 additions and 2 deletions

View File

@ -418,7 +418,7 @@ void A64ThunkEmitter::EmitSaveVolatileRegs() {
STR(X15, XSP, offsetof(StackLayout::Thunk, r[15]));
STR(X16, XSP, offsetof(StackLayout::Thunk, r[16]));
STR(X17, XSP, offsetof(StackLayout::Thunk, r[17]));
STR(X17, XSP, offsetof(StackLayout::Thunk, r[18]));
STR(X18, XSP, offsetof(StackLayout::Thunk, r[18]));
STR(Q0, XSP, offsetof(StackLayout::Thunk, xmm[0]));
STR(Q1, XSP, offsetof(StackLayout::Thunk, xmm[1]));

View File

@ -91,7 +91,7 @@ class StackLayout {
XEPACKEDSTRUCT(Thunk, {
uint64_t arg_temp[3];
uint64_t r[19];
vec128_t xmm[31];
vec128_t xmm[32];
});
static_assert(sizeof(Thunk) % 16 == 0,
"sizeof(Thunk) must be a multiple of 16!");