diff options
Diffstat (limited to 'gcc/statistics.h')
-rw-r--r-- | gcc/statistics.h | 29 |
1 files changed, 21 insertions, 8 deletions
diff --git a/gcc/statistics.h b/gcc/statistics.h index 6e21e855797..8ec0a990003 100644 --- a/gcc/statistics.h +++ b/gcc/statistics.h @@ -22,20 +22,33 @@ #ifndef GCC_STATISTICS #define GCC_STATISTICS -#ifdef GATHER_STATISTICS -#define MEM_STAT_DECL , const char * ARG_UNUSED (_loc_name), int ARG_UNUSED (_loc_line), const char * ARG_UNUSED (_loc_function) -#define ALONE_MEM_STAT_DECL const char * ARG_UNUSED (_loc_name), int ARG_UNUSED (_loc_line), const char * ARG_UNUSED (_loc_function) -#define PASS_MEM_STAT , _loc_name, _loc_line, _loc_function +#if ! defined GATHER_STATISTICS +#error GATHER_STATISTICS must be defined +#endif + +#define GCC_MEM_STAT_ARGUMENTS const char * ARG_UNUSED (_loc_name), int ARG_UNUSED (_loc_line), const char * ARG_UNUSED (_loc_function) +#if GATHER_STATISTICS +#define ALONE_MEM_STAT_DECL GCC_MEM_STAT_ARGUMENTS +#define ALONE_FINAL_MEM_STAT_DECL ALONE_MEM_STAT_DECL #define ALONE_PASS_MEM_STAT _loc_name, _loc_line, _loc_function -#define MEM_STAT_INFO , __FILE__, __LINE__, __FUNCTION__ +#define ALONE_FINAL_PASS_MEM_STAT ALONE_PASS_MEM_STAT #define ALONE_MEM_STAT_INFO __FILE__, __LINE__, __FUNCTION__ +#define MEM_STAT_DECL , ALONE_MEM_STAT_DECL +#define FINAL_MEM_STAT_DECL , ALONE_FINAL_MEM_STAT_DECL +#define PASS_MEM_STAT , ALONE_PASS_MEM_STAT +#define FINAL_PASS_MEM_STAT , ALONE_FINAL_PASS_MEM_STAT +#define MEM_STAT_INFO , ALONE_MEM_STAT_INFO #else -#define MEM_STAT_DECL #define ALONE_MEM_STAT_DECL void -#define PASS_MEM_STAT +#define ALONE_FINAL_MEM_STAT_DECL GCC_MEM_STAT_ARGUMENTS #define ALONE_PASS_MEM_STAT -#define MEM_STAT_INFO +#define ALONE_FINAL_PASS_MEM_STAT 0,0,0 #define ALONE_MEM_STAT_INFO +#define MEM_STAT_DECL +#define FINAL_MEM_STAT_DECL , ALONE_FINAL_MEM_STAT_DECL +#define PASS_MEM_STAT +#define FINAL_PASS_MEM_STAT , ALONE_FINAL_PASS_MEM_STAT +#define MEM_STAT_INFO ALONE_MEM_STAT_INFO #endif struct function; |