re PR tree-optimization/49079 (Bogus constant folding)
authorRichard Guenther <rguenther@suse.de>
Fri, 20 May 2011 15:02:49 +0000 (15:02 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Fri, 20 May 2011 15:02:49 +0000 (15:02 +0000)
commit90ff582fb1f05f7380adfab59d86065aae09a9a7
tree0f88181acea8ab0fc265d45d99e9be13fd4739e8
parent3cda91d8634805fcb1148cb856a6fc7605f6719f
re PR tree-optimization/49079 (Bogus constant folding)

2011-05-20  Richard Guenther  <rguenther@suse.de>

PR tree-optimization/49079
* tree-dfa.c (get_ref_base_and_extent): Handle view-converting
MEM_REFs correctly for the trailing array access detection.
Special case constants the same way as decls for overall size
constraining.

* gcc.dg/torture/pr49079.c: New testcase.

From-SVN: r173954
gcc/ChangeLog
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/torture/pr49079.c [new file with mode: 0644]
gcc/tree-dfa.c