2016-08-24 Richard Biener <rguenther@suse.de>
commite061fbea1b92a264538e8ba5b03df164ecb417ed
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 24 Aug 2016 07:39:42 +0000 (24 07:39 +0000)
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 24 Aug 2016 07:39:42 +0000 (24 07:39 +0000)
tree15ab6b47d35ad543989c0dd4922cdc72aecb5afa
parent197ba9c2b3877461429b4e3549649db8344f3a39
2016-08-24  Richard Biener  <rguenther@suse.de>

Backport from mainline
2016-08-17  Richard Biener  <rguenther@suse.de>

PR tree-optimization/76490
* tree-vrp.c (update_value_range): Preserve overflow infinities
when intersecting with ranges from get_range_info.
(operand_less_p): Handle overflow infinities correctly.
(value_range_constant_singleton): Use vrp_operand_equal_p
to handle overflow max/min correctly.
(vrp_valueize): Likewise.
(union_ranges): Likewise.
(intersect_ranges): Likewise.
(vrp_visit_phi_node): Improve iteration limitation to only
apply when we'll possibly re-visit the PHI via a changed argument
on the backedge.

* gfortran.fortran-torture/compile/pr76490.f90: New testcase.
* gcc.dg/pr52904.c: XFAIL.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-6-branch@239729 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/pr52904.c
gcc/testsuite/gfortran.fortran-torture/compile/pr76490.f90 [new file with mode: 0644]
gcc/tree-vrp.c