Use unaligned stores to save XMM regs to stack.

On Win32, the stack isn't aligned, so aligned stores will cause crashes.
This commit is contained in:
magumagu 2014-03-25 20:46:36 -07:00
parent 5fc6ce59c3
commit e4081b29f9

View File

@ -92,7 +92,7 @@ void XEmitter::ABI_PushRegistersAndAdjustStack(u32 mask, bool noProlog)
{
if (mask & (1 << (16 + x)))
{
MOVAPD(MDisp(RSP, offset), (X64Reg) x);
MOVUPD(MDisp(RSP, offset), (X64Reg) x);
offset += 16;
}
}
@ -114,7 +114,7 @@ void XEmitter::ABI_PopRegistersAndAdjustStack(u32 mask, bool noProlog)
{
if (mask & (1 << (16 + x)))
{
MOVAPD((X64Reg) x, MDisp(RSP, size));
MOVUPD((X64Reg) x, MDisp(RSP, size));
size += 16;
}
}