https://gcc.gnu.org/bugzilla/show_bug.cgi?id=121023
--- Comment #4 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Jakub Jelinek <ja...@gcc.gnu.org>: https://gcc.gnu.org/g:89b9372d61ccd45cb6c71518d62215917e3aaebc commit r16-2195-g89b9372d61ccd45cb6c71518d62215917e3aaebc Author: Jakub Jelinek <ja...@redhat.com> Date: Fri Jul 11 12:09:44 2025 +0200 ipa: Disallow signature changes in fun->has_musttail functions [PR121023] As the following testcase shows e.g. on ia32, letting IPA opts change signature of functions which have [[{gnu,clang}::musttail]] calls can turn programs that would be compiled normally into something that is rejected because the caller has fewer argument stack slots than the function being tail called. The following patch prevents signature changes for such functions. It is perhaps too big hammer in some cases, but it might be hard to try to figure out what signature changes are still acceptable and which are not at IPA time. 2025-07-11 Jakub Jelinek <ja...@redhat.com> Martin Jambor <mjam...@suse.cz> PR ipa/121023 * ipa-fnsummary.cc (compute_fn_summary): Disallow signature changes on cfun->has_musttail functions. * c-c++-common/musttail32.c: New test.