diff options
author | hubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-05-31 14:15:17 +0000 |
---|---|---|
committer | hubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-05-31 14:15:17 +0000 |
commit | 58d2f5dd18510e9a154ee8fd00c814f077377862 (patch) | |
tree | fd069a429f6093d8222809c6eda3e12d2e21c6e6 /gcc/lto-symtab.c | |
parent | 5a7fda1a5c1e9246f9ec9e7f9537f88665260214 (diff) | |
download | gcc-58d2f5dd18510e9a154ee8fd00c814f077377862.tar.gz |
* lto-symtab.c (lto_symtab_merge_cgraph_nodes): Merge alias decl
of thunks.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@174482 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/lto-symtab.c')
-rw-r--r-- | gcc/lto-symtab.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/gcc/lto-symtab.c b/gcc/lto-symtab.c index 8dc10e8e6c5..af8106de94f 100644 --- a/gcc/lto-symtab.c +++ b/gcc/lto-symtab.c @@ -821,11 +821,15 @@ lto_symtab_merge_cgraph_nodes (void) htab_traverse (lto_symtab_identifiers, lto_symtab_merge_cgraph_nodes_1, NULL); for (node = cgraph_nodes; node; node = node->next) - for (alias = node->same_body; alias; alias = next) - { - next = alias->next; - alias->thunk.alias = lto_symtab_prevailing_decl (alias->thunk.alias); - } + { + if (node->thunk.thunk_p) + node->thunk.alias = lto_symtab_prevailing_decl (node->thunk.alias); + for (alias = node->same_body; alias; alias = next) + { + next = alias->next; + alias->thunk.alias = lto_symtab_prevailing_decl (alias->thunk.alias); + } + } } /* Given the decl DECL, return the prevailing decl with the same name. */ |