diff --git a/gc.c b/gc.c index 82962a9a..5a1c4b06 100644 --- a/gc.c +++ b/gc.c @@ -480,6 +480,10 @@ static const int gc_color_blue = 3; static int gc_status_col; static int gc_stage; +// Does not need sync, only used by collector thread +static void **mark_stack; +static int mark_stack_len; + // GC functions called by the Mutator threads void gc_mut_update() diff --git a/include/cyclone/types.h b/include/cyclone/types.h index d0fb9fa1..e8a03c16 100644 --- a/include/cyclone/types.h +++ b/include/cyclone/types.h @@ -25,8 +25,13 @@ typedef struct gc_thread_data_t gc_thread_data; struct gc_thread_data_t { void **moveBuf; /* list of objects moved to heap during GC */ int moveBufLen; - int gc_alloc_color; // For tri-color marking + // Data needed for tri-color marking + int gc_alloc_color; int gc_mut_status; + int last_write; + int last_read; + void **mark_buffer; + int mark_buffer_len; }; /* GC data structures */