re PR tree-optimization/19637 (Missed VRP and FRE opportunities in the presence of...
authorRichard Guenther <rguenther@suse.de>
Mon, 17 Mar 2008 14:34:21 +0000 (14:34 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Mon, 17 Mar 2008 14:34:21 +0000 (14:34 +0000)
commitc4e5b5a8bf81daa9e21c17149a4943b96c8099b3
tree953f8e21808467a87b2490c396b2f654c4d588ca
parentec286fe7ab26dbfeeb7e7d05d9d747745c108393
re PR tree-optimization/19637 (Missed VRP and FRE opportunities in the presence of casts)

2008-03-17  Richard Guenther  <rguenther@suse.de>

PR tree-optimization/19637
* fold-const.c (fold_unary): Remove restrictions of removing
intermediate pointer-conversions (P2)(P1)P0.
* tree-ssa-ccp.c (maybe_fold_stmt_addition): Recover from
conversion to void pointer.
(get_maxval_strlen): Handle addresses of the form &(*p)[0].

* g++.dg/tree-ssa/pr19637.C: New testcase.

From-SVN: r133291
gcc/ChangeLog
gcc/fold-const.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/tree-ssa/pr19637.C [new file with mode: 0644]
gcc/tree-ssa-ccp.c