[Bug tree-optimization/95929] Failure to optimize tautological comparisons of comparisons to a single one

glisse at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Sat Jun 27 12:42:39 GMT 2020


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

--- Comment #1 from Marc Glisse <glisse at gcc dot gnu.org> ---
Here gcc does optimize the first f to (a != 0) ^ (b != 0). However, for the
second f, it does indeed generate something that looks like the first f before
optimization... The optimization for the first f is probably "(X && !Y) || (!X
&& Y) is X ^ Y" in fold-const.c, which may not have an equivalent in match.pd
yet.


More information about the Gcc-bugs mailing list