aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-copy.c
diff options
context:
space:
mode:
authorRichard Guenther <rguenther@suse.de>2010-12-08 23:01:40 +0000
committerSebastian Pop <spop@gcc.gnu.org>2010-12-08 23:01:40 +0000
commitfd66ea1a6f5ecd68c40d330e52e70e22cafec9d3 (patch)
treef1c5454ba13ad564e707268d461dc545286230f7 /gcc/tree-ssa-copy.c
parent09c2d63aa4ea2fb3e90055ca521940df9f8fcb56 (diff)
downloadgcc-fd66ea1a6f5ecd68c40d330e52e70e22cafec9d3.zip
gcc-fd66ea1a6f5ecd68c40d330e52e70e22cafec9d3.tar.gz
gcc-fd66ea1a6f5ecd68c40d330e52e70e22cafec9d3.tar.bz2
Fix PR45230, PR45231, and PR45370: fold_stmt_inplace after replace_exp.
2010-12-08 Richard Guenther <rguenther@suse.de> Sebastian Pop <sebastian.pop@amd.com> PR tree-optimization/45230 PR tree-optimization/45231 PR tree-optimization/45370 * sese.c (rename_uses): Returns a bool. Call recompute_tree_invariant_for_addr_expr only on the RHS of a GIMPLE_ASSIGN. (graphite_copy_stmts_from_block): Call fold_stmt_inplace when rename_uses returns true. * tree-ssa-copy.c (replace_exp): Add a comment about calling fold_stmt_inplace after replace_exp. * gcc.dg/graphite/id-pr45230-1.c: New. * gcc.dg/graphite/id-pr45231.c: New. * gfortran.dg/graphite/id-pr45370.f90: New. Co-Authored-By: Sebastian Pop <sebastian.pop@amd.com> From-SVN: r167609
Diffstat (limited to 'gcc/tree-ssa-copy.c')
-rw-r--r--gcc/tree-ssa-copy.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/gcc/tree-ssa-copy.c b/gcc/tree-ssa-copy.c
index d552c3a..8897275 100644
--- a/gcc/tree-ssa-copy.c
+++ b/gcc/tree-ssa-copy.c
@@ -191,7 +191,10 @@ propagate_value (use_operand_p op_p, tree val)
Use this version when not const/copy propagating values. For example,
PRE uses this version when building expressions as they would appear
- in specific blocks taking into account actions of PHI nodes. */
+ in specific blocks taking into account actions of PHI nodes.
+
+ The statement in which an expression has been replaced should be
+ folded using fold_stmt_inplace. */
void
replace_exp (use_operand_p op_p, tree val)