summaryrefslogtreecommitdiff
path: root/gcc/varasm.c
diff options
context:
space:
mode:
authorhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>2003-06-25 09:32:44 +0000
committerhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>2003-06-25 09:32:44 +0000
commit1a21f0bf8d346afab346f76b9d72110e3b61a688 (patch)
tree2e73ac97319379321a76fff87f820f4181b0d57f /gcc/varasm.c
parent9bd3def0c02b9f347476c4d825121746fab0afbe (diff)
downloadgcc-1a21f0bf8d346afab346f76b9d72110e3b61a688.tar.gz
* varasm.c (assemble_name): Mark needed variables even when
global info is ready. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@68472 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/varasm.c')
-rw-r--r--gcc/varasm.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/gcc/varasm.c b/gcc/varasm.c
index 73abd5edc8d..c2bd4b39b65 100644
--- a/gcc/varasm.c
+++ b/gcc/varasm.c
@@ -1747,14 +1747,17 @@ assemble_name (file, name)
id = maybe_get_identifier (real_name);
if (id)
{
- if (!TREE_SYMBOL_REFERENCED (id)
- && !cgraph_global_info_ready)
+ if (!TREE_SYMBOL_REFERENCED (id))
{
- struct cgraph_node *node = cgraph_node_for_identifier (id);
+ struct cgraph_node *node;
struct cgraph_varpool_node *vnode;
- if (node)
- cgraph_mark_needed_node (node, 1);
+ if (!cgraph_global_info_ready)
+ {
+ node = cgraph_node_for_identifier (id);
+ if (node)
+ cgraph_mark_needed_node (node, 1);
+ }
vnode = cgraph_varpool_node_for_identifier (id);
if (vnode)