[project @ 1999-03-22 11:26:03 by simonm]
[ghc-hetmet.git] / ghc / rts / Updates.hc
index d3b5ba6..e40dce9 100644 (file)
@@ -1,5 +1,5 @@
 /* -----------------------------------------------------------------------------
- * $Id: Updates.hc,v 1.9 1999/02/05 16:03:03 simonm Exp $
+ * $Id: Updates.hc,v 1.11 1999/03/22 11:26:03 simonm Exp $
  *
  * (c) The GHC Team, 1998-1999
  *
@@ -333,25 +333,29 @@ EXTFUN(stg_update_PAP)
        * either the new PAP or Node.
        */
       
-      Updatee = Su->updatee; 
-      UPD_IND(Updatee,PapClosure);
-      
+      Updatee = Su->updatee;
+
+#if defined(PROFILING)
       if (Words != 0) {
+        UPD_IND(Updatee,PapClosure);
        TICK_UPD_PAP_IN_NEW(Words+1);
-       
       } else {
-       TICK_UPD_PAP_IN_PLACE();
-       
-#if defined(PROFILING)
-       /* 
-        * Lexical scoping requires a *permanent* indirection, and we
+       /* Lexical scoping requires a *permanent* indirection, and we
         * also have to set the cost centre for the indirection.
         */
-       SET_INFO(Updatee, &IND_PERM_info);
+       UPD_PERM_IND(Updatee,PapClosure);
+       TICK_UPD_PAP_IN_PLACE();
        Updatee->header.prof.ccs = CCS_pap;
-#endif /* PROFILING */
       }
-      
+#else
+      UPD_IND(Updatee,PapClosure);
+      if (Words != 0) {
+       TICK_UPD_PAP_IN_NEW(Words+1);
+      } else {
+       TICK_UPD_PAP_IN_PLACE();
+      }
+#endif 
+
 #if defined(PROFILING)
       /* 
        * Restore the Cost Centre too (if required); again see Sansom
@@ -636,7 +640,7 @@ FN_(raisezh_fast)
        break;
 
       case STOP_FRAME:
-       barf("raisezh_fast: STOP_FRAME");
+       barf("uncaught exception");
 
       default:
        barf("raisezh_fast: weird activation record");