]> git.ipfire.org Git - thirdparty/gcc.git/commit
fold-const.c (fold_comparison): Clean up and extend X +- C1 CMP C2 to X CMP C2 -...
authorEric Botcazou <ebotcazou@adacore.com>
Tue, 27 May 2014 19:54:46 +0000 (19:54 +0000)
committerEric Botcazou <ebotcazou@gcc.gnu.org>
Tue, 27 May 2014 19:54:46 +0000 (19:54 +0000)
commitd378c07ebbb0cf59e9ebd4b2f5912b6ca6f90f1c
treee6ac227a3d7680dd7465cbd862d98caa0511d604
parent3ce6c715378c93b5ec390b5e8f0732fa93ad9fc8
fold-const.c (fold_comparison): Clean up and extend X +- C1 CMP C2 to X CMP C2 -+ C1 transformation to...

* fold-const.c (fold_comparison): Clean up and extend X +- C1 CMP C2
to X CMP C2 -+ C1 transformation to EQ_EXPR/NE_EXPR.
Add X - Y CMP 0 to X CMP Y transformation.
(fold_binary_loc) <EQ_EXPR/NE_EXPR>: Remove same transformations.

From-SVN: r210979
gcc/ChangeLog
gcc/fold-const.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/Wstrict-overflow-25.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/fold-compare-8.c [new file with mode: 0644]