X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=includes%2Fstg%2FTicky.h;h=a811aec4ebfb94385da4d44dafaa581aab02bbae;hb=aee44bbe090c356d649398a93e260d967a7c50db;hp=001ab973f7aff4529999a8dd5bc82d725173b1e0;hpb=d20d32d788e2d6c088e6b03776c428df5bb004d3;p=ghc-hetmet.git diff --git a/includes/stg/Ticky.h b/includes/stg/Ticky.h index 001ab97..a811aec 100644 --- a/includes/stg/Ticky.h +++ b/includes/stg/Ticky.h @@ -17,12 +17,26 @@ /* These should probably be automatically generated in order to keep them consistent with the macros that use them (which are - defined in Cmm.h. */ + defined in Cmm.h) */ -#ifdef TICKY_TICKY -/* same trick as in the former StgTicky.h: recycle the same declarations - for both extern decls (which are included everywhere) - and initializations (which only happen once) */ +/* Here are all the counter declarations: */ +/* If you change this list, make the corresponding change + in RTS_TICKY_SYMBOLS in rts/Linker.c */ + +/* These two are explicitly declared in rts/Ticky.c, and + hence should not be extern'd except when using this header + file from STG code; hence IN_STG_CODE */ + +#if IN_STG_CODE +extern W_ ticky_entry_ctrs[]; +extern W_ top_ct[]; +#endif + +/* The rest are not explicity declared in rts/Ticky.c. Instead + we use the same trick as in the former StgTicky.h: recycle the + same declarations for both extern decls (which are included everywhere) + and initializations (which only happen once) + TICKY_C is defined only in rts/Ticky.c */ #ifdef TICKY_C #define INIT(ializer) = ializer #define EXTERN @@ -31,8 +45,6 @@ #define EXTERN extern #endif -/* Here are all the counter declarations: */ - EXTERN StgInt ENT_VIA_NODE_ctr INIT(0); EXTERN StgInt ENT_STATIC_THK_ctr INIT(0); EXTERN StgInt ENT_DYN_THK_ctr INIT(0); @@ -118,8 +130,6 @@ EXTERN StgInt GC_SEL_MAJOR_ctr INIT(0); EXTERN StgInt GC_FAILED_PROMOTION_ctr INIT(0); -EXTERN StgInt GC_WORDS_COPIED_ctr INIT(0); - EXTERN StgInt ALLOC_UP_THK_ctr INIT(0); EXTERN StgInt ALLOC_SE_THK_ctr INIT(0); EXTERN StgInt ALLOC_THK_adm INIT(0); @@ -164,8 +174,6 @@ EXTERN StgInt RET_SEMI_loads_avoided INIT(0); /* End of counter declarations. */ -#endif /* TICKY_TICKY */ - /* This is ugly, but the story is: We got rid of StgTicky.h, which was previously defining these macros for the benefit of C code @@ -181,9 +189,9 @@ EXTERN StgInt RET_SEMI_loads_avoided INIT(0); #define TICK_UPD_NEW_IND() #define TICK_UPD_SQUEEZED() #define TICK_ALLOC_HEAP_NOCTR(x) -#define TICK_GC_WORDS_COPIED(x) #define TICK_GC_FAILED_PROMOTION() -#define TICK_ALLOC_TSO(g,s) +#define TICK_ALLOC_TSO() +#define TICK_ALLOC_STACK(g) #define TICK_ALLOC_UP_THK(g,s) #define TICK_ALLOC_SE_THK(g,s)