remove empty dir
[ghc-hetmet.git] / ghc / rts / RetainerSet.c
index 6834676..bfa0bc8 100644 (file)
@@ -1,5 +1,4 @@
 /* -----------------------------------------------------------------------------
- * $Id: RetainerSet.c,v 1.4 2003/03/25 17:58:49 sof Exp $
  *
  * (c) The GHC Team, 2001
  * Author: Sungwoo Park
@@ -10,8 +9,6 @@
 
 #ifdef PROFILING
 
-#include <stdlib.h>
-
 #include "Rts.h"
 #include "RtsFlags.h"
 #include "Stats.h"
@@ -20,6 +17,7 @@
 #include "Arena.h"
 #include "Profiling.h"
 
+#include <stdlib.h>
 #include <string.h>
 
 #define HASH_TABLE_SIZE 255
@@ -52,7 +50,7 @@ RetainerSet rs_MANY = {
 /* -----------------------------------------------------------------------------
  * calculate the size of a RetainerSet structure
  * -------------------------------------------------------------------------- */
-static inline size_t
+STATIC_INLINE size_t
 sizeofRetainerSet( int elems )
 {
     return (sizeof(RetainerSet) + elems * sizeof(retainer));
@@ -90,7 +88,7 @@ refreshAllRetainerSet(void)
     for (i = 0; i < HASH_TABLE_SIZE; i++)
        hashTable[i] = NULL;
     nextId = 2;
-#endif // FIRST_APPROACH
+#endif /* FIRST_APPROACH */
 }
 
 /* -----------------------------------------------------------------------------
@@ -148,7 +146,7 @@ addElement(retainer r, RetainerSet *rs)
     StgWord hk;         // Hash Key
 
 #ifdef DEBUG_RETAINER
-    // fprintf(stderr, "addElement(%p, %p) = ", r, rs);
+    // debugBelch("addElement(%p, %p) = ", r, rs);
 #endif
 
     ASSERT(rs != NULL);
@@ -188,7 +186,7 @@ addElement(retainer r, RetainerSet *rs)
        if (i < rs->num) continue;
 
 #ifdef DEBUG_RETAINER
-       // fprintf(stderr, "%p\n", nrs);
+       // debugBelch("%p\n", nrs);
 #endif
        // The set we are seeking already exists!
        return nrs;
@@ -211,7 +209,7 @@ addElement(retainer r, RetainerSet *rs)
     hashTable[hash(hk)] = nrs;
 
 #ifdef DEBUG_RETAINER
-    // fprintf(stderr, "%p\n", nrs);
+    // debugBelch("%p\n", nrs);
 #endif
     return nrs;
 }
@@ -495,6 +493,6 @@ outputAllRetainerSet(FILE *prof_file)
 
     stgFree(rsArray);
 }
-#endif // SECOND_APPROACH
+#endif /* SECOND_APPROACH */
 
 #endif /* PROFILING */