traverse the spark pools only once during GC rather than twice
[ghc-hetmet.git] / rts / sm / GC.h
1 /* -----------------------------------------------------------------------------
2  *
3  * (c) The GHC Team 1998-2008
4  *
5  * Generational garbage collector
6  *
7  * Documentation on the architecture of the Garbage Collector can be
8  * found in the online commentary:
9  * 
10  *   http://hackage.haskell.org/trac/ghc/wiki/Commentary/Rts/Storage/GC
11  *
12  * ---------------------------------------------------------------------------*/
13
14 #ifndef GC_H
15 #define GC_H
16
17 extern nat N;
18 extern rtsBool major_gc;
19
20 extern bdescr *mark_stack_bdescr;
21 extern StgPtr *mark_stack;
22 extern StgPtr *mark_sp;
23 extern StgPtr *mark_splim;
24
25 extern rtsBool mark_stack_overflowed;
26 extern bdescr *oldgen_scan_bd;
27 extern StgPtr  oldgen_scan;
28
29 extern long copied;
30
31 #ifdef DEBUG
32 extern nat mutlist_MUTVARS, mutlist_MUTARRS, mutlist_MVARS, mutlist_OTHERS;
33 #endif
34
35 #ifdef THREADED_RTS
36 extern SpinLock gc_alloc_block_sync;
37 #endif
38
39 #if defined(PROF_SPIN) && defined(THREADED_RTS)
40 extern StgWord64 whitehole_spin;
41 #endif
42
43 #define WORK_UNIT_WORDS 128
44
45 #endif /* GC_H */