perftest(1)
perftest(1) โ General Commands Manual ๐ซถ
okay bestie, this is the perftest(1) page, and it's giving so many benchmarks. no cap, we're gonna keep every single detail, just with way more sparkle ๐
โจ NAME โจ
ib_write_bw, ib_read_bw, ib_send_bw, ib_atomic_bw, ib_write_lat, ib_read_lat, ib_send_lat, ib_atomic_lat, raw_ethernet_bw, raw_ethernet_lat, raw_ethernet_burst_lat, raw_ethernet_fs_rate โ benchmarks for various types of infinabnd performance ๐ฆ
๐ DESCRIPTION ๐
So like, Perftest is a package that includes various benchmarks that measures different metrics & verbs performance, and it comes with many different options and modes.
๐ RUNNING TESTS ๐
Server:
./<test name> <options>
Client:
./<test name> <options> <server IP address>
Examples:
- Running bidirectional bandwidth test using Write verb for 5 seconds with 8388608 as a message size and 3 qps: Server:
./ib_write_bw -s 8388608 -b -D 5 -q 3Client:./ib_write_bw -s 8388608 -b -D 5 -q 3 1.1.1.2 - Running latency test using Read verb for 5000 iterations with 32 as a message size: Server:
./ib_read_lat -s 32 -n 5000Client:./ib_read_lat -s 32 -n 5000 192.168.0.1
๐จ IMPORTANT NOTES ๐จ
- The options that specific to modes in perftest must be the same for both server and client.
- Perftest applications may need to be ran with sudo when running from non root.
- Perftest applications usually installed to the
/usr/bin/. - Perftest may print some failures with syndroms to the stderr, perftest get those errors from rdma-core.
โจ OPTIONS โจ
-h,--helpโ Lists the available options to the screen.-a,--allโ Run sizes from 2 till 2^23. Not relevant for Atomic and RawEth.-A,--atomic_type=<type>โ Type of atomic operation from {CMP_AND_SWAP,FETCH_AND_ADD} (default FETCH_AND_ADD). Relevant only for Atomic.-b,--bidirectionalโ Measure bidirectional bandwidth (default unidirectional). Relevant only for BW.-c,--connection=<RC/XRC/UC/UD/DC/SRD>โ Connection type RC/XRC/UC/UD/DC/SRD (default RC). UD relevant only for Send verb. SRD relevant only for Read, Write and Send verbs. UC relevant only for Write and Send verbs. Not relevant for RawEth.--log_dci_streams=<log_num_dci_stream_channels>โ (default 0) Run DC initiator as DCS instead of DCI with<log_num dci_stream_channels>. Not relevant for RawEth. System support required.--log_active_dci_streams=<log_num_active_dci_stream_channels>โ (defaultlog_num_dci_stream_channels). Not relevant for RawEth. System support required.--aes_xtsโ Runs traffic with AES_XTS feature (encryption). Not relevant for RawEth and Write latency. System support required.--encrypt_on_txโ Runs traffic with encryption on tx (default decryption on tx). Not relevant for RawEth and Write latency. System support required.--sig_beforeโ Puts signature on data before encrypting it (default after). Not relevant for RawEth and Write latency. System support required.--aes_block_size=<512,520,4048,4096,4160>โ (default 512). Not relevant for RawEth and Write latency. System support required.--data_enc_keys_number=<number of data encryption keys>โ (default 1). Not relevant for RawEth and Write latency. System support required.--kek_path <path to the key encryption key file>โ Not relevant for RawEth and Write latency. System support required.--credentials_path <path to the credentials file>โ Not relevant for RawEth and Write latency. System support required.--data_enc_key_app_path <path to the data encryption key app>โ Not relevant for RawEth and Write latency. System support required.-C,--report-cyclesโ Report times in cpu cycle units (default microseconds). Relevant only for latency.-d,--ib-dev=<dev>โ Use IB device<dev>(default first device found).-D,--durationโ Run test for a customized period of seconds.-e,--eventsโ Sleep on CQ events (default poll). Not relevant for Write and RawEth.-X,--vector=<completion vector>โ Set<completion vector>used for events. Not relevant for Write and RawEth.-f,--marginโ measure results within margins. (default=2sec).-F,--CPU-freqโ Do not show a warning even if cpufreq_ondemand module is loaded, and cpu-freq is not on max.-g,--mcgโ Send messages to multicast group with 1 QP attached to it. When there is no multicast gid specified, a default IPv6 typed gid'255:1:0:0:0:2:201:133:0:0:0:0:0:0:0:0'will be used. Relevant only for send non fsRate.-H,--report-histogramโ Print out all results (default print summary only). Relevant only for latency and raw_ethernet_fs_rate.-i,--ib-port=<port>โ Use port<port>of IB device (default 1).-I,--inline_size=<size>โ Max size of message to be sent in inline. Not relevant for Read and Atomic.-l,--post_list=<list size>โ Post list of send WQEs of<list size>size (instead of single post). Relevant only for BW and raw_ethernet_burst_lat.--recv_post_list=<list size>โ Post list of receive WQEs of<list size>size (instead of single post). Relevant only for BW and raw_ethernet_burst_lat.-L,--hop_limit=<hop_limit>โ Set hop limit value (ttl for IPv4 RawEth QP). Values 0-255 (default 64). Relevant only for RawEth. Not relevant for raw_ethernet_fs_rate.-m,--mtu=<mtu>โ MTU size : 64 - 9600 (default port mtu) for RawEth else 256 - 4096. Not relevant for raw_ethernet_fs_rate.-M,--MGID=<multicast_gid>โ In multicast, uses<multicast_gid>as the group MGID.<multicast_gid>can be either decimal or hexadecimal, e.g. regarding the IPv4 224.0.0.30 : Decimal:0:0:0:0:0:0:0:0:0:0:255:255:224:0:0:30, Hexadecimal:0:0:0:0:0:0:0:0:0:0:0xff:0xff:0xe0:0:0:0x1e. Relevant only for send non fsRate.-n,--iters=<iters>โ Number of exchanges (at least 5, default for write 5000 else 1000 ).-N,--noPeakโ Cancel peak-bw calculation (default with peak up to iters=20000). Relevant only for bandwidth.-o,--outs=<num>โ Relevant only for Read and Atomic.-O,--dualportโ Run test in dual-port mode. Not relevant for RawEth. Relevant only for bandwidth. System support required.-p,--port=<port>โ Listen on/connect to port<port>(default 18515).-q,--qp=<num of qp's>โ Num of qp's(default 1). Relevant only for bandwidth.-Q,--cq-modโ Generate Cqe only after<--cq-mod>completion. Relevant only for bandwidth.-r,--rx-depth=<dep>โ Rx queue size (default 512), if using srq, rx-depth controls max-wr size of the srq. Relevant only for send non fsRate.-R,--rdma_cmโ Connect QPs with rdma_cm and run test on those QPs. Not relevant for RawEth.-s,--size=<size>โ Size of message to exchange (default 65536 for bw, for lat 2). Not relevant for Atomic.-S,--sl=<sl>โ SL (default 0). Not relevant for raw_ethernet_fs_rate.-t,--tx-depth=<dep>โ Size of tx queue (default 128 for bw else 1). Relevant only for bw and raw_ethernet_burst_lat.-T,--tos=<tos value>โ Set<tos_value>to RDMA-CM QPs. available only with-Rflag. values 0-256 (default off). Not relevant for RawEth-u,--qp-timeout=<timeout>โ QP timeout, timeout value is 4 usec * 2 ^(timeout), default 14.-U,--report-unsortedโ (implies -H) print out unsorted results (default sorted). Relevant only for latency and raw_ethernet_burst_lat and raw_ethernet_fs_rate.-V,--versionโ Display perftest version number.-W,--report-counters=<list of counter names>โ Report performance counter change (example:counters/port_xmit_data,hw_counters/out_of_buffer).-x,--gid-index=<index>โ Test uses GID with GID index. Not relevant for RawEth.-z,--comm_rdma_cmโ Communicate with rdma_cm module to exchange data - use regular QPs. Not relevant for RawEth.--out_jsonโ Save the report in a json file.--out_json_file=<file>โ Name of the report json file. (Default:"perftest_out.json"in the working directory).--cpu_utilโ Show CPU Utilization in report, valid only in Duration mode.--dlidโ Set a Destination LID instead of getting it from the other side. Not relevant for raw_ethernet_fs_rate.--dont_xchg_versionsโ Do not exchange versions and MTU with other side. Not relevant for RawEth.--force-link=<value>โ Force the link(s) to a specific type: IB or Ethernet. Not relevant for raw_ethernet_fs_rate.--use-srqโ Use a Shared Receive Queue.--rx-depthcontrols max-wr size of the SRQ. Relevant only for Send.--ipv6โ Use IPv6 GID. Default is IPv4. Not relevant for RawEth.--ipv6-addr=<IPv6>โ Use IPv6 address for parameters negotiation. Default is IPv4. Not relevant for RawEth.--bind_source_ipโ Source IP of the interface used for connection establishment. By default taken from routing table. Not relevant for RawEth.--latency_gap=<delay_time>โ delay time between each post send. Relevant only for latency.--mmap=fileโ Use an mmap'd file as the buffer for testing P2P transfers. Not relevant for RawEth.--mmap-offset=<offset>โ The mmap offset. Not relevant for RawEth.--mr_per_qpโ Create memory region for each qp. Relevant only for bandwidth.--odpโ Use On Demand Paging instead of Memory Registration. System support required.--output=<units>โ Set verbosity output level: bandwidth , message_rate, latency. Latency measurement is Average calculation. bw (bandwidth / message_rate), latency (latency).--payload_file_path=<payload_txt_file_path>โ want a custom payload? pass a txt file with your pattern written little-endian style, like'0xaaaaaaaa, 0xbbbbbbbb, ...'and boom, that's your payload ๐ Not relevant for RawEth and Write latency, bestie โ don't come for me.--use_old_post_sendโ uses the old post send flow (ibv_post_send). vintage vibes, retro moment โจ--perform_warm_upโ runs a few iterations before it starts actually measuring, purely to warm up the memory cache ๐ซ like stretching before the big game. Not relevant forraw_ethernet_fs_rate.--pkey_index=<pkey index>โ the PKey index to use for the QP ๐ Not relevant forraw_ethernet_fs_rate.--report-bothโ reports RX & TX results separately on Bidirectional BW tests ๐ Relevant only for bidirectional bandwidth.--report_gbitsโ reports Max/Average BW of the test in Gbit/sec instead of MiB/sec ๐ Relevant only for bandwidth.--report-per-portโ reports BW data on both ports when you're running Dualport and Duration mode ๐ Not relevant for RawEth. System support required, so check before you get your hopes up.--reversedโ flips the traffic direction: Server send to client ๐ main character energy, but reversed.--run_infinitelyโ runs the test forever, printing results every<duration>seconds โพ๏ธ she's committed. she's not leaving.--retry_count=<value>โ sets the retry count value inrdma_cmmode ๐ Relevant only forrdma_cmmode. Not relevant for RawEth.--tclass=<value>โ sets the Traffic Class in GRH (if GRH is in use) ๐ฆ Not relevant forraw_ethernet_fs_rate.--use-null-mrโ allocates a null memory region for the client usingibv_alloc_null_mr(3)๐ณ๏ธ nothing but vibes in there.--use_cuda=<cuda device id>โ uses a CUDA specific device for GPUDirect RDMA testing ๐ Not relevant forraw_ethernet_fs_rate. System support required.--use_cuda_bus_id=<cuda full BUS id>โ uses a CUDA specific device, picked by its full PCIe address, for GPUDirect RDMA testing ๐ Not relevant forraw_ethernet_fs_rate. System support required.--use_cuda_dmabufโ uses CUDA DMA-BUF for GPUDirect RDMA testing ๐ง Not relevant forraw_ethernet_fs_rate. System support required.--use_hl=<hl device id>โ uses a HabanaLabs specific device for HW accelerator direct RDMA testing ๐ System support required.--use_neuron=<logical neuron core id>โ uses a Neuron specific device for HW accelerator direct RDMA testing ๐ง System support required.--use_neuron_dmabufโ uses Neuron DMA-BUF for HW accelerator direct RDMA testing ๐ง โจ System support required.--use_rocm=<rocm device id>โ uses the selected ROCm device for GPUDirect RDMA testing โค๏ธ Not relevant forraw_ethernet_fs_rate. System support required.--use_hugepagesโ uses Hugepages instead of contig, memalign allocations ๐ huge pages, huge slay. Not relevant forraw_ethernet_fs_rate.--wait_destroy=<seconds>โ waits<seconds>before destroying allocated resources (QP/CQ/PD/MR..) โณ she needs a moment. Relevant only for bandwidth andraw_ethernet_burst_lat.--disable_pcie_relaxedโ disables PCIe relaxed ordering ๐ซ Relevant only for bandwidth andraw_ethernet_burst_lat. System support required.--burst_size=<size>โ sets how many messages to send in a burst when you're using the rate limiter ๐ฅ Relevant only for bandwidth andraw_ethernet_burst_lat.--typical_pkt_size=<bytes>โ sets the size of the packet to send in a burst ๐ฆ only supports the PP rate limiter, no cap. Relevant only for bandwidth andraw_ethernet_burst_lat.--rate_limit=<rate>โ sets the maximum rate of sent packages. default unit is[Gbps]โ use--rate_unitsto change that ๐๏ธ Relevant only for bandwidth andraw_ethernet_burst_lat.--rate_units=<units>โ[Mgp]sets the units for rate limit to MiBps (M), Gbps (g) or pps (p). default is Gbps (g) ๐ Relevant only for bandwidth andraw_ethernet_burst_lat.--rate_limit_type=<type>โ[HW/SW/PP]limits the QP's by HW, PP or by SW. Disabled by default. Whenrate_limitis not specified, HW limit is Default โ๏ธ Relevant only for bandwidth andraw_ethernet_burst_lat.--use_oooโ uses out of order data placement ๐ chaos, but the good kind. System support required.--write_with_immโ uses the write-with-immediate verb instead of write โ๏ธ Write tests only.
๐ RawEth only options ๐
okay bestie this whole lil crew is RawEth exclusive, don't try them anywhere else ๐
-B,--source_macโ Source MAC address, and it has to be in this format:XX:XX:XX:XX:XX:XX. MUST be entered โ no skipping, she's required ๐-E,--dest_macโ Destination MAC address, format:XX:XX:XX:XX:XX:XX. MUST be entered too, obviously ๐-G,--use_rssโ uses RSS on the server side ๐ need to open 2^x qps (using the-qflag. default is-q 2). open 2^x clients that transmit to this server.-J,--dest_ipโ Destination ip address, formatX.X.X.Xfor IPv4 orX:X:X:X:X:Xfor IPv6 (using to send packets with IP header) ๐ System support required for IPv6.-j,--source_ipโ Source ip address, formatX.X.X.Xfor IPv4 orX:X:X:X:X:Xfor IPv6 (using to send packets with IP header) ๐ฎ System support required for IPv6.-K,--dest_portโ Destination port number (using to send packets with UDP header as default, or you can use the--tcpflag to send TCP Header) ๐ช-k,--source_portโ Source port number (using to send packets with UDP header as default, or you can use the--tcpflag to send TCP Header) ๐ชโจ-Y,--ethertypeโ Ethertype value in the ethernet frame, format0xXXXX๐ท๏ธ-Z,--serverโ picks the server side for the current machine (--server/--clientmust be selected ) ๐--vlan_enโ inserts vlan tag in ethernet header ๐ท๏ธ๐--vlan_pcpโ specifies thevlan_pcpvalue for the vlan tag,0~7.8means differentvlan_pcpfor each packet ๐๏ธ-P,--clientโ picks the client side for the current machine (--server/--clientmust be selected) ๐ซถ Not relevant forraw_ethernet_fs_rate.-v,--mac_fwdโ runs the mac forwarding test ๐ฌ Not relevant forraw_ethernet_fs_rate.--flowsโ sets the number of TCP/UDP flows, starting from<src_port, dst_port>๐ Not relevant forraw_ethernet_fs_rate.--flows_burstโ sets the number of burst size per TCP/UDP flow ๐ฅ Not relevant forraw_ethernet_fs_rate.--promiscuousโ runs promiscuous mode ๐ณ she's talking to everyone. Not relevant forraw_ethernet_fs_rate.--reply_everyโ in latency test, the receiver pongs after a number of received pings ๐ Not relevant forraw_ethernet_fs_rate.--snifferโ runs sniffer mode ๐ Not relevant forraw_ethernet_fs_rate. System support required.--flow_label=<fl0, fl1,...>โ IPv6 flow label ๐ท๏ธ Not relevant forraw_ethernet_fs_rate.--tcpโ sends TCP Packets. must include IP and Ports information ๐ฆ--raw_ipv6โ sends IPv6 Packets ๐ System support required.--raw_mcastโ ๐ Relevant only for bandwidth.
๐ AUTHORS ๐
the icons who made this happen, give them their flowers fr fr ๐
- Hassan Khadour
<hkhadour@nvidia.com> - Talat Batheesh
<talatb@nvidia.com>
and that's the whole thing bestie, you made it to the end ๐๐ฆ this masterpiece lives in the perftest(1) manual page โ go forth and benchmark responsibly, mwah ๐
โจ
๐ฆ where this page comes from
- debian trixie: perftest 25.01.0+0.80-1 ยท BSD-MIT OR GPL-2.0-only
- ubuntu questing: perftest 25.01.0+0.80-1
- ubuntu resolute: perftest 25.01.0+0.80-1build1 ยท BSD-MIT OR GPL-2.0-only
- ubuntu stonking: perftest 25.01.0+0.80-1build1 ยท BSD-MIT OR GPL-2.0-only
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms