[Bug bootstrap/54876] [4.8 Regression] LTO bootstrap broken, streaming garbage-collected BLOCK

rguenth at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Tue Oct 9 15:24:00 GMT 2012


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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|                            |2012-10-09
         AssignedTo|unassigned at gcc dot       |rguenth at gcc dot gnu.org
                   |gnu.org                     |
   Target Milestone|---                         |4.8.0
     Ever Confirmed|0                           |1

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> 2012-10-09 15:24:26 UTC ---
Like the following:

Index: gcc/ipa-prop.c
===================================================================
--- gcc/ipa-prop.c      (revision 192255)
+++ gcc/ipa-prop.c      (working copy)
@@ -287,6 +287,16 @@ ipa_print_all_jump_functions (FILE *f)
     }
 }

+/* Worker for prune_expression_for_jf.  */
+
+static tree
+prune_expression_for_jf_1 (tree *tp, int *, void *)
+{
+  if (EXPR_P (*tp))
+    SET_EXPR_LOCATION (*tp, UNKNOWN_LOCATION);
+  return *tp;
+}
+
 /* Return the expression tree EXPR unshared and with location stripped off. 
*/

 static tree
@@ -295,7 +305,7 @@ prune_expression_for_jf (tree exp)
   if (EXPR_P (exp))
     {
       exp = unshare_expr (exp);
-      SET_EXPR_LOCATION (exp, UNKNOWN_LOCATION);
+      walk_tree (&exp, prune_expression_for_jf_1, NULL, NULL);
     }
   return exp;
 }


not sure if we shouldn't simply bite the bullet and identify whether we
stream to a non-function section and drop LOCATION_BLOCK there during
streaming itself.

Testing the above now.



More information about the Gcc-bugs mailing list