https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98525
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- successfully_inlined = expand_call_inline (bb, stmt, id, to_purge); maybe_remove_unused_call_args (cfun, stmt); /* This used to return true even though we do fail to inline in some cases. See PR98525. */ goto egress; Since it is not so obvious from reading the code and even reading this bug report (but it was clear from the mailing list), the suggestion was to add an assert that successfully_inlined was true and the failures in comment #0 happen when the assert is added in the above code.