re PR tree-optimization/91597 (GCC miscompiles a branch depending on a pointer tag)
authorJakub Jelinek <jakub@redhat.com>
Tue, 3 Sep 2019 07:50:46 +0000 (09:50 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Tue, 3 Sep 2019 07:50:46 +0000 (09:50 +0200)
commit3729852e407e5e1c4f1bbacea1b53e61d7609dad
tree1dcd10f803b96abc9205d08fe36771644ea96fc8
parente4a8d4a7ec496dbd6602e373dcfcb72c25c60f86
re PR tree-optimization/91597 (GCC miscompiles a branch depending on a pointer tag)

PR tree-optimization/91597
* tree-vrp.c (extract_range_from_binary_expr): Remove unsafe
BIT_AND_EXPR optimization for pointers, even if both operand
ranges don't include NULL, the result can be NULL.

* gcc.c-torture/execute/pr91597.c: New test.

Co-Authored-By: Richard Biener <rguenther@suse.de>
From-SVN: r275330
gcc/ChangeLog
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/execute/pr91597.c [new file with mode: 0644]
gcc/tree-vrp.c