CSIT-672: SNAT44 multi-thread multi-core perf tests
[csit.git] / tests / vpp / perf / ip4 / 10ge2p1x520-ethip4udp-ip4base-nat44-ndrpdrdisc.robot
1 # Copyright (c) 2017 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 | Resource | resources/libraries/robot/ip/nat.robot
17 | Resource | resources/libraries/robot/shared/traffic.robot
18 | ...
19 | Force Tags | 3_NODE_SINGLE_LINK_TOPO | PERFTEST | HW_ENV | NDRPDRDISC
20 | ... | NIC_Intel-X520-DA2 | ETH | IP4FWD | FEATURE | NAT44 | BASE
21 | ...
22 | Suite Setup | Set up 3-node performance topology with DUT's NIC model
23 | ... | L3 | Intel-X520-DA2
24 | Suite Teardown | Tear down 3-node performance topology
25 | ...
26 | Test Setup | Set up performance test
27 | ...
28 | Test Teardown | Tear down performance discovery test with NAT
29 | ... | ${min_rate}pps | ${framesize} | ${traffic_profile}
30 | ...
31 | Documentation | *NAT44 performance test cases*
32 | ...
33 | ... | *High level description*
34 | ...
35 | ... | - NDR and PDR tests
36 | ... | - 3-node topology, TG-DUT1-DUT2-TG, NAT44 is enabled between DUTs.
37 | ... | - Cores / threads: 1t1c, 2t2c, and 4t4c
38 | ... | - Framesize: 64B, 1518B, IMIX
39 | ... | - Packet: ETH / IP(src, dst) / UDP(src_port, dst_port) / payload
40 | ...
41 | ... | *Low level description*
42 | ...
43 | ... | *[Top] Network Topologies:* TG-DUT1-DUT2-TG 3-node circular topology
44 | ... | with single links between nodes.
45 | ... | *[Enc] Packet Encapsulations:* Eth-IPv4-UDP for IPv4 routing.
46 | ... | *[Cfg] DUT configuration:* DUT1 and DUT2 are configured with IPv4
47 | ... | routing and two static IPv4 /24 and IPv4/20 route entries. DUT1 and DUT2
48 | ... | tested with 2p10GE NIC X520 Niantic by Intel.
49 | ... | *[Ver] TG verification:* TG finds and reports throughput NDR (Non Drop
50 | ... | Rate) with zero packet loss tolerance or throughput PDR (Partial Drop
51 | ... | Rate) with non-zero packet loss tolerance (LT) expressed in percentage
52 | ... | of packets transmitted. NDR and PDR are discovered for different
53 | ... | Ethernet L2 frame sizes using either binary search or linear search
54 | ... | algorithms with configured starting rate and final step that determines
55 | ... | throughput measurement resolution. Test packets are generated by TG on
56 | ... | links to DUTs. TG traffic profile contains two L3 flow-groups
57 | ... | (flow-group per direction, one flow per flow-group) with all packets
58 | ... | containing Ethernet header, IPv4 header with UDP header and static
59 | ... | payload. MAC addresses are matching MAC addresses of the TG node
60 | ... | interfaces.
61 | ... | *[Ref] Applicable standard specifications:* RFC2544.
62
63 *** Variables ***
64 # X520-DA2 bandwidth limit
65 | ${s_limit} | ${10000000000}
66 # Traffic profile:
67 | ${traffic_profile} | trex-sl-3n-ethip4udp-1u1p
68
69 *** Keywords ***
70 | Discover NDR or PDR for IPv4 routing with NAT44
71 | | ...
72 | | [Arguments] | ${wt} | ${rxq} | ${framesize} | ${min_rate} | ${search_type}
73 | | ...
74 | | Set Test Variable | ${framesize}
75 | | Set Test Variable | ${min_rate}
76 | | ${max_rate}= | Calculate pps | ${s_limit} | ${framesize}
77 | | ${binary_min}= | Set Variable | ${min_rate}
78 | | ${binary_max}= | Set Variable | ${max_rate}
79 | | ${threshold}= | Set Variable | ${min_rate}
80 | | ${get_framesize}= | Get Frame Size | ${framesize}
81 | | ...
82 | | Given Add '${wt}' worker threads and '${rxq}' rxqueues in 3-node single-link circular topology
83 | | And Add PCI devices to DUTs in 3-node single link topology
84 | | And Run Keyword If | ${get_framesize} < ${1522}
85 | | ... | Add no multi seg to all DUTs
86 | | And Add NAT to all DUTs
87 | | And Apply startup configuration on all VPP DUTs
88 | | When Initialize NAT44 in 3-node circular topology
89 | | Then Run Keyword If | '${search_type}' == 'NDR'
90 | | ... | Find NDR using binary search and pps
91 | | ... | ${framesize} | ${binary_min} | ${binary_max} | ${traffic_profile}
92 | | ... | ${min_rate} | ${max_rate} | ${threshold}
93 | | ... | ELSE IF | '${search_type}' == 'PDR'
94 | | ... | Find PDR using binary search and pps
95 | | ... | ${framesize} | ${binary_min} | ${binary_max} | ${traffic_profile}
96 | | ... | ${min_rate} | ${max_rate} | ${threshold}
97 | | ... | ${perf_pdr_loss_acceptance} | ${perf_pdr_loss_acceptance_type}
98
99 *** Test Cases ***
100 | tc01-64B-1t1c-ethip4-ip4base-snat-1u-1p-ndrdisc
101 | | [Documentation]
102 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core,\
103 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
104 | | ... | 1 user and 1 port (session) per user.
105 | | ... | [Ver] Find NDR for 64 Byte frames using binary search start at 10GE\
106 | | ... | linerate, step 100kpps.
107 | | ...
108 | | [Tags] | 64B | 1T1C | STHREAD | NDRDISC
109 | | ...
110 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
111 | | wt=1 | rxq=1 | framesize=${64} | min_rate=${100000} | search_type=NDR
112
113 | tc02-64B-1t1c-ethip4-ip4base-snat-1u-1p-pdrdisc
114 | | [Documentation]
115 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core,\
116 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
117 | | ... | 1 user and 1 port (session) per user.
118 | | ... | [Ver] Find PDR for 64 Byte frames using binary search start at 10GE\
119 | | ... | linerate, step 100kpps.
120 | | ...
121 | | [Tags] | 64B | 1T1C | STHREAD | PDRDISC | SKIP_PATCH
122 | | ...
123 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
124 | | wt=1 | rxq=1 | framesize=${64} | min_rate=${100000} | search_type=PDR
125
126 | tc03-1518B-1t1c-ethip4-ip4base-snat-1u-1p-ndrdisc
127 | | [Documentation]
128 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core,\
129 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
130 | | ... | 1 user and 1 port (session) per user.
131 | | ... | [Ver] Find NDR for 1518 Byte frames using binary search start at 10GE\
132 | | ... | linerate, step 100kpps.
133 | | ...
134 | | [Tags] | 1518B | 1T1C | STHREAD | NDRDISC
135 | | ...
136 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
137 | | wt=1 | rxq=1 | framesize=${1518} | min_rate=${100000} | search_type=NDR
138
139 | tc04-1518B-1t1c-ethip4-ip4base-snat-1u-1p-pdrdisc
140 | | [Documentation]
141 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core,\
142 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
143 | | ... | 1 user and 1 port (session) per user.
144 | | ... | [Ver] Find PDR for 1518 Byte frames using binary search start at 10GE\
145 | | ... | linerate, step 100kpps.
146 | | ...
147 | | [Tags] | 1518B | 1T1C | STHREAD | PDRDISC | SKIP_PATCH
148 | | ...
149 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
150 | | wt=1 | rxq=1 | framesize=${1518} | min_rate=${100000} | search_type=PDR
151
152 | tc05-IMIX-1t1c-ethip4-ip4base-snat-1u-1p-ndrdisc
153 | | [Documentation]
154 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core,\
155 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
156 | | ... | 1 user and 1 port (session) per user.
157 | | ... | [Ver] Find NDR for IMIX frames using binary search start at 10GE\
158 | | ... | linerate, step 100kpps.
159 | | ...
160 | | [Tags] | IMIX | 1T1C | STHREAD | NDRDISC
161 | | ...
162 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
163 | | wt=1 | rxq=1 | framesize=IMIX_v4_1 | min_rate=${100000} | search_type=NDR
164
165 | tc06-IMIX-1t1c-ethip4-ip4base-snat-1u-1p-pdrdisc
166 | | [Documentation]
167 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core,\
168 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
169 | | ... | 1 user and 1 port (session) per user.
170 | | ... | [Ver] Find PDR for IMIX frames using binary search start at 10GE\
171 | | ... | linerate, step 100kpps.
172 | | ...
173 | | [Tags] | IMIX | 1T1C | STHREAD | PDRDISC | SKIP_PATCH
174 | | ...
175 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
176 | | wt=1 | rxq=1 | framesize=IMIX_v4_1 | min_rate=${100000} | search_type=PDR
177
178 | tc07-64B-2t2c-ethip4-ip4base-snat-1u-1p-ndrdisc
179 | | [Documentation]
180 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores,\
181 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
182 | | ... | 1 user and 1 port (session) per user.
183 | | ... | [Ver] Find NDR for 64 Byte frames using binary search start at 10GE\
184 | | ... | linerate, step 100kpps.
185 | | ...
186 | | [Tags] | 64B | 2T2C | MTHREAD | NDRDISC
187 | | ...
188 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
189 | | wt=2 | rxq=1 | framesize=${64} | min_rate=${100000} | search_type=NDR
190
191 | tc08-64B-2t2c-ethip4-ip4base-snat-1u-1p-pdrdisc
192 | | [Documentation]
193 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores,\
194 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
195 | | ... | 1 user and 1 port (session) per user.
196 | | ... | [Ver] Find PDR for 64 Byte frames using binary search start at 10GE\
197 | | ... | linerate, step 100kpps.
198 | | ...
199 | | [Tags] | 64B | 2T2C | MTHREAD | PDRDISC | SKIP_PATCH
200 | | ...
201 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
202 | | wt=2 | rxq=1 | framesize=${64} | min_rate=${100000} | search_type=PDR
203
204 | tc09-1518B-2t2c-ethip4-ip4base-snat-1u-1p-ndrdisc
205 | | [Documentation]
206 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores,\
207 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
208 | | ... | 1 user and 1 port (session) per user.
209 | | ... | [Ver] Find NDR for 1518 Byte frames using binary search start at 10GE\
210 | | ... | linerate, step 100kpps.
211 | | ...
212 | | [Tags] | 1518B | 2T2C | MTHREAD | NDRDISC
213 | | ...
214 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
215 | | wt=2 | rxq=1 | framesize=${1518} | min_rate=${100000} | search_type=NDR
216
217 | tc10-1518B-2t2c-ethip4-ip4base-snat-1u-1p-pdrdisc
218 | | [Documentation]
219 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores,\
220 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
221 | | ... | 1 user and 1 port (session) per user.
222 | | ... | [Ver] Find PDR for 1518 Byte frames using binary search start at 10GE\
223 | | ... | linerate, step 100kpps.
224 | | ...
225 | | [Tags] | 1518B | 2T2C | MTHREAD | PDRDISC | SKIP_PATCH
226 | | ...
227 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
228 | | wt=2 | rxq=1 | framesize=${1518} | min_rate=${100000} | search_type=PDR
229
230 | tc11-IMIX-2t2c-ethip4-ip4base-snat-1u-1p-ndrdisc
231 | | [Documentation]
232 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores,\
233 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
234 | | ... | 1 user and 1 port (session) per user.
235 | | ... | [Ver] Find NDR for IMIX frames using binary search start at 10GE\
236 | | ... | linerate, step 100kpps.
237 | | ...
238 | | [Tags] | IMIX | 2T2C | MTHREAD | NDRDISC
239 | | ...
240 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
241 | | wt=2 | rxq=1 | framesize=IMIX_v4_1 | min_rate=${100000} | search_type=NDR
242
243 | tc12-IMIX-2t2c-ethip4-ip4base-snat-1u-1p-pdrdisc
244 | | [Documentation]
245 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores,\
246 | | ... | 1 receive queue per NIC port. NAT44 is configured between DUTs -\
247 | | ... | 1 user and 1 port (session) per user.
248 | | ... | [Ver] Find PDR for IMIX frames using binary search start at 10GE\
249 | | ... | linerate, step 100kpps.
250 | | ...
251 | | [Tags] | IMIX | 2T2C | MTHREAD | PDRDISC | SKIP_PATCH
252 | | ...
253 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
254 | | wt=2 | rxq=1 | framesize=IMIX_v4_1 | min_rate=${100000} | search_type=PDR
255
256 | tc13-64B-4t4c-ethip4-ip4base-snat-1u-1p-ndrdisc
257 | | [Documentation]
258 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores,\
259 | | ... | 2 receive queues per NIC port. NAT44 is configured between DUTs -\
260 | | ... | 1 user and 1 port (session) per user.
261 | | ... | [Ver] Find NDR for 64 Byte frames using binary search start at 10GE\
262 | | ... | linerate, step 100kpps.
263 | | ...
264 | | [Tags] | 64B | 4T4C | MTHREAD | NDRDISC
265 | | ...
266 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
267 | | wt=4 | rxq=2 | framesize=${64} | min_rate=${100000} | search_type=NDR
268
269 | tc14-64B-4t4c-ethip4-ip4base-snat-1u-1p-pdrdisc
270 | | [Documentation]
271 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores,\
272 | | ... | 2 receive queues per NIC port. NAT44 is configured between DUTs -\
273 | | ... | 1 user and 1 port (session) per user.
274 | | ... | [Ver] Find PDR for 64 Byte frames using binary search start at 10GE\
275 | | ... | linerate, step 100kpps.
276 | | ...
277 | | [Tags] | 64B | 4T4C | MTHREAD | PDRDISC | SKIP_PATCH
278 | | ...
279 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
280 | | wt=4 | rxq=2 | framesize=${64} | min_rate=${100000} | search_type=PDR
281
282 | tc15-1518B-4t4c-ethip4-ip4base-snat-1u-1p-ndrdisc
283 | | [Documentation]
284 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores,\
285 | | ... | 2 receive queues per NIC port. NAT44 is configured between DUTs -\
286 | | ... | 1 user and 1 port (session) per user.
287 | | ... | [Ver] Find NDR for 1518 Byte frames using binary search start at 10GE\
288 | | ... | linerate, step 100kpps.
289 | | ...
290 | | [Tags] | 1518B | 4T4C | MTHREAD | NDRDISC
291 | | ...
292 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
293 | | wt=4 | rxq=2 | framesize=${1518} | min_rate=${100000} | search_type=NDR
294
295 | tc16-1518B-4t4c-ethip4-ip4base-snat-1u-1p-pdrdisc
296 | | [Documentation]
297 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores,\
298 | | ... | 2 receive queues per NIC port. NAT44 is configured between DUTs -\
299 | | ... | 1 user and 1 port (session) per user.
300 | | ... | [Ver] Find PDR for 1518 Byte frames using binary search start at 10GE\
301 | | ... | linerate, step 100kpps.
302 | | ...
303 | | [Tags] | 1518B | 4T4C | MTHREAD | PDRDISC | SKIP_PATCH
304 | | ...
305 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
306 | | wt=4 | rxq=2 | framesize=${1518} | min_rate=${100000} | search_type=PDR
307
308 | tc17-IMIX-4t4c-ethip4-ip4base-snat-1u-1p-ndrdisc
309 | | [Documentation]
310 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores,\
311 | | ... | 2 receive queues per NIC port. NAT44 is configured between DUTs -\
312 | | ... | 1 user and 1 port (session) per user.
313 | | ... | [Ver] Find NDR for IMIX frames using binary search start at 10GE\
314 | | ... | linerate, step 100kpps.
315 | | ...
316 | | [Tags] | IMIX | 4T4C | MTHREAD | NDRDISC
317 | | ...
318 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
319 | | wt=4 | rxq=2 | framesize=IMIX_v4_1 | min_rate=${100000} | search_type=NDR
320
321 | tc18-IMIX-4t4c-ethip4-ip4base-snat-1u-1p-pdrdisc
322 | | [Documentation]
323 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores,\
324 | | ... | 2 receive queues per NIC port. NAT44 is configured between DUTs -\
325 | | ... | 1 user and 1 port (session) per user.
326 | | ... | [Ver] Find PDR for IMIX frames using binary search start at 10GE\
327 | | ... | linerate, step 100kpps.
328 | | ...
329 | | [Tags] | IMIX | 4T4C | MTHREAD | PDRDISC | SKIP_PATCH
330 | | ...
331 | | [Template] | Discover NDR or PDR for IPv4 routing with NAT44
332 | | wt=4 | rxq=2 | framesize=IMIX_v4_1 | min_rate=${100000} | search_type=PDR