aboutsummaryrefslogtreecommitdiff
path: root/src/lj_gc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lj_gc.c')
-rw-r--r--src/lj_gc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lj_gc.c b/src/lj_gc.c
index 8fea9853..376c9d09 100644
--- a/src/lj_gc.c
+++ b/src/lj_gc.c
@@ -625,6 +625,8 @@ static size_t gc_onestep(lua_State *L)
625 case GCSsweep: { 625 case GCSsweep: {
626 MSize old = g->gc.total; 626 MSize old = g->gc.total;
627 setmref(g->gc.sweep, gc_sweep(g, mref(g->gc.sweep, GCRef), GCSWEEPMAX)); 627 setmref(g->gc.sweep, gc_sweep(g, mref(g->gc.sweep, GCRef), GCSWEEPMAX));
628 lua_assert(old >= g->gc.total);
629 g->gc.estimate -= old - g->gc.total;
628 if (gcref(*mref(g->gc.sweep, GCRef)) == NULL) { 630 if (gcref(*mref(g->gc.sweep, GCRef)) == NULL) {
629 if (g->strnum <= (g->strmask >> 2) && g->strmask > LJ_MIN_STRTAB*2-1) 631 if (g->strnum <= (g->strmask >> 2) && g->strmask > LJ_MIN_STRTAB*2-1)
630 lj_str_resize(L, g->strmask >> 1); /* Shrink string table. */ 632 lj_str_resize(L, g->strmask >> 1); /* Shrink string table. */
@@ -638,8 +640,6 @@ static size_t gc_onestep(lua_State *L)
638 g->gc.debt = 0; 640 g->gc.debt = 0;
639 } 641 }
640 } 642 }
641 lua_assert(old >= g->gc.total);
642 g->gc.estimate -= old - g->gc.total;
643 return GCSWEEPMAX*GCSWEEPCOST; 643 return GCSWEEPMAX*GCSWEEPCOST;
644 } 644 }
645 case GCSfinalize: 645 case GCSfinalize: