From f13dc59416afa8fc93bb3d784d1a73e49e1b5b09 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Fri, 7 Aug 2020 14:45:20 -0300 Subject: Better tests for gray lists Test uses an extra bit in 'marked' to mark all elements in gray lists and then check against elements colored gray. --- lgc.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'lgc.h') diff --git a/lgc.h b/lgc.h index f571fd2b..0508cd1d 100644 --- a/lgc.h +++ b/lgc.h @@ -69,13 +69,16 @@ /* ** Layout for bit use in 'marked' field. First three bits are -** used for object "age" in generational mode. +** used for object "age" in generational mode. Last bit is used +** by tests. */ #define WHITE0BIT 3 /* object is white (type 0) */ #define WHITE1BIT 4 /* object is white (type 1) */ #define BLACKBIT 5 /* object is black */ #define FINALIZEDBIT 6 /* object has been marked for finalization */ +#define TESTBIT 7 + #define WHITEBITS bit2mask(WHITE0BIT, WHITE1BIT) -- cgit v1.2.3-55-g6feb