diff --git a/src/backend_x64/emit_x64_vector.cpp b/src/backend_x64/emit_x64_vector.cpp index d8c9c3d4..e315a1a9 100644 --- a/src/backend_x64/emit_x64_vector.cpp +++ b/src/backend_x64/emit_x64_vector.cpp @@ -2806,12 +2806,12 @@ void EmitX64::EmitVectorTableLookup(EmitContext& ctx, IR::Inst* inst) { ctx.reg_alloc.EndOfAllocScope(); ctx.reg_alloc.HostCall(nullptr); - code.movaps(xword[rsp + ABI_SHADOW_SPACE + (table_size + 0) * 16], defaults); - code.movaps(xword[rsp + ABI_SHADOW_SPACE + (table_size + 1) * 16], indicies); code.lea(code.ABI_PARAM1, ptr[rsp + ABI_SHADOW_SPACE]); code.lea(code.ABI_PARAM2, ptr[rsp + ABI_SHADOW_SPACE + (table_size + 0) * 16]); code.lea(code.ABI_PARAM3, ptr[rsp + ABI_SHADOW_SPACE + (table_size + 1) * 16]); code.mov(code.ABI_PARAM4.cvt32(), table_size); + code.movaps(xword[code.ABI_PARAM2], defaults); + code.movaps(xword[code.ABI_PARAM3], indicies); code.CallFunction(static_cast*, VectorArray&, const VectorArray&, size_t)>( [](const VectorArray* table, VectorArray& result, const VectorArray& indicies, size_t table_size) {