[Bug debug/51650] [4.7 regression] LTO ICE in dwarf2out_finish, at dwarf2out.c:22501 while building libxul
rguenth at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Jan 2 15:53:00 GMT 2012
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51650
--- Comment #21 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-01-02 15:52:45 UTC ---
(In reply to comment #20)
>
> Fortunately it seems that this bug was the last issue that needed to be fixed.
> Firefox now builds fine with -lto and -g.
Can you also check the following variant?
Index: gcc/dwarf2out.c
===================================================================
--- gcc/dwarf2out.c (revision 182784)
+++ gcc/dwarf2out.c (working copy)
@@ -22501,15 +22501,8 @@ dwarf2out_finish (const char *filename)
else if (TYPE_P (node->created_for))
context = TYPE_CONTEXT (node->created_for);
- gcc_assert (context
- && (TREE_CODE (context) == FUNCTION_DECL
- || TREE_CODE (context) == NAMESPACE_DECL));
-
- origin = lookup_decl_die (context);
- if (origin)
- add_child_die (origin, die);
- else
- add_child_die (comp_unit_die (), die);
+ origin = get_context_die (context);
+ add_child_die (origin, die);
}
}
}
More information about the Gcc-bugs
mailing list