https://gcc.gnu.org/bugzilla/show_bug.cgi?id=26724
--- Comment #4 from Marc Glisse <glisse at gcc dot gnu.org> --- (In reply to pskocik from comment #3) > I don't know if this is related, It isn't, please file a separate bug report. memcmp is optimized to an integer comparison in strlen, much later than the lowering of __builtin_constant_p.