Re: [PATCH] x86: Deinline cpuid_eax and friends

From: H. Peter Anvin
Date: Wed May 06 2015 - 15:00:36 EST


On 05/06/2015 10:07 AM, Denys Vlasenko wrote:
> cpuid_e{a,b,c,d}x() functions compile to 44 bytes of machine code each.
> On x86 allyesconfig build they have 48 callsites.
> Deinlining all four of them shrinks kernel by about 1k:
>
> text data bss dec hex filename
> 82434909 22255384 20627456 125317749 7783275 vmlinux.before
> 82433898 22255384 20627456 125316738 7782e82 vmlinux
>
> Speed impact: CPUID instruction takes from 50 to 350+ cycles,
> call overhead is negligible in comparison.

How on Earth does it make 44 bytes? Is this due to paravirt_fail?

-hpa


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/