[project @ 1996-07-25 20:43:49 by partain]
[ghc-hetmet.git] / ghc / runtime / storage / SM1s.lc
index 85919b0..57822b5 100644 (file)
@@ -122,22 +122,32 @@ collectHeap(reqsize, sm, do_full_collection)
     /* end of bracket */
 
 #ifndef PAR
-    sweepUpDeadMallocPtrs(sm->MallocPtrList, 
-                         compactingInfo.base, 
-                         compactingInfo.bits );
+    sweepUpDeadForeignObjs(sm->ForeignObjList, 
+                          compactingInfo.base, 
+                          compactingInfo.bits );
 #endif
 
     LinkCAFs(sm->CAFlist);
 
     LinkRoots( sm->roots, sm->rootno );
-#ifdef CONCURRENT
+#if defined(GRAN)
+    LinkEvents();
+#endif
+#if defined(CONCURRENT)
     LinkSparks();
 #endif
 #ifdef PAR
     LinkLiveGAs(compactingInfo.base, compactingInfo.bits);
 #else
+    /*
+      The stable pointer table is reachable via sm->roots,
+      (Reason: in markHeapRoots all roots have to be considered,
+      including the StablePointerTable)
+
     DEBUG_STRING("Linking Stable Pointer Table:");
     LINK_LOCATION_TO_CLOSURE(&sm->StablePointerTable);
+
+    */
     LinkAStack( MAIN_SpA, stackInfo.botA );
     LinkBStack( MAIN_SuB, stackInfo.botB );
 #endif /* parallel */
@@ -151,7 +161,7 @@ collectHeap(reqsize, sm, do_full_collection)
                                compactingInfo.bits,
                                compactingInfo.bit_words
 #if ! defined(PAR)
-                               , &(sm->MallocPtrList)
+                               , &(sm->ForeignObjList)
 #endif
                                ) - 1;