X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=rts%2FLdvProfile.c;h=a1eef17ef16385c351ed5418d497815ddf8f197a;hb=95d4b4c552cef8a33bbfb37361e90c079d65134b;hp=0cd80dee6504b5cf0924f765b1f3eaf31885ca83;hpb=4e79709df545c16812b85f2c27ab3411f5a7b54f;p=ghc-hetmet.git diff --git a/rts/LdvProfile.c b/rts/LdvProfile.c index 0cd80de..a1eef17 100644 --- a/rts/LdvProfile.c +++ b/rts/LdvProfile.c @@ -9,10 +9,11 @@ #ifdef PROFILING +#include "PosixSource.h" #include "Rts.h" -#include "LdvProfile.h" -#include "RtsFlags.h" + #include "Profiling.h" +#include "LdvProfile.h" #include "Stats.h" #include "RtsUtils.h" #include "Schedule.h" @@ -143,9 +144,7 @@ processHeapClosureForDead( StgClosure *c ) case FUN_1_1: case FUN_0_2: case BLACKHOLE: - case SE_BLACKHOLE: case CAF_BLACKHOLE: - case SE_CAF_BLACKHOLE: case IND_PERM: case IND_OLDGEN_PERM: /* @@ -181,11 +180,6 @@ processHeapClosureForDead( StgClosure *c ) case RET_SMALL: case RET_BIG: // others - case BLOCKED_FETCH: - case FETCH_ME: - case FETCH_ME_BQ: - case RBH: - case REMOTE_REF: case INVALID_OBJECT: default: barf("Invalid object in processHeapClosureForDead(): %d", info->type); @@ -239,27 +233,6 @@ processNurseryForDead( void ) } /* -------------------------------------------------------------------------- - * Calls processHeapClosureForDead() on every *dead* closures in the - * small object pool. - * ----------------------------------------------------------------------- */ -static void -processSmallObjectPoolForDead( void ) -{ - bdescr *bd; - StgPtr p; - - for (bd = g0s0->blocks; bd != NULL; bd = bd->link) { - p = bd->start; - while (p < bd->free) { - p += processHeapClosureForDead((StgClosure *)p); - while (p < bd->free && !*p) // skip slop - p++; - } - ASSERT(p == bd->free); - } -} - -/* -------------------------------------------------------------------------- * Calls processHeapClosureForDead() on every *dead* closures in the closure * chain. * ----------------------------------------------------------------------- */ @@ -268,7 +241,9 @@ processChainForDead( bdescr *bd ) { // Any object still in the chain is dead! while (bd != NULL) { - processHeapClosureForDead((StgClosure *)bd->start); + if (!(bd->flags & BF_PINNED)) { + processHeapClosureForDead((StgClosure *)bd->start); + } bd = bd->link; } } @@ -299,7 +274,6 @@ LdvCensusForDead( nat N ) for (g = 0; g <= N; g++) for (s = 0; s < generations[g].n_steps; s++) { if (g == 0 && s == 0) { - processSmallObjectPoolForDead(); processNurseryForDead(); processChainForDead(generations[g].steps[s].large_objects); } else{