aboutsummaryrefslogtreecommitdiff
path: root/gcc/ipa-cp.c
diff options
context:
space:
mode:
authorJan Hubicka <jh@suse.cz>2010-07-08 18:46:49 +0200
committerJan Hubicka <hubicka@gcc.gnu.org>2010-07-08 16:46:49 +0000
commit09411461d2e1d7dfcc3aed713bddc68e34ba223d (patch)
treebc5d1a43aa025755bcaa3455dd75d5fff8fd479a /gcc/ipa-cp.c
parent72109b25534c8471768fa2765bebe7c62420e059 (diff)
downloadgcc-09411461d2e1d7dfcc3aed713bddc68e34ba223d.zip
gcc-09411461d2e1d7dfcc3aed713bddc68e34ba223d.tar.gz
gcc-09411461d2e1d7dfcc3aed713bddc68e34ba223d.tar.bz2
cgraph.c (cgraph_will_be_removed_from_program_if_no_direct_calls): New function.
* cgraph.c (cgraph_will_be_removed_from_program_if_no_direct_calls): New function. * cgraph.h (cgraph_will_be_removed_from_program_if_no_direct_calls): Declare. * ipa-cp.c (ipcp_estimate_growth): Use it. * ipa-inline.c (cgraph_estimate_growth, cgraph_decide_inlining): Likewise. From-SVN: r161966
Diffstat (limited to 'gcc/ipa-cp.c')
-rw-r--r--gcc/ipa-cp.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/ipa-cp.c b/gcc/ipa-cp.c
index 8f99373..be19569 100644
--- a/gcc/ipa-cp.c
+++ b/gcc/ipa-cp.c
@@ -951,7 +951,8 @@ ipcp_estimate_growth (struct cgraph_node *node)
struct cgraph_edge *cs;
int redirectable_node_callers = 0;
int removable_args = 0;
- bool need_original = !cgraph_only_called_directly_p (node);
+ bool need_original
+ = !cgraph_will_be_removed_from_program_if_no_direct_calls (node);
struct ipa_node_params *info;
int i, count;
int growth;
@@ -1134,7 +1135,7 @@ ipcp_insert_stage (void)
for (cs = node->callers; cs != NULL; cs = cs->next_caller)
if (cs->caller == node || ipcp_need_redirect_p (cs))
break;
- if (!cs && cgraph_only_called_directly_p (node))
+ if (!cs && cgraph_will_be_removed_from_program_if_no_direct_calls (node))
bitmap_set_bit (dead_nodes, node->uid);
info = IPA_NODE_REF (node);