diff options
Diffstat (limited to 'src/lj_asm.c')
-rw-r--r-- | src/lj_asm.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lj_asm.c b/src/lj_asm.c index 38bbb1c2..5e7ff7f5 100644 --- a/src/lj_asm.c +++ b/src/lj_asm.c | |||
@@ -3042,7 +3042,7 @@ static void asm_tail_sync(ASMState *as) | |||
3042 | SnapShot *snap = &as->T->snap[as->T->nsnap-1]; /* Last snapshot. */ | 3042 | SnapShot *snap = &as->T->snap[as->T->nsnap-1]; /* Last snapshot. */ |
3043 | MSize n, nent = snap->nent; | 3043 | MSize n, nent = snap->nent; |
3044 | SnapEntry *map = &as->T->snapmap[snap->mapofs]; | 3044 | SnapEntry *map = &as->T->snapmap[snap->mapofs]; |
3045 | SnapEntry *flinks = map + nent + snap->nframelinks; | 3045 | SnapEntry *flinks = map + nent + 1; |
3046 | BCReg newbase = 0; | 3046 | BCReg newbase = 0; |
3047 | BCReg nslots, topslot = 0; | 3047 | BCReg nslots, topslot = 0; |
3048 | 3048 | ||
@@ -3116,11 +3116,11 @@ static void asm_tail_sync(ASMState *as) | |||
3116 | if (!(sn & (SNAP_CONT|SNAP_FRAME))) | 3116 | if (!(sn & (SNAP_CONT|SNAP_FRAME))) |
3117 | emit_movmroi(as, RID_BASE, ofs+4, irt_toitype(ir->t)); | 3117 | emit_movmroi(as, RID_BASE, ofs+4, irt_toitype(ir->t)); |
3118 | else if (s != 0) /* Do not overwrite link to previous frame. */ | 3118 | else if (s != 0) /* Do not overwrite link to previous frame. */ |
3119 | emit_movmroi(as, RID_BASE, ofs+4, (int32_t)(*--flinks)); | 3119 | emit_movmroi(as, RID_BASE, ofs+4, (int32_t)(*flinks++)); |
3120 | } | 3120 | } |
3121 | checkmclim(as); | 3121 | checkmclim(as); |
3122 | } | 3122 | } |
3123 | lua_assert(map + nent == flinks-1); | 3123 | lua_assert(map + nent + 1 + snap->depth == flinks); |
3124 | } | 3124 | } |
3125 | 3125 | ||
3126 | /* Fixup the tail code. */ | 3126 | /* Fixup the tail code. */ |