This is pretty easy to verify. If the call ais in the same compilation unit, most compilers optimize it. Let's see what happens:
$ cat > foo.c
void b(int, int);
void
a(int a)
{
b(a, 0);
}
void
foo(void)
{
a(17);
}
Then compile it only with assembler with some basic optimizations (I added omit-frame-pointer to create cleaner output, you can make sure that it would happen the same way without this flag):
$ cc -fomit-frame-pointer -S -O2 foo.c
( , , ):
$ cat foo.s
a:
xorl %esi, %esi
jmp b
foo:
xorl %esi, %esi
movl $17, %edi
jmp b
, , a, b ( , , jmp jmp). foo a .
, , gcc, , clang . , - , , , .