[hjl@gnu-6 tmp]$ cat x.c extern void bar (void) __attribute__ ((noreturn)); void foo (void) { bar (); } [hjl@gnu-6 tmp]$ gcc -S x.c -O3 [hjl@gnu-6 tmp]$ cat x.s .file "x.c" .section .text.unlikely,"ax",@progbits .LCOLDB0: .text .LHOTB0: .p2align 4,,15 .globl foo .type foo, @function foo: .LFB0: .cfi_startproc subq $8, %rsp .cfi_def_cfa_offset 16 call bar .cfi_endproc .LFE0: .size foo, .-foo .section .text.unlikely .LCOLDE0: .text .LHOTE0: .ident "GCC: (GNU) 5.2.1 20151104 (Red Hat 5.2.1-4)" .section .note.GNU-stack,"",@progbits [hjl@gnu-6 tmp]$
It's a feature for debugging of abort()-like calls. And in this case it's a tailcall as well (which is probably what you are after).
I believe this is intentional and has been discussed in the past. E.g. one of the often used noreturn functions is abort and its callers, in that case we better not sibcall to that, as it will be harder to find out where exactly the code aborted. Also, often not doing a sibcall is shorter, you can stay where you were with the stack pointer, while for sibcall you'd bump the stack pointer first.
Won't fix then.
This is the second time in less than 6 months you filed this bug, see PR 67327. Anyways this is a dup of bug 10837 really. *** This bug has been marked as a duplicate of bug 10837 ***