Move "(A & C) == D is false when D & ~C != 0" to match.pd
authorMarc Glisse <marc.glisse@inria.fr>
Thu, 25 May 2017 08:39:37 +0000 (10:39 +0200)
committerMarc Glisse <glisse@gcc.gnu.org>
Thu, 25 May 2017 08:39:37 +0000 (08:39 +0000)
commit10bc8017a3028c291e7b85486bc66bfc12b5f377
tree0ae39800f5225d93ec8ee7ce60769570b69186da
parentd112b94ac4c8038056cf035dd8d550c9dc74b8e2
Move "(A & C) == D is false when D & ~C != 0" to match.pd

2017-05-25  Marc Glisse  <marc.glisse@inria.fr>

* fold-const.c (fold_binary_loc) [(A & C) == D]: Remove transformation.
* match.pd (X == C): Rewrite it here.
(with_possible_nonzero_bits, with_possible_nonzero_bits2,
with_certain_nonzero_bits2): New predicates.
* tree-ssanames.c (get_nonzero_bits): Handle INTEGER_CST.

From-SVN: r248447
gcc/ChangeLog
gcc/fold-const.c
gcc/match.pd
gcc/tree-ssanames.c