20bc0155ada6742ae3975575521f08a7d4137b5b
[ghc-hetmet.git] / rts / Stats.h
1 /* -----------------------------------------------------------------------------
2  *
3  * (c) The GHC Team, 1998-2005
4  *
5  * Statistics and timing-related functions.
6  *
7  * ---------------------------------------------------------------------------*/
8
9 #ifndef STATS_H
10 #define STATS_H
11
12 #include "GetTime.h"
13
14 void      stat_startInit(void);
15 void      stat_endInit(void);
16
17 void      stat_startGC(void);
18 void      stat_endGC (lnat alloc, lnat live, 
19                       lnat copied, lnat scavd_copied, lnat gen);
20
21 #ifdef PROFILING
22 void      stat_startRP(void);
23 void      stat_endRP(nat, 
24 #ifdef DEBUG_RETAINER
25                             nat, int, 
26 #endif
27                             double);
28 #endif /* PROFILING */
29
30 #if defined(PROFILING) || defined(DEBUG)
31 void      stat_startHeapCensus(void);
32 void      stat_endHeapCensus(void);
33 #endif
34
35 void      stat_startExit(void);
36 void      stat_endExit(void);
37
38 void      stat_exit(int alloc);
39 void      stat_workerStop(void);
40
41 void      initStats(void);
42
43 double    mut_user_time_during_GC(void);
44 double    mut_user_time(void);
45
46 #ifdef PROFILING
47 double    mut_user_time_during_RP(void);
48 double    mut_user_time_during_heap_census(void);
49 #endif /* PROFILING */
50
51 void      statDescribeGens( void );
52 HsInt64   getAllocations( void );
53
54 Ticks stat_getElapsedGCTime(void);
55
56 #endif /* STATS_H */