aboutsummaryrefslogtreecommitdiff
path: root/src/lj_asm_x86.h
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/lj_asm_x86.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lj_asm_x86.h b/src/lj_asm_x86.h
index 3c934c31..512f1afd 100644
--- a/src/lj_asm_x86.h
+++ b/src/lj_asm_x86.h
@@ -227,9 +227,6 @@ static void asm_fuseahuref(ASMState *as, IRRef ref, RegSet allow)
227#endif 227#endif
228 return; 228 return;
229 default: 229 default:
230 lj_assertA(ir->o == IR_HREF || ir->o == IR_NEWREF || ir->o == IR_UREFO ||
231 ir->o == IR_KKPTR,
232 "bad IR op %d", ir->o);
233 break; 230 break;
234 } 231 }
235 } 232 }
@@ -490,6 +487,7 @@ static Reg asm_fuseload(ASMState *as, IRRef ref, RegSet allow)
490 } 487 }
491 } else if (ir->o == IR_VLOAD && !(LJ_GC64 && irt_isaddr(ir->t))) { 488 } else if (ir->o == IR_VLOAD && !(LJ_GC64 && irt_isaddr(ir->t))) {
492 asm_fuseahuref(as, ir->op1, xallow); 489 asm_fuseahuref(as, ir->op1, xallow);
490 as->mrm.ofs += 8 * ir->op2;
493 return RID_MRM; 491 return RID_MRM;
494 } 492 }
495 } 493 }
@@ -1550,6 +1548,7 @@ static void asm_ahuvload(ASMState *as, IRIns *ir)
1550 Reg dest = asm_load_lightud64(as, ir, 1); 1548 Reg dest = asm_load_lightud64(as, ir, 1);
1551 if (ra_hasreg(dest)) { 1549 if (ra_hasreg(dest)) {
1552 asm_fuseahuref(as, ir->op1, RSET_GPR); 1550 asm_fuseahuref(as, ir->op1, RSET_GPR);
1551 if (ir->o == IR_VLOAD) as->mrm.ofs += 8 * ir->op2;
1553 emit_mrm(as, XO_MOV, dest|REX_64, RID_MRM); 1552 emit_mrm(as, XO_MOV, dest|REX_64, RID_MRM);
1554 } 1553 }
1555 return; 1554 return;
@@ -1559,6 +1558,7 @@ static void asm_ahuvload(ASMState *as, IRIns *ir)
1559 RegSet allow = irt_isnum(ir->t) ? RSET_FPR : RSET_GPR; 1558 RegSet allow = irt_isnum(ir->t) ? RSET_FPR : RSET_GPR;
1560 Reg dest = ra_dest(as, ir, allow); 1559 Reg dest = ra_dest(as, ir, allow);
1561 asm_fuseahuref(as, ir->op1, RSET_GPR); 1560 asm_fuseahuref(as, ir->op1, RSET_GPR);
1561 if (ir->o == IR_VLOAD) as->mrm.ofs += 8 * ir->op2;
1562#if LJ_GC64 1562#if LJ_GC64
1563 if (irt_isaddr(ir->t)) { 1563 if (irt_isaddr(ir->t)) {
1564 emit_shifti(as, XOg_SHR|REX_64, dest, 17); 1564 emit_shifti(as, XOg_SHR|REX_64, dest, 17);
@@ -1586,6 +1586,7 @@ static void asm_ahuvload(ASMState *as, IRIns *ir)
1586 } 1586 }
1587#endif 1587#endif
1588 asm_fuseahuref(as, ir->op1, gpr); 1588 asm_fuseahuref(as, ir->op1, gpr);
1589 if (ir->o == IR_VLOAD) as->mrm.ofs += 8 * ir->op2;
1589 } 1590 }
1590 /* Always do the type check, even if the load result is unused. */ 1591 /* Always do the type check, even if the load result is unused. */
1591 as->mrm.ofs += 4; 1592 as->mrm.ofs += 4;