This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/26899] Fold does not fold (i0 > i1 + 1) || (i1 < i0 - 1)
- From: "rguenth at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 Oct 2006 18:03:34 -0000
- Subject: [Bug middle-end/26899] Fold does not fold (i0 > i1 + 1) || (i1 < i0 - 1)
- References: <bug-26899-10053@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from rguenth at gcc dot gnu dot org 2006-10-28 18:03 -------
Subject: Bug 26899
Author: rguenth
Date: Sat Oct 28 18:03:21 2006
New Revision: 118106
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=118106
Log:
2006-10-28 Richard Guenther <rguenther@suse.de>
PR middle-end/26899
* fold-const.c (maybe_canonicalize_comparison_1): Helper
for maybe_canonicalize_comparison.
(maybe_canonicalize_comparison): New function for canonicalizing
comparison trees.
(fold_comparison): Call it to canonicalize comparisons with
constants involved.
* gcc.dg/tree-ssa/pr26899.c: New testcase.
Added:
trunk/gcc/testsuite/gcc.dg/tree-ssa/pr26899.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/fold-const.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26899