diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2012-07-04 12:52:38 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2012-07-04 12:52:38 -0300 |
commit | e4f609d0ee1cbbd357bec00c43effc659971bc7a (patch) | |
tree | 4be588031fdb7f63efafb86d42c37e53ab23fa26 /lgc.h | |
parent | 5ac56a94dd318aa3db031a31bdc03efb45386b9f (diff) | |
download | lua-e4f609d0ee1cbbd357bec00c43effc659971bc7a.tar.gz lua-e4f609d0ee1cbbd357bec00c43effc659971bc7a.tar.bz2 lua-e4f609d0ee1cbbd357bec00c43effc659971bc7a.zip |
collector in generational mode must be in 'propagate' state when
not running a collection
Diffstat (limited to 'lgc.h')
-rw-r--r-- | lgc.h | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lgc.h,v 2.55 2012/05/21 13:18:10 roberto Exp roberto $ | 2 | ** $Id: lgc.h,v 2.56 2012/05/23 15:43:14 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 | */ |
@@ -55,9 +55,10 @@ | |||
55 | ** phase may break the invariant, as objects turned white may point to | 55 | ** phase may break the invariant, as objects turned white may point to |
56 | ** still-black objects. The invariant is restored when sweep ends and | 56 | ** still-black objects. The invariant is restored when sweep ends and |
57 | ** all objects are white again. During a generational collection, the | 57 | ** all objects are white again. During a generational collection, the |
58 | ** invariant must be kept all times. | 58 | ** invariant must be kept all times. (The state in generational mode |
59 | ** is kept in 'propagate', so 'keepinvariant' is always true.) | ||
59 | */ | 60 | */ |
60 | #define keepinvariant(g) (isgenerational(g) || g->gcstate <= GCSatomic) | 61 | #define keepinvariant(g) (g->gcstate <= GCSatomic) |
61 | 62 | ||
62 | 63 | ||
63 | /* | 64 | /* |