Don't call processHeapClosureForDead on pinned blocks
authorSimon Marlow <marlowsd@gmail.com>
Mon, 16 Mar 2009 16:05:34 +0000 (16:05 +0000)
committerSimon Marlow <marlowsd@gmail.com>
Mon, 16 Mar 2009 16:05:34 +0000 (16:05 +0000)
Fixes heapprof001(prof_hp) after fix for #2917

rts/LdvProfile.c

index 6a807cf..eab3ec3 100644 (file)
@@ -266,7 +266,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;
     }
 }