On bluefield 3, how to build pktgen

trying to build latest pktgen-dpdk-pktgen-23.06.1 on bf3. While building, it gave the following error message. “cc1: error: switch ‘-mcpu=cortex-a72’ conflicts with ‘-march=armv8.2-a+crypto+fp16+rcpc+dotprod+flagm+pauth’ switch”. I tried build with armv8-a, but the packet rate is really poor.
How to build pktgen on bf3? Or is there some other similar tool to use instead?

Hello @thomas.li2,

Thank you for posting your query on our community. I would like to ask if you followed the instructions listed in the following link to build pktgen - Part VII/B - NVIDIA Mellanox Bluefield-2 SmartNIC Hands-On Tutorial | Levente Csikor | CodeX

An alternative tool to use to test packet processing would be ‘testpmd’ which can be configured as mentioned in the article - ESPCommunity


1 Like

Thanks for the response, in this case, I was trying to build and run pktgen on BF3 instead of the host pc. I am trying to see what packet size range I can transmit at line rate from Bluefield with pktgen running on BF3.

From the BF3, I tried

wget https://git.dpdk.org/apps/pktgen-dpdk/snapshot/pktgen-dpdk-pktgen-23.06.1.tar.xz
tar -xJvf pktgen-dpdk-pktgen-23.06.q.tar.xz
cd pktgen-dpdk-pktgen-23.06.1/

This gave me the error message
cc1: error: switch ‘-mcpu=cortex-a72’ conflicts with ‘-march=armv8.2-a+crypto+fp16+rcpc+dotprod+flagm+pauth’ switch

To get pktgen to compile on bf3, I modified the meson.build for -march=armv8_a. This does build, but I was not able to get linerate across the different packet sizes. So suspect I cannot build pktgen on bf3 this way.

I did try the same on steps on BF2 16G verison, and was able to get similar result to what was seen on Part II - NVIDIA Mellanox Bluefield-2 SmartNIC Hands-On Tutorial | Levente Csikor | CodeX

If possible, still do need a way to generate packets from BF3 itself (not host cpu), to see at what packet size I can get line rate.

thx to email correspondance, after the mlxconfig reset, we can now transmit at linerate 200G using pktgen from the arm of bf3 with packet size 512B. It seems likely something was in the mlxconfig that prevented the BF3 from achieving linerate. Issue is resolved.