summaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-pre.c
diff options
context:
space:
mode:
authorRichard Guenther <rguenther@suse.de>2011-10-18 11:44:15 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2011-10-18 11:44:15 +0000
commit748c5114543cb803cdb494105510217046d20513 (patch)
tree847629880f509227c06859b1e00e05e1245cf5e0 /gcc/tree-ssa-pre.c
parent5b6b2942cd75a2dec7bd0d2fb15ffd3a517a1427 (diff)
downloadgcc-748c5114543cb803cdb494105510217046d20513.tar.gz
re PR tree-optimization/50767 (ICE: in refs_may_alias_p_1, at tree-ssa-alias.c:1004 with -O2 -fno-tree-copy-prop -fno-tree-dominator-opts)
2011-10-18 Richard Guenther <rguenther@suse.de> PR tree-optimization/50767 * tree-ssa-pre.c (create_expression_by_pieces): Update the folded statement. * gcc.dg/torture/pr50767.c: New testcase. From-SVN: r180134
Diffstat (limited to 'gcc/tree-ssa-pre.c')
-rw-r--r--gcc/tree-ssa-pre.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/tree-ssa-pre.c b/gcc/tree-ssa-pre.c
index a7f6cee35d8..60ae35cef73 100644
--- a/gcc/tree-ssa-pre.c
+++ b/gcc/tree-ssa-pre.c
@@ -3188,7 +3188,8 @@ create_expression_by_pieces (basic_block block, pre_expr expr,
/* Fold the last statement. */
gsi = gsi_last (*stmts);
- fold_stmt_inplace (&gsi);
+ if (fold_stmt_inplace (&gsi))
+ update_stmt (gsi_stmt (gsi));
/* Add a value number to the temporary.
The value may already exist in either NEW_SETS, or AVAIL_OUT, because