1 .. SPDX-License-Identifier: BSD-3-Clause
2 Copyright 2020 Mellanox Technologies, Ltd
7 Application for rte_flow performance testing.
8 The application provide the ability to test insertion rate of specific
9 rte_flow rule, by stressing it to the NIC, and calculate the insertion
12 The application offers some options in the command line, to configure
15 After that the application will start producing rules with same pattern
16 but increasing the outer IP source address by 1 each time, thus it will
17 give different flow each time, and all other items will have open masks.
23 The current version has limitations which can be removed in future:
25 * Support outer items up to tunnel layer only.
26 * Single core insertion only.
27 * Only one instance of same action can be added in one rule.
29 The application also provide the ability to measure rte flow deletion rate,
30 in addition to memory consumption before and after the flows creation.
32 The app supports single and multi core performance measurements.
35 Compiling the Application
36 =========================
38 The ``test-flow-perf`` application is compiled as part of the main compilation
39 of the DPDK libraries and tools.
41 Refer to the DPDK Getting Started Guides for details.
44 Running the Application
45 =======================
47 EAL Command-line Options
48 ------------------------
50 Please refer to :doc:`EAL parameters (Linux) <../linux_gsg/linux_eal_parameters>`
51 or :doc:`EAL parameters (FreeBSD) <../freebsd_gsg/freebsd_eal_parameters>` for
52 a list of available EAL command-line options.
55 Flow Performance Options
56 ------------------------
58 The following are the command-line options for the flow performance application.
59 They must be separated from the EAL options, shown in the previous section,
60 with a ``--`` separator:
62 .. code-block:: console
64 sudo ./dpdk-test-flow_perf -n 4 -w 08:00.0 -- --ingress --ether --ipv4 --queue --flows-count=1000000
66 The command line options are:
69 Display a help message and quit.
72 Set the number of needed flows to insert,
73 where 1 <= N <= "number of flows".
74 The default value is 4,000,000.
76 * ``--dump-iterations``
77 Print rates for each iteration of flows.
78 Default iteration is 1,00,000.
81 Enable deletion rate calculations.
83 * ``--dump-socket-mem``
84 Dump the memory stats for each socket before the insertion and after.
87 Enable packets forwarding after insertion/deletion operations.
93 Set Ingress attribute to all flows attributes.
96 Set Egress attribute to all flows attributes.
99 Set Transfer attribute to all flows attributes.
102 Set group for all flows, where N >= 0.
108 Add Ether item to all flows items, This item have open mask.
111 Add VLAN item to all flows items,
112 This item have VLAN value defined in user_parameters.h
113 under ``VNI_VALUE`` with full mask, default value = 1.
114 Other fields are open mask.
117 Add IPv4 item to all flows items,
118 This item have incremental source IP, with full mask.
119 Other fields are open mask.
122 Add IPv6 item to all flows item,
123 This item have incremental source IP, with full mask.
124 Other fields are open mask.
127 Add TCP item to all flows items, This item have open mask.
130 Add UDP item to all flows items, This item have open mask.
133 Add VXLAN item to all flows items,
134 This item have VNI value defined in user_parameters.h
135 under ``VNI_VALUE`` with full mask, default value = 1.
136 Other fields are open mask.
139 Add VXLAN-GPE item to all flows items,
140 This item have VNI value defined in user_parameters.h
141 under ``VNI_VALUE`` with full mask, default value = 1.
142 Other fields are open mask.
145 Add GRE item to all flows items,
146 This item have protocol value defined in user_parameters.h
147 under ``GRE_PROTO`` with full mask, default protocol = 0x6558 "Ether"
148 Other fields are open mask.
151 Add GENEVE item to all flows items,
152 This item have VNI value defined in user_parameters.h
153 under ``VNI_VALUE`` with full mask, default value = 1.
154 Other fields are open mask.
157 Add GTP item to all flows items,
158 This item have TEID value defined in user_parameters.h
159 under ``TEID_VALUE`` with full mask, default value = 1.
160 Other fields are open mask.
163 Add Meta item to all flows items,
164 This item have data value defined in user_parameters.h
165 under ``META_DATA`` with full mask, default value = 1.
166 Other fields are open mask.
169 Add Tag item to all flows items,
170 This item have data value defined in user_parameters.h
171 under ``META_DATA`` with full mask, default value = 1.
173 Also it have tag value defined in user_parameters.h
174 under ``TAG_INDEX`` with full mask, default value = 0.
175 Other fields are open mask.
181 Add port redirection action to all flows actions.
182 Port redirection destination is defined in user_parameters.h
183 under PORT_ID_DST, default value = 1.
186 Add RSS action to all flows actions,
187 The queues in RSS action will be all queues configured
191 Add queue action to all flows items,
192 The queue will change in round robin state for each flow.
195 The app running with 4 RX queues
196 Flow #0: queue index 0
197 Flow #1: queue index 1
198 Flow #2: queue index 2
199 Flow #3: queue index 3
200 Flow #4: queue index 0
204 Add jump action to all flows actions.
205 Jump action destination is defined in user_parameters.h
206 under ``JUMP_ACTION_TABLE``, default value = 2.
209 Add mark action to all flows actions.
210 Mark action id is defined in user_parameters.h
211 under ``MARK_ID``, default value = 1.
214 Add count action to all flows actions.
217 Add set-meta action to all flows actions.
218 Meta data is defined in user_parameters.h under ``META_DATA``
219 with full mask, default value = 1.
222 Add set-tag action to all flows actions.
223 Meta data is defined in user_parameters.h under ``META_DATA``
224 with full mask, default value = 1.
226 Tag index is defined in user_parameters.h under ``TAG_INDEX``
227 with full mask, default value = 0.
230 Add drop action to all flows actions.
232 * ``--hairpin-queue=N``
233 Add hairpin queue action to all flows actions.
234 The queue will change in round robin state for each flow.
237 The app running with 4 RX hairpin queues and 4 normal RX queues
238 Flow #0: queue index 4
239 Flow #1: queue index 5
240 Flow #2: queue index 6
241 Flow #3: queue index 7
242 Flow #4: queue index 4
245 * ``--hairpin-rss=N``
246 Add hairpin RSS action to all flows actions.
247 The queues in RSS action will be all hairpin queues configured