Remove vectored returns.
[ghc-hetmet.git] / rts / sm / Evac.c
index 6ffe167..dda5659 100644 (file)
@@ -4,6 +4,11 @@
  *
  * Generational garbage collector: evacuation functions
  *
+ * Documentation on the architecture of the Garbage Collector can be
+ * found in the online commentary:
+ * 
+ *   http://hackage.haskell.org/trac/ghc/wiki/Commentary/Rts/Storage/GC
+ *
  * ---------------------------------------------------------------------------*/
 
 #include "Rts.h"
@@ -541,9 +546,7 @@ loop:
 
   case RET_BCO:
   case RET_SMALL:
-  case RET_VEC_SMALL:
   case RET_BIG:
-  case RET_VEC_BIG:
   case RET_DYN:
   case UPDATE_FRAME:
   case STOP_FRAME:
@@ -841,6 +844,14 @@ selector_loop:
          if (thunk_selector_depth >= MAX_THUNK_SELECTOR_DEPTH) {
              break;
          }
+
+         // we don't update THUNK_SELECTORS in the compacted
+         // generation, because compaction does not remove the INDs
+         // that result, this causes confusion later.
+         if (Bdescr((P_)selectee)->flags && BF_COMPACTED) {
+             break;
+         }
+
          thunk_selector_depth++;
 
          val = eval_thunk_selector(info->layout.selector_offset,