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