new parameter 'majorinc' to control frequency of major collections

in generational mode
This commit is contained in:
Roberto Ierusalimschy
2010-09-03 11:14:01 -03:00
parent daa5fe3e31
commit 6828f6d427
6 changed files with 25 additions and 13 deletions

7
lapi.c
View File

@@ -1,5 +1,5 @@
/*
** $Id: lapi.c,v 2.133 2010/07/25 15:18:19 roberto Exp roberto $
** $Id: lapi.c,v 2.134 2010/08/04 18:40:28 roberto Exp roberto $
** Lua API
** See Copyright Notice in lua.h
*/
@@ -976,6 +976,11 @@ LUA_API int lua_gc (lua_State *L, int what, int data) {
g->gcpause = data;
break;
}
case LUA_GCSETMAJORINC: {
res = g->gcmajorinc;
g->gcmajorinc = data;
break;
}
case LUA_GCSETSTEPMUL: {
res = g->gcstepmul;
g->gcstepmul = data;