Commit c8ba6498 by Eric Botcazou

re PR tree-optimization/66757 (wrong code at -O1 and above on x86_64-linux-gnu)

	PR tree-optimization/66757
	* match.pd: Add missing condition to ~X ^ C -> X ^ ~C.

From-SVN: r225446
parent 43cbef95
2015-07-06 Eric Botcazou <ebotcazou@adacore.com>
PR tree-optimization/66757
* match.pd: Add missing condition to ~X ^ C -> X ^ ~C.
2015-07-05 Chung-Lin Tang <cltang@codesourcery.com>
Sandra Loosemore <sandra@codesourcery.com>
......
......@@ -444,7 +444,8 @@ along with GCC; see the file COPYING3. If not see
/* Convert ~X ^ C to X ^ ~C. */
(simplify
(bit_xor (convert? (bit_not @0)) INTEGER_CST@1)
(bit_xor (convert @0) (bit_not @1)))
(if (tree_nop_conversion_p (type, TREE_TYPE (@0)))
(bit_xor (convert @0) (bit_not @1))))
/* Fold (X & Y) ^ Y as ~X & Y. */
(simplify
......
2015-07-06 Eric Botcazou <ebotcazou@adacore.com>
* gcc.c-torture/execute/pr66757.c: New test.
2015-07-06 Bin Cheng <bin.cheng@arm.com>
PR tree-optimization/66720
* gcc.dg/vect/pr48052.c: Use dg-require-effective-target
vect_int_mult.
* gcc.dg/vect/pr48052.c: Use dg-require-effective-target vect_int_mult.
2015-07-05 Chung-Lin Tang <cltang@codesourcery.com>
Sandra Loosemore <sandra@codesourcery.com>
......
/* PR tree-optimization/66757 */
/* Testcase by Zhendong Su <su@cs.ucdavis.edu> */
int a, b;
int
main (void)
{
unsigned int t = (unsigned char) (~b);
if ((t ^ 1) / 255)
__builtin_abort ();
return 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment