[Bug tree-optimization/95836] Failure to remove strchr converted to bool with string literal when bit magic would be much more efficient (and sometimes smaller)

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Tue Jun 23 09:48:36 GMT 2020


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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
With & it would actually invoke UB for c >= 64U.
So it has to be either &&, or << (c & 63), at least until we know exactly what
the behavior on out of bounds shift will be.


More information about the Gcc-bugs mailing list