re PR bootstrap/65150 (r220875 causes bootstrap failure on x86_64 darwin)
authorJan Hubicka <hubicka@ucw.cz>
Fri, 27 Feb 2015 02:06:48 +0000 (03:06 +0100)
committerJan Hubicka <hubicka@gcc.gnu.org>
Fri, 27 Feb 2015 02:06:48 +0000 (02:06 +0000)
commit0a7246ee3887147e6934684ecf768ebe929a975e
tree64340fdd45bcc8e11f6dbe5c80f68a86cce6c1fa
parentf91f1c1312beaf16da0d12feea1696c91cb5f0a7
re PR bootstrap/65150 (r220875 causes bootstrap failure on x86_64 darwin)

PR bootstrap/65150
* ipa-icf.c (symbol_compare_collection::symbol_compare_colleciton):
Use address_matters_p.
(redirect_all_callers, set_addressable): New functions.
(sem_function::merge): Reorganize and fix merging issues.
(sem_variable::merge): Likewise.
(sem_variable::compare_sections): Remove.
* common.opt (fmerge-all-constants, fmerge-constants): Remove
Optimization flag.
* symtab.c (symtab_node::resolve_alias): When alias has aliases,
redirect them.
(symtab_node::make_decl_local): Set ADDRESSABLE bit when
decl is used.
(address_matters_1): New function.
(symtab_node::address_matters_p): New function.
* cgraph.c (cgraph_edge::verify_corresponds_to_fndecl): Fix
check for merged flag.
* cgraph.h (address_matters_p): Declare.
(symtab_node::address_taken_from_non_vtable_p): Remove.
(symtab_node::address_can_be_compared_p): New method.
(ipa_ref::address_matters_p): Move here from ipa-ref.c; simplify.
* ipa-visibility.c (symtab_node::address_taken_from_non_vtable_p):
Remove.
(comdat_can_be_unshared_p_1) Use address_matters_p.
(update_vtable_references): Fix formating.
* ipa-ref.c (ipa_ref::address_matters_p): Move inline.
* cgraphunit.c (cgraph_node::create_wrapper): Drop UNINLINABLE flag.
* cgraphclones.c: Preserve merged and icf_merged flags.

Co-Authored-By: Martin Liska <mliska@suse.cz>
From-SVN: r221040
18 files changed:
gcc/ChangeLog
gcc/cgraph.c
gcc/cgraph.h
gcc/cgraphclones.c
gcc/cgraphunit.c
gcc/common.opt
gcc/ipa-icf.c
gcc/ipa-ref.c
gcc/ipa-visibility.c
gcc/symtab.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/ipa/ipa-icf-4.C
gcc/testsuite/g++.dg/warn/Wsuggest-final.C
gcc/testsuite/gcc.dg/ipa/iinline-5.c
gcc/testsuite/gcc.dg/ipa/ipa-cp-1.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/ipa/ipa-cp-2.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/pr28685-1.c
gcc/testsuite/gcc.dg/pr64454.c