diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2010-04-29 14:31:31 -0300 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2010-04-29 14:31:31 -0300 |
| commit | 3eb1788bb4236cd983f1230ee14e2adb1b5b3ff5 (patch) | |
| tree | 6c2c41dd92bacf2dfe266d750b61b28a67198f9a /lstate.h | |
| parent | 00114a95b2a1234954a46fca6221d1c6922713f8 (diff) | |
| download | lua-3eb1788bb4236cd983f1230ee14e2adb1b5b3ff5.tar.gz lua-3eb1788bb4236cd983f1230ee14e2adb1b5b3ff5.tar.bz2 lua-3eb1788bb4236cd983f1230ee14e2adb1b5b3ff5.zip | |
new way to control GC speed (keeping a 'debt' counter)
Diffstat (limited to 'lstate.h')
| -rw-r--r-- | lstate.h | 4 |
1 files changed, 2 insertions, 2 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: lstate.h,v 2.62 2010/04/12 16:07:06 roberto Exp roberto $ | 2 | ** $Id: lstate.h,v 2.63 2010/04/13 20:48:12 roberto Exp roberto $ |
| 3 | ** Global State | 3 | ** Global State |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -116,7 +116,7 @@ typedef struct global_State { | |||
| 116 | lua_Alloc frealloc; /* function to reallocate memory */ | 116 | lua_Alloc frealloc; /* function to reallocate memory */ |
| 117 | void *ud; /* auxiliary data to `frealloc' */ | 117 | void *ud; /* auxiliary data to `frealloc' */ |
| 118 | lu_mem totalbytes; /* number of bytes currently allocated */ | 118 | lu_mem totalbytes; /* number of bytes currently allocated */ |
| 119 | lu_mem GCthreshold; /* when totalbytes > GCthreshold, run GC step */ | 119 | l_mem GCdebt; /* when positive, run a GC step */ |
| 120 | lu_mem lastmajormem; /* memory in use after last major collection */ | 120 | lu_mem lastmajormem; /* memory in use after last major collection */ |
| 121 | stringtable strt; /* hash table for strings */ | 121 | stringtable strt; /* hash table for strings */ |
| 122 | TValue l_registry; | 122 | TValue l_registry; |
