diff options
author | Jan Hubicka <hubicka@ucw.cz> | 2017-07-07 15:28:35 +0200 |
---|---|---|
committer | Jan Hubicka <hubicka@gcc.gnu.org> | 2017-07-07 13:28:35 +0000 |
commit | 29f1e2b173f1701b66410bc3624a989e98e23724 (patch) | |
tree | b2b3db83fc40d137f7bde2edb4558d282d409c6a /gcc/ipa-inline-analysis.c | |
parent | 8b42ccf6ddfbb350776d0c1b22bddbe9ff634b48 (diff) | |
download | gcc-29f1e2b173f1701b66410bc3624a989e98e23724.zip gcc-29f1e2b173f1701b66410bc3624a989e98e23724.tar.gz gcc-29f1e2b173f1701b66410bc3624a989e98e23724.tar.bz2 |
ipa-comdats.c: Remove optimize check from gate.
* ipa-comdats.c: Remove optimize check from gate.
* ipa-fnsummary.c (ipa_fn_summary_generate): do not generate summary
for functions not optimized.
(ipa_fn_summary_read): Skip optimize check.
(ipa_fn_summary_write): Likewise.
* ipa-inline-analysis.c (do_estimate_growth_1): Check that caller
is optimized.
* ipa-inline.c (can_inline_edge_p): Not optimized functions are
uninlinable.
(can_inline_edge_p): Check flag_pcc_struct_return for match.
(check_callers): Give up on caller which is not optimized.
(inline_small_functions): Likewise.
(ipa_inline): Do not give up when not optimizing.
* ipa-visbility.c (function_and_variable_visibility): Do not optimize
away unoptimizes cdtors.
(whole_program_function_and_variable_visibility): Do
ipa_discover_readonly_nonaddressable_vars in LTO mode.
* ipa.c (process_references): Do not check optimize.
(symbol_table::remove_unreachable_nodes): Update optimize check.
(set_writeonly_bit): Update optimize check.
(pass_ipa_cdtor_merge::gate): Do not check optimize.
(pass_ipa_single_use::gate): Remove.
From-SVN: r250048
Diffstat (limited to 'gcc/ipa-inline-analysis.c')
-rw-r--r-- | gcc/ipa-inline-analysis.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/ipa-inline-analysis.c b/gcc/ipa-inline-analysis.c index 1d79ec4..38f3d2e 100644 --- a/gcc/ipa-inline-analysis.c +++ b/gcc/ipa-inline-analysis.c @@ -326,7 +326,8 @@ do_estimate_growth_1 (struct cgraph_node *node, void *data) { gcc_checking_assert (e->inline_failed); - if (cgraph_inline_failed_type (e->inline_failed) == CIF_FINAL_ERROR) + if (cgraph_inline_failed_type (e->inline_failed) == CIF_FINAL_ERROR + || !opt_for_fn (e->caller->decl, optimize)) { d->uninlinable = true; continue; |