https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118136
--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to Andrew Pinski from comment #3) > >+__attribute__((naked)) void custom_start() { > calls > > This is not defined code as naked is only to be used with one inline-asm > without any calls. Plus NOT all targets implement the naked attribute. From https://gcc.gnu.org/onlinedocs/gcc-14.2.0/gcc/x86-Function-Attributes.html#index-naked-function-attribute_002c-x86 "While using extended asm or a mixture of basic asm and C code may appear to work, they cannot be depended upon to work reliably and are not supported." So at least the naked attribute causes the testcase to be invalid/undefined.