https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93487
--- Comment #5 from Petr Skocik <pskocik at gmail dot com> --- Another case of a missed tailcall which might warrant a separate mention: struct big{ long _[10]; }; void takePtr(void *); void takeBigAndPassItsAddress(struct big X){ takePtr(&X); } This should ideally compile to just `lea 8(%rsp), %rdi; jmp takePtr;`. The compiler might be tempted here to use the taking of an address of a local here as a reason not to tail call, and clang misses this optimization too, probably for this reason, but tailcalling here is fine as the particular local here isn't allocated by the function but rather the callee during the call. Icc does do this optimization: https://godbolt.org/z/a6coTzPjz