CSIT-530: Add common setup and teardown to perf tests
[csit.git] / tests / perf / 40ge2p1xl710-ethip4-ip4base-ndrdisc.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.robot
16 | Library | resources.libraries.python.topology.Topology
17 | Library | resources.libraries.python.NodePath
18 | Library | resources.libraries.python.InterfaceUtil
19 | Library | resources.libraries.python.IPv4Setup.Dut | ${nodes['DUT1']}
20 | ... | WITH NAME | dut1_v4
21 | Library | resources.libraries.python.IPv4Setup.Dut | ${nodes['DUT2']}
22 | ... | WITH NAME | dut2_v4
23 | ...
24 | Force Tags | 3_NODE_SINGLE_LINK_TOPO | PERFTEST | HW_ENV | NDRPDRDISC
25 | ... | NIC_Intel-XL710 | ETH | IP4FWD | BASE
26 | ...
27 | Suite Setup | 3-node Performance Suite Setup with DUT's NIC model
28 | ... | L3 | Intel-XL710
29 | Suite Teardown | 3-node Performance Suite Teardown
30 | ...
31 | Test Setup | Performance test setup
32 | Test Teardown | Performance test teardown | ${min_rate}pps | ${framesize}
33 | ... | 3-node-IPv4
34 | ...
35 | Documentation | *RFC2544: Pkt throughput IPv4 routing test cases*
36 | ...
37 | ... | *[Top] Network Topologies:* TG-DUT1-DUT2-TG 3-node circular topology
38 | ... | with single links between nodes.
39 | ... | *[Enc] Packet Encapsulations:* Eth-IPv4 for IPv4 routing.
40 | ... | *[Cfg] DUT configuration:* DUT1 and DUT2 are configured with IPv4
41 | ... | routing and two static IPv4 /24 route entries. DUT1 and DUT2 tested with
42 | ... | 2p40GE NIC XL710 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 # XL710-DA2 bandwidth limit ~49Gbps/2=24.5Gbps
59 | ${s_24.5G} | ${24500000000}
60 # XL710-DA2 Mpps limit 37.5Mpps/2=18.75Mpps
61 | ${s_18.75Mpps} | ${18750000}
62
63 *** Test Cases ***
64 | tc01-64B-1t1c-ethip4-ip4base-ndrdisc
65 | | [Documentation]
66 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core, \
67 | | ... | 1 receive queue per NIC port. [Ver] Find NDR for 64 Byte frames
68 | | ... | using binary search start at 18.75Mpps rate, step 100kpps.
69 | | [Tags] | 1T1C | STHREAD | NDRDISC
70 | | ${framesize}= | Set Variable | ${64}
71 | | ${min_rate}= | Set Variable | ${100000}
72 | | ${max_rate}= | Set Variable | ${s_18.75Mpps}
73 | | ${binary_min}= | Set Variable | ${min_rate}
74 | | ${binary_max}= | Set Variable | ${max_rate}
75 | | ${threshold}= | Set Variable | ${min_rate}
76 | | Given Add '1' worker threads and rxqueues '1' in 3-node single-link topo
77 | | And   Add PCI devices to DUTs from 3-node single link topology
78 | | And   Add No Multi Seg to all DUTs
79 | | And   Apply startup configuration on all VPP DUTs
80 | | And   IPv4 forwarding initialized in a 3-node circular topology
81 | | Then Find NDR using binary search and pps | ${framesize} | ${binary_min}
82 | | ...                                       | ${binary_max} | 3-node-IPv4
83 | | ...                                       | ${min_rate} | ${max_rate}
84 | | ...                                       | ${threshold}
85
86 | tc03-1518B-1t1c-ethip4-ip4base-ndrdisc
87 | | [Documentation]
88 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core, \
89 | | ... | 1 receive queue per NIC port. [Ver] Find NDR for 1518 Byte frames
90 | | ... | using binary search start at 24.5G rate, step 10kpps.
91 | | [Tags] | 1T1C | STHREAD | NDRDISC
92 | | ${framesize}= | Set Variable | ${1518}
93 | | ${min_rate}= | Set Variable | ${10000}
94 | | ${max_rate}= | Calculate pps | ${s_24.5G} | ${framesize}
95 | | ${binary_min}= | Set Variable | ${min_rate}
96 | | ${binary_max}= | Set Variable | ${max_rate}
97 | | ${threshold}= | Set Variable | ${min_rate}
98 | | Given Add '1' worker threads and rxqueues '1' in 3-node single-link topo
99 | | And   Add PCI devices to DUTs from 3-node single link topology
100 | | And   Add No Multi Seg to all DUTs
101 | | And   Apply startup configuration on all VPP DUTs
102 | | And   IPv4 forwarding initialized in a 3-node circular topology
103 | | Then Find NDR using binary search and pps | ${framesize} | ${binary_min}
104 | | ...                                       | ${binary_max} | 3-node-IPv4
105 | | ...                                       | ${min_rate} | ${max_rate}
106 | | ...                                       | ${threshold}
107
108 | tc07-64B-2t2c-ethip4-ip4base-ndrdisc
109 | | [Documentation]
110 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores, \
111 | | ... | 1 receive queue per NIC port. [Ver] Find NDR for 64 Byte frames
112 | | ... | using binary search start at 18.75Mpps rate, step 100kpps.
113 | | [Tags] | 2T2C | MTHREAD | NDRDISC
114 | | ${framesize}= | Set Variable | ${64}
115 | | ${min_rate}= | Set Variable | ${100000}
116 | | ${max_rate}= | Set Variable | ${s_18.75Mpps}
117 | | ${binary_min}= | Set Variable | ${min_rate}
118 | | ${binary_max}= | Set Variable | ${max_rate}
119 | | ${threshold}= | Set Variable | ${min_rate}
120 | | Given Add '2' worker threads and rxqueues '1' in 3-node single-link topo
121 | | And   Add PCI devices to DUTs from 3-node single link topology
122 | | And   Add No Multi Seg to all DUTs
123 | | And   Apply startup configuration on all VPP DUTs
124 | | And   IPv4 forwarding initialized in a 3-node circular topology
125 | | Then Find NDR using binary search and pps | ${framesize} | ${binary_min}
126 | | ...                                       | ${binary_max} | 3-node-IPv4
127 | | ...                                       | ${min_rate} | ${max_rate}
128 | | ...                                       | ${threshold}
129
130 | tc09-1518B-2t2c-ethip4-ip4base-ndrdisc
131 | | [Documentation]
132 | | ... | [Cfg] DUT runs IPv4 routing config with 2 threads, 2 phy cores, \
133 | | ... | 1 receive queue per NIC port. [Ver] Find NDR for 1518 Byte frames
134 | | ... | using binary search start at 24.5G rate, step 10kpps.
135 | | [Tags] | 2T2C | MTHREAD | NDRDISC | SKIP_PATCH
136 | | ${framesize}= | Set Variable | ${1518}
137 | | ${min_rate}= | Set Variable | ${10000}
138 | | ${max_rate}= | Calculate pps | ${s_24.5G} | ${framesize}
139 | | ${binary_min}= | Set Variable | ${min_rate}
140 | | ${binary_max}= | Set Variable | ${max_rate}
141 | | ${threshold}= | Set Variable | ${min_rate}
142 | | Given Add '2' worker threads and rxqueues '1' in 3-node single-link topo
143 | | And   Add PCI devices to DUTs from 3-node single link topology
144 | | And   Add No Multi Seg to all DUTs
145 | | And   Apply startup configuration on all VPP DUTs
146 | | And   IPv4 forwarding initialized in a 3-node circular topology
147 | | Then Find NDR using binary search and pps | ${framesize} | ${binary_min}
148 | | ...                                       | ${binary_max} | 3-node-IPv4
149 | | ...                                       | ${min_rate} | ${max_rate}
150 | | ...                                       | ${threshold}
151
152 | tc13-64B-4t4c-ethip4-ip4base-ndrdisc
153 | | [Documentation]
154 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores, \
155 | | ... | 2 receive queues per NIC port. [Ver] Find NDR for 64 Byte frames
156 | | ... | using binary search start at 18.75Mpps rate, step 100kpps.
157 | | [Tags] | 4T4C | MTHREAD | NDRDISC
158 | | ${framesize}= | Set Variable | ${64}
159 | | ${min_rate}= | Set Variable | ${100000}
160 | | ${max_rate}= | Set Variable | ${s_18.75Mpps}
161 | | ${binary_min}= | Set Variable | ${min_rate}
162 | | ${binary_max}= | Set Variable | ${max_rate}
163 | | ${threshold}= | Set Variable | ${min_rate}
164 | | Given Add '4' worker threads and rxqueues '2' in 3-node single-link topo
165 | | And   Add PCI devices to DUTs from 3-node single link topology
166 | | And   Add No Multi Seg to all DUTs
167 | | And   Apply startup configuration on all VPP DUTs
168 | | And   IPv4 forwarding initialized in a 3-node circular topology
169 | | Then Find NDR using binary search and pps | ${framesize} | ${binary_min}
170 | | ...                                       | ${binary_max} | 3-node-IPv4
171 | | ...                                       | ${min_rate} | ${max_rate}
172 | | ...                                       | ${threshold}
173
174 | tc15-1518B-4t4c-ethip4-ip4base-ndrdisc
175 | | [Documentation]
176 | | ... | [Cfg] DUT runs IPv4 routing config with 4 threads, 4 phy cores, \
177 | | ... | 2 receive queues per NIC port. [Ver] Find NDR for 1518 Byte frames
178 | | ... | using binary search start at 24.5G rate, step 10kpps.
179 | | [Tags] | 4T4C | MTHREAD | NDRDISC | SKIP_PATCH
180 | | ${framesize}= | Set Variable | ${1518}
181 | | ${min_rate}= | Set Variable | ${10000}
182 | | ${max_rate}= | Calculate pps | ${s_24.5G} | ${framesize}
183 | | ${binary_min}= | Set Variable | ${min_rate}
184 | | ${binary_max}= | Set Variable | ${max_rate}
185 | | ${threshold}= | Set Variable | ${min_rate}
186 | | Given Add '4' worker threads and rxqueues '2' in 3-node single-link topo
187 | | And   Add PCI devices to DUTs from 3-node single link topology
188 | | And   Add No Multi Seg to all DUTs
189 | | And   Apply startup configuration on all VPP DUTs
190 | | And   IPv4 forwarding initialized in a 3-node circular topology
191 | | Then Find NDR using binary search and pps | ${framesize} | ${binary_min}
192 | | ...                                       | ${binary_max} | 3-node-IPv4
193 | | ...                                       | ${min_rate} | ${max_rate}
194 | | ...                                       | ${threshold}
195
196 | tc19-IMIX-1t1c-ethip4-ip4base-ndrdisc
197 | | [Documentation]
198 | | ... | [Cfg] DUT runs IPv4 routing config with 1 thread, 1 phy core, \
199 | | ... | 1 receive queue per NIC port. [Ver] Find NDR for IMIX_v4_1 frame size
200 | | ... | using binary search start at 24.5G rate, step 100kpps.
201 | | ... | IMIX_v4_1 = (28x64B;16x570B;4x1518B)
202 | | [Tags] | 1T1C | STHREAD | NDRDISC
203 | | ${framesize}= | Set Variable | IMIX_v4_1
204 | | ${min_rate}= | Set Variable | ${100000}
205 | | ${max_rate}= | Calculate pps | ${s_24.5G} | ${framesize}
206 | | ${binary_min}= | Set Variable | ${min_rate}
207 | | ${binary_max}= | Set Variable | ${max_rate}
208 | | ${threshold}= | Set Variable | ${min_rate}
209 | | Given Add '1' worker threads and rxqueues '1' in 3-node single-link topo
210 | | And   Add all PCI devices to all DUTs
211 | | And   Add No Multi Seg to all DUTs
212 | | And   Apply startup configuration on all VPP DUTs
213 | | And   IPv4 forwarding initialized in a 3-node circular topology
214 | | Then Find NDR using binary search and pps | ${framesize} | ${binary_min}
215 | | ...                                       | ${binary_max} | 3-node-IPv4
216 | | ...                                       | ${min_rate} | ${max_rate}
217 | | ...                                       | ${threshold}
218
219 | tc20-IMIX-2t2c-ethip4-ip4base-ndrdisc
220 | | [Documentation]
221 | | ... | [Cfg] DUT runs IPv4 routing config with 2 thread, 2 phy core, \
222 | | ... | 1 receive queue per NIC port. [Ver] Find NDR for IMIX_v4_1 frame size
223 | | ... | using binary search start at 24.5G rate, step 100kpps.
224 | | ... | IMIX_v4_1 = (28x64B;16x570B;4x1518B)
225 | | [Tags] | 2T2C | MTHREAD | NDRDISC | SKIP_PATCH
226 | | ${framesize}= | Set Variable | IMIX_v4_1
227 | | ${min_rate}= | Set Variable | ${100000}
228 | | ${max_rate}= | Calculate pps | ${s_24.5G} | ${framesize}
229 | | ${binary_min}= | Set Variable | ${min_rate}
230 | | ${binary_max}= | Set Variable | ${max_rate}
231 | | ${threshold}= | Set Variable | ${min_rate}
232 | | Given Add '2' worker threads and rxqueues '1' in 3-node single-link topo
233 | | And   Add all PCI devices to all DUTs
234 | | And   Add No Multi Seg to all DUTs
235 | | And   Apply startup configuration on all VPP DUTs
236 | | And   IPv4 forwarding initialized in a 3-node circular topology
237 | | Then Find NDR using binary search and pps | ${framesize} | ${binary_min}
238 | | ...                                       | ${binary_max} | 3-node-IPv4
239 | | ...                                       | ${min_rate} | ${max_rate}
240 | | ...                                       | ${threshold}
241
242 | tc21-IMIX-4t4c-ethip4-ip4base-ndrdisc
243 | | [Documentation]
244 | | ... | [Cfg] DUT runs IPv4 routing config with 4 thread, 4 phy core, \
245 | | ... | 2 receive queue per NIC port. [Ver] Find NDR for IMIX_v4_1 frame size
246 | | ... | using binary search start at 24.5G rate, step 100kpps.
247 | | ... | IMIX_v4_1 = (28x64B;16x570B;4x1518B)
248 | | [Tags] | 4T4C | MTHREAD | NDRDISC | SKIP_PATCH
249 | | ${framesize}= | Set Variable | IMIX_v4_1
250 | | ${min_rate}= | Set Variable | ${100000}
251 | | ${max_rate}= | Calculate pps | ${s_24.5G} | ${framesize}
252 | | ${binary_min}= | Set Variable | ${min_rate}
253 | | ${binary_max}= | Set Variable | ${max_rate}
254 | | ${threshold}= | Set Variable | ${min_rate}
255 | | Given Add '4' worker threads and rxqueues '2' in 3-node single-link topo
256 | | And   Add all PCI devices to all DUTs
257 | | And   Add No Multi Seg to all DUTs
258 | | And   Apply startup configuration on all VPP DUTs
259 | | And   IPv4 forwarding initialized in a 3-node circular topology
260 | | Then Find NDR using binary search and pps | ${framesize} | ${binary_min}
261 | | ...                                       | ${binary_max} | 3-node-IPv4
262 | | ...                                       | ${min_rate} | ${max_rate}
263 | | ...                                       | ${threshold}
264