summaryrefslogtreecommitdiff
path: root/gcc/ipa-cp.c
diff options
context:
space:
mode:
authorjamborm <jamborm@138bc75d-0d04-0410-961f-82ee72b054a4>2014-12-05 11:06:26 +0000
committerjamborm <jamborm@138bc75d-0d04-0410-961f-82ee72b054a4>2014-12-05 11:06:26 +0000
commitfe3c9f1edbf0e827ee9fd20ca7bc2a9748bba960 (patch)
tree5535b89bdfdb34a70839578dacb6e9d89a13a6df /gcc/ipa-cp.c
parent5b30676162710fa4dc98dd83677fd53650732b46 (diff)
downloadgcc-fe3c9f1edbf0e827ee9fd20ca7bc2a9748bba960.tar.gz
2014-12-05 Martin Jambor <mjambor@suse.cz>
* cgraph.h (cgraph_node): New method expand_all_artificial_thunks. (cgraph_edge): New method redirect_callee_duplicating_thunks. * cgraphclones.c (duplicate_thunk_for_node): Donot expand newly created thunks. (redirect_edge_duplicating_thunks): Turned into edge method redirect_callee_duplicating_thunks. (cgraph_node::expand_all_artificial_thunks): New method. (create_clone): Call expand_all_artificial_thunks. * ipa-cp.c (perhaps_add_new_callers): Call redirect_callee_duplicating_thunks instead of redirect_callee. Also call expand_all_artificial_thunks. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@218417 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ipa-cp.c')
-rw-r--r--gcc/ipa-cp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/ipa-cp.c b/gcc/ipa-cp.c
index 3baa1158626..9b6784b8b5f 100644
--- a/gcc/ipa-cp.c
+++ b/gcc/ipa-cp.c
@@ -3912,7 +3912,8 @@ perhaps_add_new_callers (cgraph_node *node, ipcp_value<valtype> *val)
xstrdup (val->spec_node->name ()),
val->spec_node->order);
- cs->redirect_callee (val->spec_node);
+ cs->redirect_callee_duplicating_thunks (val->spec_node);
+ val->spec_node->expand_all_artificial_thunks ();
redirected_sum += cs->count;
}
cs = get_next_cgraph_edge_clone (cs);