https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93419
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> --- I think the docs are clear here too: The special operator __has_attribute (operand) may be used in ‘#if’ and ‘#elif’ expressions to test whether the attribute referenced by its operand is recognized by GCC. ---- CUT --- __has_attribute just says GCC recognizes the attribute which is true, ifunc is recognized and is basically supported inside gcc until the very end of the compiler. So I want to say this is an invalid bug report ...