As Andrew P recognized, we were using the wrong mode when simplifying certain
equality tests like (eq (ior (ne x 0 (y)). Sam took Andrew's suggestion and
verified it fixed the problem he was stumbling over.
So even though I haven't recreated the problem, I'm reasonably confident we've
got the right fix. I've bootstrapped and regression tested on x86.
PR rtl-optimization/122575
gcc/
* simplify-rtx.cc (simplify_context::simplify_relational_operation_1):
Use correct mode for simplified IOR expression inside equality
conditional.