From 882537a8744a75681355fb520923e6e867f99d23 Mon Sep 17 00:00:00 2001 From: Mike Pall Date: Thu, 13 Oct 2011 20:53:01 +0200 Subject: [PATCH] FFI: Fix unfused loads of float fields. --- src/lj_asm_x86.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lj_asm_x86.h b/src/lj_asm_x86.h index 0803ecef..840484d0 100644 --- a/src/lj_asm_x86.h +++ b/src/lj_asm_x86.h @@ -1147,13 +1147,13 @@ static void asm_strref(ASMState *as, IRIns *ir) static void asm_fxload(ASMState *as, IRIns *ir) { - Reg dest = ra_dest(as, ir, irt_isnum(ir->t) ? RSET_FPR : RSET_GPR); + Reg dest = ra_dest(as, ir, irt_isfp(ir->t) ? RSET_FPR : RSET_GPR); x86Op xo; if (ir->o == IR_FLOAD) asm_fusefref(as, ir, RSET_GPR); else asm_fusexref(as, ir->op1, RSET_GPR); - /* ir->op2 is ignored -- unaligned loads are ok on x86. */ + /* ir->op2 is ignored -- unaligned loads are ok on x86. */ switch (irt_type(ir->t)) { case IRT_I8: xo = XO_MOVSXb; break; case IRT_U8: xo = XO_MOVZXb; break;