1 /* -----------------------------------------------------------------------------
3 * (c) The GHC Team 1998-2006
5 * Generational garbage collector
7 * Documentation on the architecture of the Garbage Collector can be
8 * found in the online commentary:
10 * http://hackage.haskell.org/trac/ghc/wiki/Commentary/Rts/Storage/GC
12 * ---------------------------------------------------------------------------*/
18 extern rtsBool major_gc;
20 extern rtsBool eager_promotion;
21 extern rtsBool failed_to_evac;
23 extern StgClosure* static_objects;
24 extern StgClosure* scavenged_static_objects;
26 extern bdescr *mark_stack_bdescr;
27 extern StgPtr *mark_stack;
28 extern StgPtr *mark_sp;
29 extern StgPtr *mark_splim;
31 extern rtsBool mark_stack_overflowed;
32 extern bdescr *oldgen_scan_bd;
33 extern StgPtr oldgen_scan;
35 extern lnat new_blocks; // blocks allocated during this GC
36 extern lnat new_scavd_blocks; // ditto, but depth-first blocks
39 extern nat mutlist_MUTVARS, mutlist_MUTARRS, mutlist_OTHERS;
42 StgClosure * isAlive(StgClosure *p);