[dpdk-dev] [PATCH v3 1/3] lib/lpm: not inline unnecessary functions

Medvedkin, Vladimir vladimir.medvedkin at intel.com
Fri Jun 28 15:38:21 CEST 2019


Hi Stephen,

On 27/06/2019 16:24, Stephen Hemminger wrote:
> On Thu, 27 Jun 2019 17:37:49 +0800
> Ruifeng Wang <ruifeng.wang at arm.com> wrote:
>
>> Tests showed that the function inlining caused performance drop
>> on some x86 platforms with the memory ordering patches applied.
>> By force no-inline functions, the performance was better than
>> before on x86 and no impact to arm64 platforms.
>>
>> Suggested-by: Medvedkin Vladimir <vladimir.medvedkin at intel.com>
>> Signed-off-by: Ruifeng Wang <ruifeng.wang at arm.com>
>> Reviewed-by: Gavin Hu <gavin.hu at arm.com>
>   {
>
> Do you actually need to force noinline or is just taking of inline enough?
> In general, letting compiler decide is often best practice.
In some cases compiler inlines this functions even if they don't have an 
inline qualifier. On some processors it leads to performance drop (maybe 
because of icache trashing).

-- 
Regards,
Vladimir



More information about the dev mailing list