'objsize' broke in smaller pieces

This commit is contained in:
Roberto Ierusalimschy
2024-09-30 14:01:42 -03:00
parent e4f418f07c
commit 3d54b42d59
9 changed files with 91 additions and 63 deletions

15
lgc.h
View File

@@ -160,7 +160,11 @@
*/
/* Default Values for GC parameters */
/*
** {======================================================
** Default Values for GC parameters
** =======================================================
*/
/*
** Minor collections will shift to major ones after LUAI_MINORMAJOR%
@@ -189,17 +193,20 @@
/*
** Step multiplier: The collector handles LUAI_GCMUL% work units for
** each new allocated byte. (Each "work unit" corresponds roughly to
** sweeping or marking one object.)
** sweeping one object or traversing one slot.)
*/
#define LUAI_GCMUL 20 /* ??? */
#define LUAI_GCMUL 40
/* How many bytes to allocate before next GC step */
#define LUAI_GCSTEPSIZE (250 * sizeof(void*))
#define LUAI_GCSTEPSIZE (200 * sizeof(Table))
#define setgcparam(g,p,v) (g->gcparams[LUA_GCP##p] = luaO_codeparam(v))
#define applygcparam(g,p,x) luaO_applyparam(g->gcparams[LUA_GCP##p], x)
/* }====================================================== */
/*
** Control when GC is running:
*/