[PATCH 3/5] net/hns3: optimize free mbuf code for SVE Tx
lihuisong (C)
lihuisong at huawei.com
Tue Sep 26 06:03:21 CEST 2023
在 2023/9/25 22:21, Ferruh Yigit 写道:
> On 7/11/2023 11:24 AM, Dongdong Liu wrote:
>> From: Huisong Li <lihuisong at huawei.com>
>>
>> Currently, hns3 SVE Tx checks the valid bits of all descriptors
>> in a batch and then determines whether to release the corresponding
>> mbufs. Actually, once the valid bit of any descriptor in a batch
>> isn't cleared, driver does not need to scan the rest of descriptors.
>>
>> If we optimize SVE codes algorithm about this function, the performance
>> of a single queue for 64B packet is improved by ~2% on txonly forwarding
>> mode. And if use C code to scan all descriptors, the performance is
>> improved by ~8%.
>>
>> So this patch selects C code to optimize this code to improve the SVE
>> Tx performance.
>>
>> Signed-off-by: Huisong Li <lihuisong at huawei.com>
>> Signed-off-by: Dongdong Liu <liudongdong3 at huawei.com>
>>
> SVE Tx optimized by removing SVE implementation :)
Yes. I didn't remove it, TBH. but I have no other idea.😂
>
> Do you have any insight why generic vector implementation is faster?
I guess the number of instructions for this SVE code block is greater
than C code with scanning one by one.
But If the burst size is bigger, such as 128 and more, the SVE
performance can be enhanced a little.
>
>
>
> .
More information about the dev
mailing list