diff options
author | rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2016-10-20 08:49:48 +0000 |
---|---|---|
committer | rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2016-10-20 08:49:48 +0000 |
commit | c72bf91129c519f36686434ed4f1d7114201e104 (patch) | |
tree | eaf4fefd23878ee067a9f658dce72d2897a8686e /gcc/ipa.c | |
parent | ad6502915190926311669afa0cfb73a5ab65035c (diff) | |
download | gcc-c72bf91129c519f36686434ed4f1d7114201e104.tar.gz |
2016-10-20 Richard Biener <rguenther@suse.de>
* cgraphunit.c (analyze_functions): Set node->definition to
false to signal symbol removal to debug_hooks->late_global_decl.
* ipa.c (symbol_table::remove_unreachable_nodes): When not in
WPA signal symbol removal to the debuginfo machinery.
* dwarf2out.c (dwarf2out_late_global_decl): Instead of
using early_finised to guard the we're called for symbol
removal case look at the symtabs definition flag.
(gen_variable_die): Remove redundant check.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@241363 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ipa.c')
-rw-r--r-- | gcc/ipa.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/ipa.c b/gcc/ipa.c index e20e4953e8f..879d9c249cd 100644 --- a/gcc/ipa.c +++ b/gcc/ipa.c @@ -36,6 +36,7 @@ along with GCC; see the file COPYING3. If not see #include "ipa-prop.h" #include "ipa-inline.h" #include "dbgcnt.h" +#include "debug.h" /* Return true when NODE has ADDR reference. */ @@ -622,6 +623,12 @@ symbol_table::remove_unreachable_nodes (FILE *file) if (file) fprintf (file, " %s/%i", vnode->name (), vnode->order); vnext = next_variable (vnode); + /* Signal removal to the debug machinery. */ + if (! flag_wpa) + { + vnode->definition = false; + (*debug_hooks->late_global_decl) (vnode->decl); + } vnode->remove (); changed = true; } |