From d915cf4f9dbe525f8faeb4cb04df13d5f08692da Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Wed, 10 Nov 1999 13:39:35 -0200 Subject: ways to measure number of `blocks' for GC + details --- lstate.h | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'lstate.h') diff --git a/lstate.h b/lstate.h index c0ccb1e1..d508120e 100644 --- a/lstate.h +++ b/lstate.h @@ -1,5 +1,5 @@ /* -** $Id: lstate.h,v 1.20 1999/10/04 17:51:04 roberto Exp roberto $ +** $Id: lstate.h,v 1.21 1999/11/04 17:22:26 roberto Exp roberto $ ** Global State ** See Copyright Notice in lua.h */ @@ -14,8 +14,6 @@ #include "luadebug.h" -#define GARBAGE_BLOCK 150 - typedef int StkId; /* index to stack elements */ @@ -50,13 +48,6 @@ typedef struct stringtable { } stringtable; -enum Status {LOCK, HOLD, FREE, COLLECTED}; - -struct ref { - TObject o; - enum Status status; -}; - struct lua_State { /* thread-specific state */ @@ -82,6 +73,7 @@ struct lua_State { int last_tag; /* last used tag in IMtable */ struct ref *refArray; /* locked objects */ int refSize; /* size of refArray */ + int refFree; /* list of free positions in refArray */ unsigned long GCthreshold; unsigned long nblocks; /* number of 'blocks' currently allocated */ }; -- cgit v1.2.3-55-g6feb