summaryrefslogtreecommitdiff
path: root/src/lj_record.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lj_record.c')
-rw-r--r--src/lj_record.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/lj_record.c b/src/lj_record.c
index 64eba291..b712ec56 100644
--- a/src/lj_record.c
+++ b/src/lj_record.c
@@ -1992,6 +1992,7 @@ static void rec_setup_side(jit_State *J, GCtrace *T)
1992 IRRef ref = snap_ref(sn); 1992 IRRef ref = snap_ref(sn);
1993 BCReg s = snap_slot(sn); 1993 BCReg s = snap_slot(sn);
1994 IRIns *ir = &T->ir[ref]; 1994 IRIns *ir = &T->ir[ref];
1995 IRType t = irt_type(ir->t);
1995 TRef tr; 1996 TRef tr;
1996 /* The bloom filter avoids O(nent^2) overhead for de-duping slots. */ 1997 /* The bloom filter avoids O(nent^2) overhead for de-duping slots. */
1997 if (bloomtest(seen, ref)) { 1998 if (bloomtest(seen, ref)) {
@@ -2005,7 +2006,7 @@ static void rec_setup_side(jit_State *J, GCtrace *T)
2005 bloomset(seen, ref); 2006 bloomset(seen, ref);
2006 switch ((IROp)ir->o) { 2007 switch ((IROp)ir->o) {
2007 /* Only have to deal with constants that can occur in stack slots. */ 2008 /* Only have to deal with constants that can occur in stack slots. */
2008 case IR_KPRI: tr = TREF_PRI(irt_type(ir->t)); break; 2009 case IR_KPRI: tr = TREF_PRI(t); break;
2009 case IR_KINT: tr = lj_ir_kint(J, ir->i); break; 2010 case IR_KINT: tr = lj_ir_kint(J, ir->i); break;
2010 case IR_KGC: tr = lj_ir_kgc(J, ir_kgc(ir), irt_t(ir->t)); break; 2011 case IR_KGC: tr = lj_ir_kgc(J, ir_kgc(ir), irt_t(ir->t)); break;
2011 case IR_KNUM: tr = lj_ir_k64(J, IR_KNUM, ir_knum(ir)); break; 2012 case IR_KNUM: tr = lj_ir_k64(J, IR_KNUM, ir_knum(ir)); break;
@@ -2013,13 +2014,14 @@ static void rec_setup_side(jit_State *J, GCtrace *T)
2013 case IR_KPTR: tr = lj_ir_kptr(J, ir_kptr(ir)); break; /* Continuation. */ 2014 case IR_KPTR: tr = lj_ir_kptr(J, ir_kptr(ir)); break; /* Continuation. */
2014 /* Inherited SLOADs don't need a guard or type check. */ 2015 /* Inherited SLOADs don't need a guard or type check. */
2015 case IR_SLOAD: 2016 case IR_SLOAD:
2016 tr = emitir_raw(ir->ot & ~IRT_GUARD, s, 2017 if (LJ_SOFTFP && (sn & SNAP_SOFTFPNUM)) t = IRT_NUM;
2018 tr = emitir_raw(IRT(IR_SLOAD, t), s,
2017 (ir->op2&IRSLOAD_READONLY) | IRSLOAD_INHERIT|IRSLOAD_PARENT); 2019 (ir->op2&IRSLOAD_READONLY) | IRSLOAD_INHERIT|IRSLOAD_PARENT);
2018 break; 2020 break;
2019 /* Parent refs are already typed and don't need a guard. */ 2021 /* Parent refs are already typed and don't need a guard. */
2020 default: 2022 default:
2021 tr = emitir_raw(IRT(IR_SLOAD, irt_type(ir->t)), s, 2023 if (LJ_SOFTFP && (sn & SNAP_SOFTFPNUM)) t = IRT_NUM;
2022 IRSLOAD_INHERIT|IRSLOAD_PARENT); 2024 tr = emitir_raw(IRT(IR_SLOAD, t), s, IRSLOAD_INHERIT|IRSLOAD_PARENT);
2023 break; 2025 break;
2024 } 2026 }
2025 setslot: 2027 setslot: