diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2003-12-01 14:33:30 -0200 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2003-12-01 14:33:30 -0200 |
commit | 1d10acb35500df47d6052164e6c56476f520232e (patch) | |
tree | c6e4983bff097a53b0d73820506ec13ceb8887f5 /lgc.h | |
parent | da61624756a9a64df4aa7e45e9f4013c1b76c293 (diff) | |
download | lua-1d10acb35500df47d6052164e6c56476f520232e.tar.gz lua-1d10acb35500df47d6052164e6c56476f520232e.tar.bz2 lua-1d10acb35500df47d6052164e6c56476f520232e.zip |
incremental GC phases
Diffstat (limited to 'lgc.h')
-rw-r--r-- | lgc.h | 14 |
1 files changed, 12 insertions, 2 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lgc.h,v 1.23 2003/11/18 14:55:11 roberto Exp roberto $ | 2 | ** $Id: lgc.h,v 1.24 2003/11/19 19:41:57 roberto Exp roberto $ |
3 | ** Garbage Collector | 3 | ** Garbage Collector |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -12,6 +12,16 @@ | |||
12 | 12 | ||
13 | 13 | ||
14 | /* | 14 | /* |
15 | ** Possible states of the Garbage Collector | ||
16 | */ | ||
17 | #define GCSroot 0 | ||
18 | #define GCSpropagate 1 | ||
19 | #define GCSatomic 2 | ||
20 | #define GCSsweep 3 | ||
21 | #define GCSfinalize 4 | ||
22 | |||
23 | |||
24 | /* | ||
15 | * ** some userful bit tricks | 25 | * ** some userful bit tricks |
16 | * */ | 26 | * */ |
17 | #define resetbits(x,m) ((x) &= cast(lu_byte, ~(m))) | 27 | #define resetbits(x,m) ((x) &= cast(lu_byte, ~(m))) |
@@ -53,7 +63,7 @@ | |||
53 | 63 | ||
54 | size_t luaC_separateudata (lua_State *L); | 64 | size_t luaC_separateudata (lua_State *L); |
55 | void luaC_callGCTM (lua_State *L); | 65 | void luaC_callGCTM (lua_State *L); |
56 | void luaC_sweep (lua_State *L, int all); | 66 | void luaC_sweepall (lua_State *L); |
57 | void luaC_collectgarbage (lua_State *L); | 67 | void luaC_collectgarbage (lua_State *L); |
58 | void luaC_link (lua_State *L, GCObject *o, lu_byte tt); | 68 | void luaC_link (lua_State *L, GCObject *o, lu_byte tt); |
59 | 69 | ||