reg_alloc: Determine size of spill slot with sizeof

This commit is contained in:
MerryMage 2021-05-16 21:46:10 +01:00
parent b6bff56523
commit 5bf74b5f04

View file

@ -714,7 +714,7 @@ Xbyak::Address RegAlloc::SpillToOpArg(HostLoc loc) {
ASSERT_MSG(i < SpillCount, "Spill index greater than number of available spill locations"); ASSERT_MSG(i < SpillCount, "Spill index greater than number of available spill locations");
using namespace Xbyak::util; using namespace Xbyak::util;
return xword[rsp + reserved_stack_space + ABI_SHADOW_SPACE + offsetof(StackLayout, spill) + i * sizeof(u64) * 2]; return xword[rsp + reserved_stack_space + ABI_SHADOW_SPACE + offsetof(StackLayout, spill) + i * sizeof(StackLayout::spill[0])];
} }
} // namespace Dynarmic::Backend::X64 } // namespace Dynarmic::Backend::X64