https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81128
--- Comment #6 from Nathan Sidwell <nathan at gcc dot gnu.org> --- the ifunc attribute is essentially slightly different syntactic sugar to the alias attribute. It sounds like the optimizer is treating the attribute as-if it were an alias.