summaryrefslogtreecommitdiff
path: root/gcc/ipa-inline-transform.c
diff options
context:
space:
mode:
authorhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>2014-05-21 05:41:46 +0000
committerhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>2014-05-21 05:41:46 +0000
commit7c5c01f175739331175300e95ba9c0e3135be01f (patch)
tree4b9f247bf7f2f748f5c2c735e1b8ccd0f27c1d99 /gcc/ipa-inline-transform.c
parent4206bfac538b8498b0db386ea864bfa3ffc5b3c9 (diff)
downloadgcc-7c5c01f175739331175300e95ba9c0e3135be01f.tar.gz
PR bootstrap/60984
* ipa-inline-transform.c (inline_call): Use add CALLEE_REMOVED parameter. * ipa-inline.c (inline_to_all_callers): If callee was removed; return. (ipa_inline): Loop inline_to_all_callers until no more aliases are removed. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@210674 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ipa-inline-transform.c')
-rw-r--r--gcc/ipa-inline-transform.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/ipa-inline-transform.c b/gcc/ipa-inline-transform.c
index 7cd3ff740e0..82fe839b380 100644
--- a/gcc/ipa-inline-transform.c
+++ b/gcc/ipa-inline-transform.c
@@ -215,6 +215,7 @@ clone_inlined_nodes (struct cgraph_edge *e, bool duplicate,
it is NULL. If UPDATE_OVERALL_SUMMARY is false, do not bother to recompute overall
size of caller after inlining. Caller is required to eventually do it via
inline_update_overall_summary.
+ If callee_removed is non-NULL, set it to true if we removed callee node.
Return true iff any new callgraph edges were discovered as a
result of inlining. */
@@ -222,7 +223,8 @@ clone_inlined_nodes (struct cgraph_edge *e, bool duplicate,
bool
inline_call (struct cgraph_edge *e, bool update_original,
vec<cgraph_edge_p> *new_edges,
- int *overall_size, bool update_overall_summary)
+ int *overall_size, bool update_overall_summary,
+ bool *callee_removed)
{
int old_size = 0, new_size = 0;
struct cgraph_node *to = NULL;
@@ -261,6 +263,8 @@ inline_call (struct cgraph_edge *e, bool update_original,
{
next_alias = cgraph_alias_target (alias);
cgraph_remove_node (alias);
+ if (callee_removed)
+ *callee_removed = true;
alias = next_alias;
}
else