aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-loop-im.c
diff options
context:
space:
mode:
authorRichard Biener <rguenther@suse.de>2016-05-18 12:32:46 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2016-05-18 12:32:46 +0000
commit524c2492c505c5bd6f0ec0e6752f7aef8cfbfc05 (patch)
treebc8290796438facfda1f1add132a2e4268657953 /gcc/tree-ssa-loop-im.c
parentcf087b415c8e72e07a5024ff24e29e859b2747e5 (diff)
downloadgcc-524c2492c505c5bd6f0ec0e6752f7aef8cfbfc05.zip
gcc-524c2492c505c5bd6f0ec0e6752f7aef8cfbfc05.tar.gz
gcc-524c2492c505c5bd6f0ec0e6752f7aef8cfbfc05.tar.bz2
tree-ssa-loop-im.c (determine_max_movement): Properly add condition cost to PHI cost instead of total_cost.
2016-05-18 Richard Biener <rguenther@suse.de> * tree-ssa-loop-im.c (determine_max_movement): Properly add condition cost to PHI cost instead of total_cost. From-SVN: r236376
Diffstat (limited to 'gcc/tree-ssa-loop-im.c')
-rw-r--r--gcc/tree-ssa-loop-im.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/tree-ssa-loop-im.c b/gcc/tree-ssa-loop-im.c
index ec0fb7f..b9cd0f6 100644
--- a/gcc/tree-ssa-loop-im.c
+++ b/gcc/tree-ssa-loop-im.c
@@ -717,7 +717,7 @@ determine_max_movement (gimple *stmt, bool must_preserve_exec)
return false;
def_data = get_lim_data (SSA_NAME_DEF_STMT (val));
if (def_data)
- total_cost += def_data->cost;
+ lim_data->cost += def_data->cost;
}
/* We want to avoid unconditionally executing very expensive