CSIT-1008: Fix 9000B VM Vhost performance tests
[csit.git] / tests / vpp / perf / vm_vhost / 10ge2p1x520-ethip4-ip4base-eth-4vhostvr1024-2vm-ndrpdrdisc.robot
1 # Copyright (c) 2018 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
5 #
6 #     http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
13
14 *** Settings ***
15 | Resource | resources/libraries/robot/performance/performance_setup.robot
16 | Library | resources.libraries.python.QemuUtils
17 | ...
18 | Force Tags | 3_NODE_SINGLE_LINK_TOPO | PERFTEST | HW_ENV | NDRPDRDISC
19 | ... | NIC_Intel-X520-DA2 | ETH | IP4FWD | BASE | VHOST | VM | VHOST_1024
20 | ...
21 | Suite Setup | Set up 3-node performance topology with DUT's NIC model
22 | ... | L3 | Intel-X520-DA2
23 | Suite Teardown | Tear down 3-node performance topology
24 | ...
25 | Test Setup | Set up performance test
26 | Test Teardown | Tear down performance test with vhost and VM with dpdk-testpmd
27 | ... | ${min_rate}pps | ${framesize} | ${traffic_profile}
28 | ... | dut1_node=${dut1} | dut1_vm_refs=${dut1_vm_refs}
29 | ... | dut2_node=${dut2} | dut2_vm_refs=${dut2_vm_refs}
30 | ...
31 | Documentation | *RFC2544: Pkt throughput IPv4 test cases with vhost*
32 | ...
33 | ... | *[Top] Network Topologies:* TG-DUT1-DUT2-TG 3-node circular topology
34 | ... | with single links between nodes.
35 | ... | *[Enc] Packet Encapsulations:* Eth-IPv4 for IPv4 routing.
36 | ... | *[Cfg] DUT configuration:* DUT1 and DUT2 are configured with IPv4
37 | ... | routing and static IPv4 /24 route entries. Qemu Guests are connected
38 | ... | to VPP via vhost-user interfaces. Guests are running DPDK testpmd
39 | ... | interconnecting vhost-user interfaces using 5 cores pinned to cpus 6-10
40 | ... | and 11-15 and 2048M memory. Testpmd is using socket-mem=1024M (512x2M
41 | ... | hugepages), 5 cores (1 main core and 4 cores dedicated for io),
42 | ... | forwarding mode is set to mac, rxd/txd=256, burst=64. DUT1, DUT2 are
43 | ... | tested with 2p10GE NIC X520 Niantic by Intel.
44 | ... | *[Ver] TG verification:* TG finds and reports throughput NDR (Non Drop
45 | ... | Rate) with zero packet loss tolerance or throughput PDR (Partial Drop
46 | ... | Rate) with non-zero packet loss tolerance (LT) expressed in percentage
47 | ... | of packets transmitted. NDR and PDR are discovered for different
48 | ... | Ethernet L2 frame sizes using either binary search or linear search
49 | ... | algorithms with configured starting rate and final step that determines
50 | ... | throughput measurement resolution. Test packets are generated by TG on
51 | ... | links to DUTs. TG traffic profile contains two L3 flow-groups
52 | ... | (flow-group per direction, 253 flows per flow-group) with all packets
53 | ... | containing Ethernet header, IPv4 header with IP protocol=61 and static
54 | ... | payload. MAC addresses are matching MAC addresses of the TG node
55 | ... | interfaces.
56 | ... | *[Ref] Applicable standard specifications:* RFC2544.
57
58 *** Variables ***
59 | ${perf_qemu_qsz}= | 1024
60 # X520-DA2 bandwidth limit
61 | ${s_limit}= | ${10000000000}
62 # CPU settings
63 | ${system_cpus}= | ${1}
64 | ${vpp_cpus}= | ${5}
65 | ${vm_cpus}= | ${5}
66 # Traffic profile:
67 | ${traffic_profile}= | trex-sl-3n-ethip4-ip4src253
68
69 *** Keywords ***
70 | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
71 | | [Documentation]
72 | | ... | [Cfg] DUT runs IPv4 routing config with ${wt} thread, ${wt} phy\
73 | | ... | core, ${rxq} receive queue per NIC port.
74 | | ... | [Ver] Find NDR for ${framesize} frames using binary search start at
75 | | ... | 10GE linerate, step 10kpps.
76 | | ...
77 | | [Arguments] | ${wt} | ${rxq} | ${framesize} | ${min_rate} | ${search_type}
78 | | ...
79 | | # Test Variables required for test and test teardown
80 | | Set Test Variable | ${framesize}
81 | | Set Test Variable | ${min_rate}
82 | | ${get_framesize}= | Get Frame Size | ${framesize}
83 | | ${max_rate}= | Calculate pps | ${s_limit} | ${get_framesize}
84 | | ${binary_min}= | Set Variable | ${min_rate}
85 | | ${binary_max}= | Set Variable | ${max_rate}
86 | | ${threshold}= | Set Variable | ${min_rate}
87 | | ${dut1_vm_refs}= | Create Dictionary
88 | | ${dut2_vm_refs}= | Create Dictionary
89 | | Set Test Variable | ${dut1_vm_refs}
90 | | Set Test Variable | ${dut2_vm_refs}
91 | | ${jumbo_frames}= | Set Variable If | ${get_framesize} < ${1522}
92 | | ... | ${False} | ${True}
93 | | Set Test Variable | ${jumbo_frames}
94 | | ...
95 | | Given Add '${wt}' worker threads and '${rxq}' rxqueues in 3-node single-link circular topology
96 | | And Add PCI devices to DUTs in 3-node single link topology
97 | | And Run Keyword If | ${get_framesize} < ${1522}
98 | | ... | Add no multi seg to all DUTs
99 | | And Apply startup configuration on all VPP DUTs
100 | | When Initialize IPv4 forwarding with vhost for '2' VMs in 3-node circular topology
101 | | And Configure '2' guest VMs with dpdk-testpmd-mac connected via vhost-user in 3-node circular topology
102 | | Then Run Keyword If | '${search_type}' == 'NDR'
103 | | ... | Find NDR using binary search and pps
104 | | ... | ${framesize} | ${binary_min} | ${binary_max} | ${traffic_profile}
105 | | ... | ${min_rate} | ${max_rate} | ${threshold}
106 | | ... | ELSE IF | '${search_type}' == 'PDR'
107 | | ... | Find PDR using binary search and pps
108 | | ... | ${framesize} | ${binary_min} | ${binary_max} | ${traffic_profile}
109 | | ... | ${min_rate} | ${max_rate} | ${threshold}
110 | | ... | ${perf_pdr_loss_acceptance} | ${perf_pdr_loss_acceptance_type}
111
112 *** Test Cases ***
113 | tc01-64B-1t1c-ethip4-ip4base-eth-4vhostvr1024-2vm-ndrdisc
114 | | [Documentation]
115 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core, \
116 | | ... | 1 receive queue per NIC port.
117 | | ... | [Ver] Find NDR for 64 Byte frames \
118 | | ... | using binary search start at 10GE linerate, step 10kpps.
119 | | ...
120 | | [Tags] | 64B | 1T1C | STHREAD | NDRDISC
121 | | ...
122 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
123 | | wt=1 | rxq=1 | framesize=${64} | min_rate=${10000} | search_type=NDR
124
125 | tc02-64B-1t1c-ethip4-ip4base-eth-4vhostvr1024-2vm-pdrdisc
126 | | [Documentation]
127 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core, \
128 | | ... | 1 receive queue per NIC port.
129 | | ... | [Ver] Find PDR for 64 Byte frames \
130 | | ... | using binary search start at 10GE linerate, step 10kpps, LT=0.5%.
131 | | ...
132 | | [Tags] | 64B | 1T1C | STHREAD | PDRDISC | SKIP_PATCH
133 | | ...
134 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
135 | | wt=1 | rxq=1 | framesize=${64} | min_rate=${10000} | search_type=PDR
136
137 | tc03-1518B-1t1c-ethip4-ip4base-eth-4vhostvr1024-2vm-ndrdisc
138 | | [Documentation]
139 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core, \
140 | | ... | 1 receive queue per NIC port.
141 | | ... | [Ver] Find NDR for 1518 Byte frames \
142 | | ... | using binary search start at 10GE linerate, step 10kpps.
143 | | ...
144 | | [Tags] | 1518B | 1T1C | STHREAD | NDRDISC
145 | | ...
146 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
147 | | wt=1 | rxq=1 | framesize=${1518} | min_rate=${10000} | search_type=NDR
148
149 | tc04-1518B-1t1c-ethip4-ip4base-eth-4vhostvr1024-2vm-pdrdisc
150 | | [Documentation]
151 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core, \
152 | | ... | 1 receive queue per NIC port.
153 | | ... | [Ver] Find PDR for 1518 Byte frames \
154 | | ... | using binary search start at 10GE linerate, step 10kpps, LT=0.5%.
155 | | ...
156 | | [Tags] | 1518B | 1T1C | STHREAD | PDRDISC | SKIP_PATCH
157 | | ...
158 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
159 | | wt=1 | rxq=1 | framesize=${1518} | min_rate=${10000} | search_type=PDR
160
161 | tc05-IMIX-1t1c-ethip4-ip4base-eth-4vhostvr1024-2vm-ndrdisc
162 | | [Documentation]
163 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core, \
164 | | ... | 1 receive queue per NIC port.
165 | | ... | [Ver] Find NDR for IMIX_v4_1 frame \
166 | | ... | size using binary search start at 10GE linerate, step 10kpps.
167 | | ... | IMIX_v4_1 = (28x64B;16x570B;4x1518B)
168 | | ...
169 | | [Tags] | IMIX | 1T1C | STHREAD | NDRDISC
170 | | ...
171 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
172 | | wt=1 | rxq=1 | framesize=IMIX_v4_1 | min_rate=${10000} | search_type=NDR
173
174 | tc06-IMIX-1t1c-ethip4-ip4base-eth-4vhostvr1024-2vm-pdrdisc
175 | | [Documentation]
176 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core, \
177 | | ... | 1 receive queue per NIC port.
178 | | ... | [Ver] Find PDR for IMIX_v4_1 frame \
179 | | ... | size using binary search start at 10GE linerate, step 10kpps, LT=0.5%.
180 | | ... | IMIX_v4_1 = (28x64B;16x570B;4x1518B)
181 | | ...
182 | | [Tags] | IMIX | 1T1C | STHREAD | PDRDISC | SKIP_PATCH
183 | | ...
184 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
185 | | wt=1 | rxq=1 | framesize=IMIX_v4_1 | min_rate=${10000} | search_type=PDR
186
187 | tc07-64B-2t2c-ethip4-ip4base-eth-4vhostvr1024-2vm-ndrdisc
188 | | [Documentation]
189 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores, \
190 | | ... | 1 receive queue per NIC port.
191 | | ... | [Ver] Find NDR for 64 Byte frames \
192 | | ... | using binary search start at 10GE linerate, step 10kpps.
193 | | ...
194 | | [Tags] | 64B | 2T2C | MTHREAD | NDRDISC
195 | | ...
196 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
197 | | wt=2 | rxq=1 | framesize=${64} | min_rate=${10000} | search_type=NDR
198
199 | tc08-64B-2t2c-ethip4-ip4base-eth-4vhostvr1024-2vm-pdrdisc
200 | | [Documentation]
201 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores, \
202 | | ... | 1 receive queue per NIC port.
203 | | ... | [Ver] Find PDR for 64 Byte frames \
204 | | ... | using binary search start at 10GE linerate, step 10kpps, LT=0.5%.
205 | | ...
206 | | [Tags] | 64B | 2T2C | MTHREAD | PDRDISC | SKIP_PATCH
207 | | ...
208 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
209 | | wt=2 | rxq=1 | framesize=${64} | min_rate=${10000} | search_type=PDR
210
211 | tc09-1518B-2t2c-ethip4-ip4base-eth-4vhostvr1024-2vm-ndrdisc
212 | | [Documentation]
213 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores, \
214 | | ... | 1 receive queue per NIC port.
215 | | ... | [Ver] Find NDR for 1518 Byte frames \
216 | | ... | using binary search start at 10GE linerate, step 10kpps.
217 | | ...
218 | | [Tags] | 1518B | 2T2C | MTHREAD | NDRDISC | SKIP_PATCH
219 | | ...
220 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
221 | | wt=2 | rxq=1 | framesize=${1518} | min_rate=${10000} | search_type=NDR
222
223 | tc10-1518B-2t2c-ethip4-ip4base-eth-4vhostvr1024-2vm-pdrdisc
224 | | [Documentation]
225 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores, \
226 | | ... | 1 receive queue per NIC port.
227 | | ... | [Ver] Find PDR for 1518 Byte frames \
228 | | ... | using binary search start at 10GE linerate, step 10kpps, LT=0.5%.
229 | | ...
230 | | [Tags] | 1518B | 2T2C | MTHREAD | PDRDISC | SKIP_PATCH
231 | | ...
232 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
233 | | wt=2 | rxq=1 | framesize=${1518} | min_rate=${10000} | search_type=PDR
234
235 | tc11-IMIX-2t2c-ethip4-ip4base-eth-4vhostvr1024-2vm-ndrdisc
236 | | [Documentation]
237 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores, \
238 | | ... | 1 receive queue per NIC port.
239 | | ... | [Ver] Find NDR for IMIX_v4_1 frame \
240 | | ... | size using binary search start at 10GE linerate, step 10kpps.
241 | | ... | IMIX_v4_1 = (28x64B;16x570B;4x1518B)
242 | | ...
243 | | [Tags] | IMIX | 2T2C | MTHREAD | NDRDISC | SKIP_PATCH
244 | | ...
245 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
246 | | wt=2 | rxq=1 | framesize=IMIX_v4_1 | min_rate=${10000} | search_type=NDR
247
248 | tc12-IMIX-2t2c-ethip4-ip4base-eth-4vhostvr1024-2vm-pdrdisc
249 | | [Documentation]
250 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores, \
251 | | ... | 1 receive queue per NIC port.
252 | | ... | [Ver] Find PDR for IMIX_v4_1 frame \
253 | | ... | size using binary search start at 10GE linerate, step 10kpps, LT=0.5%.
254 | | ... | IMIX_v4_1 = (28x64B;16x570B;4x1518B)
255 | | ...
256 | | [Tags] | IMIX | 2T2C | MTHREAD | PDRDISC | SKIP_PATCH
257 | | ...
258 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
259 | | wt=2 | rxq=1 | framesize=IMIX_v4_1 | min_rate=${10000} | search_type=PDR
260
261 | tc13-64B-4t4c-ethip4-ip4base-eth-4vhostvr1024-2vm-ndrdisc
262 | | [Documentation]
263 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores, \
264 | | ... | 2 receive queues per NIC port.
265 | | ... | [Ver] Find NDR for 64 Byte frames \
266 | | ... | using binary search start at 10GE linerate, step 10kpps.
267 | | ...
268 | | [Tags] | 64B | 4T4C | MTHREAD | NDRDISC
269 | | ...
270 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
271 | | wt=4 | rxq=2 | framesize=${64} | min_rate=${10000} | search_type=NDR
272
273 | tc14-64B-4t4c-ethip4-ip4base-eth-4vhostvr1024-2vm-pdrdisc
274 | | [Documentation]
275 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores, \
276 | | ... | 2 receive queues per NIC port.
277 | | ... | [Ver] Find PDR for 64 Byte frames \
278 | | ... | using binary search start at 10GE linerate, step 10kpps, LT=0.5%.
279 | | ...
280 | | [Tags] | 64B | 4T4C | MTHREAD | PDRDISC | SKIP_PATCH
281 | | ...
282 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
283 | | wt=4 | rxq=2 | framesize=${64} | min_rate=${10000} | search_type=PDR
284
285 | tc15-1518B-4t4c-ethip4-ip4base-eth-4vhostvr1024-2vm-ndrdisc
286 | | [Documentation]
287 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores, \
288 | | ... | 2 receive queues per NIC port.
289 | | ... | [Ver] Find NDR for 1518 Byte frames \
290 | | ... | using binary search start at 10GE linerate, step 10kpps.
291 | | ...
292 | | [Tags] | 1518B | 4T4C | MTHREAD | NDRDISC | SKIP_PATCH
293 | | ...
294 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
295 | | wt=4 | rxq=2 | framesize=${1518} | min_rate=${10000} | search_type=NDR
296
297 | tc16-1518B-4t4c-ethip4-ip4base-eth-4vhostvr1024-2vm-pdrdisc
298 | | [Documentation]
299 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores, \
300 | | ... | 2 receive queues per NIC port.
301 | | ... | [Ver] Find PDR for 1518 Byte frames \
302 | | ... | using binary search start at 10GE linerate, step 10kpps, LT=0.5%.
303 | | ...
304 | | [Tags] | 1518B | 4T4C | MTHREAD | PDRDISC | SKIP_PATCH
305 | | ...
306 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
307 | | wt=4 | rxq=2 | framesize=${1518} | min_rate=${10000} | search_type=PDR
308
309 | tc17-IMIX-4t4c-ethip4-ip4base-eth-4vhostvr1024-2vm-ndrdisc
310 | | [Documentation]
311 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores, \
312 | | ... | 2 receive queues per NIC port.
313 | | ... | [Ver] Find NDR for IMIX_v4_1 frame \
314 | | ... | size using binary search start at 10GE linerate, step 10kpps.
315 | | ... | IMIX_v4_1 = (28x64B;16x570B;4x1518B)
316 | | ...
317 | | [Tags] | IMIX | 4T4C | MTHREAD | NDRDISC | SKIP_PATCH
318 | | ...
319 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
320 | | wt=4 | rxq=2 | framesize=IMIX_v4_1 | min_rate=${10000} | search_type=NDR
321
322 | tc18-IMIX-4t4c-ethip4-ip4base-eth-4vhostvr1024-2vm-pdrdisc
323 | | [Documentation]
324 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores, \
325 | | ... | 2 receive queues per NIC port.
326 | | ... | [Ver] Find PDR for IMIX_v4_1 frame \
327 | | ... | size using binary search start at 10GE linerate, step 10kpps, LT=0.5%.
328 | | ... | IMIX_v4_1 = (28x64B;16x570B;4x1518B)
329 | | ...
330 | | [Tags] | IMIX | 4T4C | MTHREAD | PDRDISC | SKIP_PATCH
331 | | ...
332 | | [Template] | Discover NDR or PDR for ethip4-ip4base-eth-4vhostvr1024-2vm
333 | | wt=4 | rxq=2 | framesize=IMIX_v4_1 | min_rate=${10000} | search_type=PDR