On 20.02.2023 14:13, Andrew Cooper wrote:
> There is no such thing as a fastpath with a printk() on it, making printk() an
> excellent heuristic for slowpaths.
> 
> Net delta is:
> 
>   add/remove: 595/2 grow/shrink: 56/762 up/down: 70879/-87331 (-16452)
>   Total: Before=4085425, After=4068973, chg -0.40%
> 
> because cold functions are optimised differently.  For example, one function
> with a particularly large swing is:
> 
>   vmcs_dump_vcpu.cold                            -    2172   +2172
>   vmcs_dump_vcpu                              7030     408   -6622
> 
> with a net delta of 7030 down to 4450.
> 
> Signed-off-by: Andrew Cooper <[email protected]>

Acked-by: Jan Beulich <[email protected]>

> There are other functions which will be good heuristics to annotate, but we
> probaby want to collect .cold together in one location rather than having them
> spread out across all translation units.

Doesn't the compiler put it in .text.cold? Or is that compiler variant
and/or version dependent?

Jan

Reply via email to