fold-const.c (fold_comparison): Move X - Y CMP 0 -> X CMP Y...
authorRichard Biener <rguenther@suse.de>
Wed, 1 Jul 2015 13:18:49 +0000 (13:18 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Wed, 1 Jul 2015 13:18:49 +0000 (13:18 +0000)
commit2ee05f1e9be5f02d4c874262d27e1eff96a301f0
treee048319d1f8fe53189f0de6f0710cba5e059e036
parente09abfa408597ec644621b6318d735eb0a2d299d
fold-const.c (fold_comparison): Move X - Y CMP 0 -> X CMP Y...

2015-07-01  Richard Biener  <rguenther@suse.de>

* fold-const.c (fold_comparison): Move X - Y CMP 0 -> X CMP Y,
X * C1 CMP 0 -> X CMP 0, X CMP X, ~X CMP ~Y -> Y CMP X and
~X CMP C -> X CMP' ~C to ...
* match.pd: ... patterns here.

From-SVN: r225249
gcc/ChangeLog
gcc/fold-const.c
gcc/match.pd