------- Comment #19 from pinskia at gcc dot gnu dot org  2008-02-15 21:29 
-------
I don't know if this is the correct patch but we made this for the PS3
toolchain:
Index: gcc/cgraph.c
===================================================================
--- gcc/cgraph.c        (revision 2280)
+++ gcc/cgraph.c        (working copy)
@@ -476,14 +476,16 @@
       if (!n->next_clone && !n->global.inlined_to
          && (cgraph_global_info_ready
              && (TREE_ASM_WRITTEN (n->decl) || DECL_EXTERNAL (n->decl))))
-       kill_body = true;
+       {
+         DECL_INITIAL (node->decl) = error_mark_node;
+         kill_body = true;
+       }
     }

   if (kill_body && !dump_enabled_p (TDI_tree_all) && flag_unit_at_a_time)
     {
       DECL_SAVED_TREE (node->decl) = NULL;
       DECL_STRUCT_FUNCTION (node->decl) = NULL;
-      DECL_INITIAL (node->decl) = error_mark_node;
     }
   cgraph_n_nodes--;
   /* Do not free the structure itself so the walk over chain can continue.  */


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27574

Reply via email to