diff options
author | hubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-07-08 14:20:23 +0000 |
---|---|---|
committer | hubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-07-08 14:20:23 +0000 |
commit | ced14259dafe3918bebc987e342d4c371249b681 (patch) | |
tree | b48a07adef9b35b2300676942bad2b110175cd69 /gcc/cgraph.c | |
parent | 75cc9a88cb1d2e54d9d64e696f9435007be8d1bd (diff) | |
download | gcc-ced14259dafe3918bebc987e342d4c371249b681.tar.gz |
* ipa.c: Include pointer-set.h
(cgraph_externally_visible_p): New attribute ALIASED;
when in LTO, hidden symbols are local unless they are aliased.
(function_and_variable_visibility): Compute aliased nodes;
handle LTO and hidden symbol on functions and vars.
* cgraph.c (cgraph_make_decl_local): Clear NAMED_SECTION
for COMDAT symbols; handle COMDAT_GROUPS also at vars.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@161957 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cgraph.c')
-rw-r--r-- | gcc/cgraph.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/gcc/cgraph.c b/gcc/cgraph.c index 37367695606..33653df1549 100644 --- a/gcc/cgraph.c +++ b/gcc/cgraph.c @@ -2455,15 +2455,16 @@ cgraph_make_decl_local (tree decl) if (TREE_CODE (decl) == VAR_DECL) DECL_COMMON (decl) = 0; - else if (TREE_CODE (decl) == FUNCTION_DECL) + else gcc_assert (TREE_CODE (decl) == FUNCTION_DECL); + + if (DECL_COMDAT (decl)) { + DECL_SECTION_NAME (decl) = 0; DECL_COMDAT (decl) = 0; - DECL_COMDAT_GROUP (decl) = 0; - DECL_WEAK (decl) = 0; - DECL_EXTERNAL (decl) = 0; } - else - gcc_unreachable (); + DECL_COMDAT_GROUP (decl) = 0; + DECL_WEAK (decl) = 0; + DECL_EXTERNAL (decl) = 0; TREE_PUBLIC (decl) = 0; if (!DECL_RTL_SET_P (decl)) return; |