Do not register a cast as an equivalence.
authorAndrew MacLeod <amacleod@redhat.com>
Mon, 12 Jul 2021 15:38:17 +0000 (11:38 -0400)
committerAndrew MacLeod <amacleod@redhat.com>
Mon, 12 Jul 2021 18:36:24 +0000 (14:36 -0400)
commita1539b797a06e03b08e1f1de28ad0d19a3956616
treedbe4394df357484f0e5c763202f79aede74f6d36
parent9d4393af9d2b37b78eb5b1f84f5d4da3a6f7fba6
Do not register a cast as an equivalence.

Registering an equivalence between objects of the same size in a cast can
cause other relations to be incorrect.

gcc/
PR tree-optimization/101335
* range-op.cc (operator_cast::lhs_op1_relation): Delete.

gcc/testsuite/
* gcc.dg/tree-ssa/pr101335.c: New.
gcc/range-op.cc
gcc/testsuite/gcc.dg/tree-ssa/pr101335.c [new file with mode: 0644]