From cadc82fc0a7a1e640bb04842769ca337dedb8c70 Mon Sep 17 00:00:00 2001 From: simonmar Date: Thu, 16 Sep 1999 12:29:55 +0000 Subject: [PATCH 1/1] [project @ 1999-09-16 12:29:55 by simonmar] Fix for DEBUG && !PROFILING --- ghc/rts/ProfHeap.c | 14 +++++++++++++- ghc/rts/ProfRts.h | 7 ++++++- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/ghc/rts/ProfHeap.c b/ghc/rts/ProfHeap.c index 2f28e58..1cbf43f 100644 --- a/ghc/rts/ProfHeap.c +++ b/ghc/rts/ProfHeap.c @@ -1,5 +1,5 @@ /* ----------------------------------------------------------------------------- - * $Id: ProfHeap.c,v 1.1 1999/09/15 13:46:28 simonmar Exp $ + * $Id: ProfHeap.c,v 1.2 1999/09/16 12:29:55 simonmar Exp $ * * (c) The GHC Team, 1998-1999 * @@ -33,6 +33,18 @@ static void fprint_data(FILE *fp); char prof_filename[128]; /* urk */ FILE *prof_file; +#ifdef DEBUG_HEAP_PROF +void initProfiling( void ) +{ + initHeapProfiling(); +} + +void endProfiling( void ) +{ + endHeapProfiling(); +} +#endif /* DEBUG_HEAP_PROF */ + nat initHeapProfiling(void) { diff --git a/ghc/rts/ProfRts.h b/ghc/rts/ProfRts.h index 870786c..883672f 100644 --- a/ghc/rts/ProfRts.h +++ b/ghc/rts/ProfRts.h @@ -1,5 +1,5 @@ /* ----------------------------------------------------------------------------- - * $Id: ProfRts.h,v 1.5 1999/09/15 13:45:18 simonmar Exp $ + * $Id: ProfRts.h,v 1.6 1999/09/16 12:29:55 simonmar Exp $ * * (c) The GHC Team, 1998-1999 * @@ -7,6 +7,11 @@ * * ---------------------------------------------------------------------------*/ +#if defined(PROFILING) || defined(DEBUG) +void initProfiling ( void ); +void endProfiling ( void ); +#endif + #ifdef PROFILING void report_ccs_profiling ( void ); -- 1.7.10.4