Don't init root pointers if they aren't gonna be used.
authorLemmih <lemmih@gmail.com>
Wed, 26 Apr 2006 11:11:43 +0000 (11:11 +0000)
committerLemmih <lemmih@gmail.com>
Wed, 26 Apr 2006 11:11:43 +0000 (11:11 +0000)
rts/Linker.c

index 0db2c5e..e1be5e6 100644 (file)
@@ -856,7 +856,7 @@ static void
 addRootObject(void *addr)
 {
   StgWord rt;
-
+  initRootPtrTable();
   if (root_ptr_free == NULL) {
     enlargeRootPtrTable();
   }
@@ -954,7 +954,6 @@ initLinker( void )
       linker_init_done = 1;
     }
 
-    initRootPtrTable();
     stablehash = allocStrHashTable();
     symhash = allocStrHashTable();