https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103660

--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Andrew Pinski from comment #2)
> Actually:
> ```
> (for (op plus bit_ior bit_xor)
>  (simplify
>   (op (cond @0 @1 integer_zero_p)
>       (cond @2 @3 integer_zero_p))
>   (with { bool wascmp; }
>    (if (bitwise_inverted_equal_p (@0, @2, wascmp))
>     (cond @0 @1 @3)
>    )
>   )
>  )
> )
> ```
> Should fix this.
> 
> Well that replaces the pattern that was added in r13-4620-g4d9db4bdd458 and
> extends it to for plus and bit_xor.

Note I think the patterns added in that revision were incorrect:
+   (cond (cmp@0  @01 @02) @3 zerop)
+   (cond (icmp@4 @01 @02) @5 zerop))

allows for @1 and @2 (which by the way 01 and 02 is; just using base 8 rather
than base 10).

Reply via email to