From patchwork Thu Oct 7 10:54:50 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: LTO plugin and comdat symbols Date: Thu, 07 Oct 2010 00:54:50 -0000 From: Jan Hubicka X-Patchwork-Id: 67029 Message-Id: <20101007105450.GB31320@kam.mff.cuni.cz> To: "H.J. Lu" Cc: Jan Hubicka , ccoutant@google.com, iant@google.com, tglek@mozilla.com, rguenther@suse.de, gcc-patches@gcc.gnu.org, dnovillo@google.com > > The ipa.c changes caused: > > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45926 Hi, I reverted the cgraph_remove_unreachable_nodes hunk. It originally wasn't supposed to be in the patch, I must've grabbed earlier version of it (it also explains why I had to re-write changelog). The change is correct, however gomp code keeps functions without properly inserting them to callgraph across some time so I will submit separate patch for this. My apologizes for the breakage. Honza Index: ChangeLog =================================================================== --- ChangeLog (revision 165089) +++ ChangeLog (working copy) @@ -1,3 +1,8 @@ +2010-10-07 Jan Hubicka + + PR middle-end/45926 + * ipa.c (cgraph_remove_unreachable_nodes): Revert my previous patch. + 2010-10-07 Richard Guenther PR bootstrap/45914 Index: ipa.c =================================================================== --- ipa.c (revision 165088) +++ ipa.c (working copy) @@ -238,19 +238,14 @@ cgraph_remove_unreachable_nodes (bool be #endif varpool_reset_queue (); for (node = cgraph_nodes; node; node = node->next) - if (!node->analyzed) - { - gcc_assert (!node->aux); - node->reachable = false; - } - else if ((!cgraph_can_remove_if_no_direct_calls_and_refs_p (node) - /* Keep around virtual functions for possible devirtualization. */ - || (!before_inlining_p - && !node->global.inlined_to - && DECL_VIRTUAL_P (node->decl) - && (DECL_COMDAT (node->decl) || DECL_EXTERNAL (node->decl)))) - && ((!DECL_EXTERNAL (node->decl)) - || before_inlining_p)) + if ((!cgraph_can_remove_if_no_direct_calls_and_refs_p (node) + /* Keep around virtual functions for possible devirtualization. */ + || (!before_inlining_p + && !node->global.inlined_to + && DECL_VIRTUAL_P (node->decl) + && (DECL_COMDAT (node->decl) || DECL_EXTERNAL (node->decl)))) + && ((!DECL_EXTERNAL (node->decl)) + || before_inlining_p)) { gcc_assert (!node->global.inlined_to); enqueue_cgraph_node (node, &first);