intel / intel-ipsec-mb

Intel(R) Multi-Buffer Crypto for IPSec
BSD 3-Clause "New" or "Revised" License
292 stars 88 forks source link

vpp integrated ipsecmb engine, the performance of sm4 and sm3 algorithm is very low #152

Closed 403705726 closed 3 months ago

403705726 commented 4 months ago

vpp integrated ipsecmb engine, the performance of the national secret algorithm is very low, only 200Mbps, I would like to ask the algorithm library is not optimized for the performance of the national secret algorithm, for the very low performance of the national secret algorithm, I would like to ask if there is a good solution

tkanteck commented 3 months ago

What hardware platform did you use in the benchmark? I suspect that base SM3 and SM4 implementations were used in the benchmark. Please note that current base implementations of these algorithms are not optimized.

SM3NI and SM4NI enabled hardware platform is required for better SM3 and SM4 performance.

tkanteck commented 3 months ago

As to VPP, I don't think VPP ipsecmb crypto engine supports SM3 and SM4 algorithms. Did you use modified engine version in your tests?

tkanteck commented 3 months ago

closing it - feel free to re-open

403705726 commented 3 weeks ago

Thank you for your reply, it is really affected by the cpu instruction set  

の ☆→等 @.***

 

------------------ 原始邮件 ------------------ 发件人: "Tomasz @.>; 发送时间: 2024年6月14日(星期五) 晚上11:24 收件人: @.>; 抄送: "の @.>; @.>; 主题: Re: [intel/intel-ipsec-mb] vpp integrated ipsecmb engine, the performance of sm4 and sm3 algorithm is very low (Issue #152)

What hardware platform did you use in the benchmark? I suspect that base SM3 and SM4 implementations were used in the benchmark. Please note that current base implementations of these algorithms are not optimized.

SM3NI and SM4NI enabled hardware platform is required for better SM3 and SM4 performance.

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

403705726 commented 3 weeks ago

Yes, I modified the source code of vpp to support SM3 and SM4 algorithm calls. At the same time, the latest version of intel-mb source also supports the algorithm,but the performance of sm4 and sm3 algorithm is very low。 At the moment, as far as I can tell, it should be limited to the cpu instruction set's impact on the performance of sm3 and sm4 algorithms. But I'm not sure how big of an impact that is and whether there's room for optimization.  

の ☆→等 @.***

 

------------------ 原始邮件 ------------------ 发件人: "Tomasz @.>; 发送时间: 2024年6月19日(星期三) 晚上10:52 收件人: @.>; 抄送: "の @.>; @.>; 主题: Re: [intel/intel-ipsec-mb] vpp integrated ipsecmb engine, the performance of sm4 and sm3 algorithm is very low (Issue #152)

As to VPP, I don't think VPP ipsecmb crypto engine supports SM3 and SM4 algorithms. Did you use modified engine version in your tests?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>