diff options
author | Dehao Chen <dehao@google.com> | 2014-05-20 22:25:06 +0000 |
---|---|---|
committer | Dehao Chen <dehao@gcc.gnu.org> | 2014-05-20 22:25:06 +0000 |
commit | 983398517e18629db71d6a75bc7e50c3df44b3d4 (patch) | |
tree | 1bd8a95838906705bcd87c8109dcd41dccc7f970 /gcc/ipa-inline-transform.c | |
parent | 6ed9c90a5db18fa72928d77d47c0159f75486b45 (diff) | |
download | gcc-983398517e18629db71d6a75bc7e50c3df44b3d4.zip gcc-983398517e18629db71d6a75bc7e50c3df44b3d4.tar.gz gcc-983398517e18629db71d6a75bc7e50c3df44b3d4.tar.bz2 |
ipa-inline-transform.c (clone_inlined_nodes): Use min of edge count and callee count to get clone count.
2014-05-20 Dehao Chen <dehao@google.com>
* ipa-inline-transform.c (clone_inlined_nodes): Use min of edge count
and callee count to get clone count.
* tree-inline.c (expand_call_inline): Use callee count instead of bb
count in copy_body.
From-SVN: r210660
Diffstat (limited to 'gcc/ipa-inline-transform.c')
-rw-r--r-- | gcc/ipa-inline-transform.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/ipa-inline-transform.c b/gcc/ipa-inline-transform.c index a45aab1..7cd3ff7 100644 --- a/gcc/ipa-inline-transform.c +++ b/gcc/ipa-inline-transform.c @@ -183,8 +183,9 @@ clone_inlined_nodes (struct cgraph_edge *e, bool duplicate, if (freq_scale == -1) freq_scale = e->frequency; n = cgraph_clone_node (e->callee, e->callee->decl, - e->count, freq_scale, update_original, - vNULL, true, inlining_into, NULL); + MIN (e->count, e->callee->count), freq_scale, + update_original, vNULL, true, inlining_into, + NULL); cgraph_redirect_edge_callee (e, n); } } |