https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89613
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- This might be the same as PR 63572. The point here is that the function is pure/const so it is detected as that and then the original code is converted into a() * 2 instead so only one call is done at all. That same issue would happen even without ICF. The ICF specific issue is really recorded as PR 63572.