From 5fb52815fa7aef4a4793eb58a909bd5465b77bb4 Mon Sep 17 00:00:00 2001 From: Simon Marlow Date: Mon, 7 Dec 2009 11:53:59 +0000 Subject: [PATCH] remove global 'total_allocated', seems to be the same as 'GC_tot_alloc' --- rts/Stats.c | 2 +- rts/sm/Storage.c | 3 --- rts/sm/Storage.h | 2 -- 3 files changed, 1 insertion(+), 6 deletions(-) diff --git a/rts/Stats.c b/rts/Stats.c index b1061de..20de32a 100644 --- a/rts/Stats.c +++ b/rts/Stats.c @@ -813,7 +813,7 @@ statDescribeGens(void) -------------------------------------------------------------------------- */ extern HsInt64 getAllocations( void ) -{ return (HsInt64)total_allocated * sizeof(W_); } +{ return (HsInt64)GC_tot_alloc * sizeof(W_); } /* ----------------------------------------------------------------------------- Dumping stuff in the stats file, or via the debug message interface diff --git a/rts/sm/Storage.c b/rts/sm/Storage.c index 4498bda..781234a 100644 --- a/rts/sm/Storage.c +++ b/rts/sm/Storage.c @@ -49,8 +49,6 @@ generation *generations = NULL; /* all the generations */ generation *g0 = NULL; /* generation 0, for convenience */ generation *oldest_gen = NULL; /* oldest generation, for convenience */ -ullong total_allocated = 0; /* total memory allocated during run */ - nursery *nurseries = NULL; /* array of nurseries, size == n_capabilities */ #ifdef THREADED_RTS @@ -789,7 +787,6 @@ calcAllocated( void ) allocated += g0->n_new_large_blocks * BLOCK_SIZE_W; - total_allocated += allocated; return allocated; } diff --git a/rts/sm/Storage.h b/rts/sm/Storage.h index 6dbccd8..f8532e0 100644 --- a/rts/sm/Storage.h +++ b/rts/sm/Storage.h @@ -132,8 +132,6 @@ lnat countNurseryBlocks ( void ); Stats 'n' DEBUG stuff -------------------------------------------------------------------------- */ -extern ullong total_allocated; - lnat calcAllocated (void); lnat calcLiveBlocks (void); lnat calcLiveWords (void); -- 1.7.10.4