diff options
Diffstat (limited to 'src/lj_record.c')
-rw-r--r-- | src/lj_record.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lj_record.c b/src/lj_record.c index 4939d3af..90779f92 100644 --- a/src/lj_record.c +++ b/src/lj_record.c | |||
@@ -1013,7 +1013,7 @@ TRef lj_record_idx(jit_State *J, RecordIndex *ix) | |||
1013 | IRType t = itype2irt(oldv); | 1013 | IRType t = itype2irt(oldv); |
1014 | TRef res; | 1014 | TRef res; |
1015 | if (oldv == niltvg(J2G(J))) { | 1015 | if (oldv == niltvg(J2G(J))) { |
1016 | emitir(IRTG(IR_EQ, IRT_P32), xref, lj_ir_kptr(J, niltvg(J2G(J)))); | 1016 | emitir(IRTG(IR_EQ, IRT_P32), xref, lj_ir_kkptr(J, niltvg(J2G(J)))); |
1017 | res = TREF_NIL; | 1017 | res = TREF_NIL; |
1018 | } else { | 1018 | } else { |
1019 | res = emitir(IRTG(loadop, t), xref, 0); | 1019 | res = emitir(IRTG(loadop, t), xref, 0); |
@@ -1036,7 +1036,7 @@ TRef lj_record_idx(jit_State *J, RecordIndex *ix) | |||
1036 | emitir(IRTG(loadop, IRT_NIL), xref, 0); /* Guard for nil value. */ | 1036 | emitir(IRTG(loadop, IRT_NIL), xref, 0); /* Guard for nil value. */ |
1037 | else if (xrefop == IR_HREF) | 1037 | else if (xrefop == IR_HREF) |
1038 | emitir(IRTG(oldv == niltvg(J2G(J)) ? IR_EQ : IR_NE, IRT_P32), | 1038 | emitir(IRTG(oldv == niltvg(J2G(J)) ? IR_EQ : IR_NE, IRT_P32), |
1039 | xref, lj_ir_kptr(J, niltvg(J2G(J)))); | 1039 | xref, lj_ir_kkptr(J, niltvg(J2G(J)))); |
1040 | if (ix->idxchain && lj_record_mm_lookup(J, ix, MM_newindex)) { | 1040 | if (ix->idxchain && lj_record_mm_lookup(J, ix, MM_newindex)) { |
1041 | lua_assert(hasmm); | 1041 | lua_assert(hasmm); |
1042 | goto handlemm; | 1042 | goto handlemm; |
@@ -1052,7 +1052,7 @@ TRef lj_record_idx(jit_State *J, RecordIndex *ix) | |||
1052 | } else if (!lj_opt_fwd_wasnonnil(J, loadop, tref_ref(xref))) { | 1052 | } else if (!lj_opt_fwd_wasnonnil(J, loadop, tref_ref(xref))) { |
1053 | /* Cannot derive that the previous value was non-nil, must do checks. */ | 1053 | /* Cannot derive that the previous value was non-nil, must do checks. */ |
1054 | if (xrefop == IR_HREF) /* Guard against store to niltv. */ | 1054 | if (xrefop == IR_HREF) /* Guard against store to niltv. */ |
1055 | emitir(IRTG(IR_NE, IRT_P32), xref, lj_ir_kptr(J, niltvg(J2G(J)))); | 1055 | emitir(IRTG(IR_NE, IRT_P32), xref, lj_ir_kkptr(J, niltvg(J2G(J)))); |
1056 | if (ix->idxchain) { /* Metamethod lookup required? */ | 1056 | if (ix->idxchain) { /* Metamethod lookup required? */ |
1057 | /* A check for NULL metatable is cheaper (hoistable) than a load. */ | 1057 | /* A check for NULL metatable is cheaper (hoistable) than a load. */ |
1058 | if (!mt) { | 1058 | if (!mt) { |