CSIT-1202: Unify min_rate
[csit.git] / tests / vpp / perf / l2 / 40ge2p1xl710-eth-l2bdbasemaclrn-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 | Library | resources.libraries.python.NodePath
17 | ...
18 | Force Tags | 3_NODE_SINGLE_LINK_TOPO | PERFTEST | HW_ENV | NDRPDRDISC
19 | ... | NIC_Intel-XL710 | ETH | L2BDMACLRN | BASE
20 | Suite Setup | Set up 3-node performance topology with DUT's NIC model
21 | ... | L2 | Intel-XL710
22 | Suite Teardown | Tear down 3-node performance topology
23 | ...
24 | Test Setup | Set up performance test
25 | ...
26 | Test Teardown | Tear down performance discovery test | ${min_rate}pps
27 | ... | ${framesize} | ${traffic_profile}
28 | ...
29 | Test Template | Local template
30 | ...
31 | Documentation | *RFC2544: Pkt throughput L2BD test cases*
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 switching of IPv4.
36 | ... | *[Cfg] DUT configuration:* DUT1 and DUT2 are configured with L2 bridge-\
37 | ... | domain and MAC learning enabled. DUT1 and DUT2 tested with 2p40GE NIC\
38 | ... | XL710-DA2 by Intel.
39 | ... | *[Ver] TG verification:* TG finds and reports throughput NDR (Non Drop\
40 | ... | Rate) with zero packet loss tolerance or throughput PDR (Partial Drop\
41 | ... | Rate) with non-zero packet loss tolerance (LT) expressed in percentage\
42 | ... | of packets transmitted. NDR and PDR are discovered for different\
43 | ... | Ethernet L2 frame sizes using either binary search or linear search\
44 | ... | algorithms with configured starting rate and final step that determines\
45 | ... | throughput measurement resolution. Test packets are generated by TG on\
46 | ... | links to DUTs. TG traffic profile contains two L3 flow-groups\
47 | ... | (flow-group per direction, 253 flows per flow-group) with all packets\
48 | ... | containing Ethernet header, IPv4 header with IP protocol=61 and static\
49 | ... | payload. MAC addresses are matching MAC addresses of the TG node\
50 | ... | interfaces.
51 | ... | *[Ref] Applicable standard specifications:* RFC2544.
52
53 *** Variables ***
54 # XL710-DA2 bandwidth limit ~49Gbps/2=24.5Gbps
55 | ${s_24.5G} | ${24500000000}
56 # XL710-DA2 Mpps limit 37.5Mpps/2=18.75Mpps
57 | ${s_18.75Mpps} | ${18750000}
58 # Traffic profile:
59 | ${traffic_profile} | trex-sl-3n-ethip4-ip4src254
60
61 *** Keywords ***
62 | L2 Bridge Domain Binary Search BW limit
63 | | [Arguments] | ${framesize} | ${phy_cores} | ${s_limit}
64 | | ... | ${search_type} | ${min_rate}=${50000}
65 | | Set Test Variable | ${framesize}
66 | | Set Test Variable | ${min_rate}
67 | | ${max_rate}= | Calculate pps | ${s_limit} | ${framesize}
68 | | ${binary_min}= | Set Variable | ${min_rate}
69 | | ${binary_max}= | Set Variable | ${max_rate}
70 | | ${threshold}= | Set Variable | ${min_rate}
71 | | Add worker threads and rxqueues to all DUTs | ${phy_cores} | ${None}
72 | | Add PCI devices to all DUTs
73 | | ${get_framesize}= | Get Frame Size | ${framesize}
74 | | Run Keyword If | ${get_framesize} < ${1522} | Add no multi seg to all DUTs
75 | | Add DPDK dev default RXD to all DUTs | 2048
76 | | Add DPDK dev default TXD to all DUTs | 2048
77 | | Apply startup configuration on all VPP DUTs
78 | | Initialize L2 bridge domain in 3-node circular topology
79 | | Run Keyword If | '${search_type}' == 'NDR'
80 | | ... | Find NDR using binary search and pps
81 | | ... | ${framesize} | ${binary_min} | ${binary_max} | ${traffic_profile}
82 | | ... | ${min_rate} | ${max_rate} | ${threshold}
83 | | ... | ELSE IF | '${search_type}' == 'PDR'
84 | | ... | Find PDR using binary search and pps
85 | | ... | ${framesize} | ${binary_min} | ${binary_max} | ${traffic_profile}
86 | | ... | ${min_rate} | ${max_rate} | ${threshold}
87 | | ... | ${perf_pdr_loss_acceptance} | ${perf_pdr_loss_acceptance_type}
88
89 | L2 Bridge Domain Binary Search
90 | | [Arguments] | ${framesize} | ${phy_cores} | ${s_limit}
91 | | ... | ${search_type} | ${min_rate}=${50000}
92 | | Set Test Variable | ${framesize}
93 | | Set Test Variable | ${min_rate}
94 | | ${max_rate}= | Set Variable | ${s_limit}
95 | | ${binary_min}= | Set Variable | ${min_rate}
96 | | ${binary_max}= | Set Variable | ${max_rate}
97 | | ${threshold}= | Set Variable | ${min_rate}
98 | | Add worker threads and rxqueues to all DUTs | ${phy_cores} | ${None}
99 | | Add PCI devices to all DUTs
100 | | ${get_framesize}= | Get Frame Size | ${framesize}
101 | | Run Keyword If | ${get_framesize} < ${1522} | Add no multi seg to all DUTs
102 | | Add DPDK dev default RXD to all DUTs | 2048
103 | | Add DPDK dev default TXD to all DUTs | 2048
104 | | Apply startup configuration on all VPP DUTs
105 | | Initialize L2 bridge domain in 3-node circular topology
106 | | Run Keyword If | '${search_type}' == 'NDR'
107 | | ... | Find NDR using binary search and pps
108 | | ... | ${framesize} | ${binary_min} | ${binary_max} | ${traffic_profile}
109 | | ... | ${min_rate} | ${max_rate} | ${threshold}
110 | | ... | ELSE IF | '${search_type}' == 'PDR'
111 | | ... | Find PDR using binary search and pps
112 | | ... | ${framesize} | ${binary_min} | ${binary_max} | ${traffic_profile}
113 | | ... | ${min_rate} | ${max_rate} | ${threshold}
114 | | ... | ${perf_pdr_loss_acceptance} | ${perf_pdr_loss_acceptance_type}
115
116 *** Test Cases ***
117 | tc01-64B-1t1c-eth-l2bdbasemaclrn-ndrdisc
118 | | [Documentation]
119 | | ... | [Cfg] DUT runs L2BD switching config with with\
120 | | ... | 1 phy core, 1 receive queue per NIC port.
121 | | ... | [Ver] Find NDR for 64 Byte frames using binary search start at\
122 | | ... | 18.75Mpps rate, step 50kpps.
123 | | [Tags] | 64B | 1C | NDRDISC
124 | | [Template] | L2 Bridge Domain Binary Search
125 | | framesize=${64}  | phy_cores=${1}
126 | | ... | s_limit=${s_18.75Mpps} | search_type=NDR
127
128 | tc03-1518B-1t1c-eth-l2bdbasemaclrn-ndrdisc
129 | | [Documentation]
130 | | ... | [Cfg] DUT runs L2BD switching config with with\
131 | | ... | 1 phy core, 1 receive queue per NIC port.
132 | | ... | [Ver] Find NDR for 1518 Byte frames using binary search start at\
133 | | ... | 24.5G rate, step 50kpps.
134 | | [Tags] | 1518B | 1C | NDRDISC
135 | | [Template] | L2 Bridge Domain Binary Search BW limit
136 | | framesize=${1518}  | phy_cores=${1}
137 | | ... | s_limit=${s_24.5G} | search_type=NDR
138
139 | tc07-64B-2t2c-eth-l2bdbasemaclrn-ndrdisc
140 | | [Documentation]
141 | | ... | [Cfg] DUT runs L2BD switching config with with\
142 | | ... | 2 phy cores, 1 receive queue per NIC port.
143 | | ... | [Ver] Find NDR for 64 Byte frames using binary search start at\
144 | | ... | 18.75Mpps rate, step 50kpps.
145 | | [Tags] | 64B | 2C | NDRDISC
146 | | [Template] | L2 Bridge Domain Binary Search
147 | | framesize=${64}  | phy_cores=${2}
148 | | ... | s_limit=${s_18.75Mpps} | search_type=NDR
149
150 | tc09-1518B-2t2c-eth-l2bdbasemaclrn-ndrdisc
151 | | [Documentation]
152 | | ... | [Cfg] DUT runs L2BD switching config with with\
153 | | ... | 2 phy cores, 1 receive queue per NIC port.
154 | | ... | [Ver] Find NDR for 64 Byte frames using binary search start at\
155 | | ... | 24.5G rate, step 50kpps.
156 | | [Tags] | 1518B | 2C | NDRDISC | SKIP_PATCH
157 | | [Template] | L2 Bridge Domain Binary Search BW limit
158 | | framesize=${1518}  | phy_cores=${2}
159 | | ... | s_limit=${s_24.5G} | search_type=NDR
160
161 | tc13-64B-4t4c-eth-l2bdbasemaclrn-ndrdisc
162 | | [Documentation]
163 | | ... | [Cfg] DUT runs L2BD switching config with with\
164 | | ... | 4 phy cores, 2 receive queues per NIC port.
165 | | ... | [Ver] Find NDR for 64 Byte frames using binary search start at\
166 | | ... | 18.75Mpps rate, step 50kpps.
167 | | [Tags] | 64B | 4C | NDRDISC
168 | | [Template] | L2 Bridge Domain Binary Search
169 | | framesize=${64}  | phy_cores=${4}
170 | | ... | s_limit=${s_18.75Mpps} | search_type=NDR
171
172 | tc15-1518B-4t4c-eth-l2bdbasemaclrn-ndrdisc
173 | | [Documentation]
174 | | ... | [Cfg] DUT runs L2BD switching config with with\
175 | | ... | 4 phy cores, 2 receive queues per NIC port.
176 | | ... | [Ver] Find NDR for 1518 Byte frames using binary search start at\
177 | | ... | 24.5G rate, step 50kpps.
178 | | [Tags] | 1518B | 4C | NDRDISC | SKIP_PATCH
179 | | [Template] | L2 Bridge Domain Binary Search BW limit
180 | | framesize=${1518}  | phy_cores=${4}
181 | | ... | s_limit=${s_24.5G} | search_type=NDR
182
183 | tc19-IMIX-1t1c-eth-l2bdbasemaclrn-ndrdisc
184 | | [Documentation]
185 | | ... | [Cfg] DUT runs L2BD switching config with with\
186 | | ... | 1 phy core, 1 receive queue per NIC port.
187 | | ... | [Ver] Find NDR for IMIX_v4_1 frames using binary search start at\
188 | | ... | 24.5G rate, step 50kpps.
189 | | [Tags] | IMIX | 1C | NDRDISC
190 | | [Template] | L2 Bridge Domain Binary Search BW limit
191 | | framesize=IMIX_v4_1  | phy_cores=${1}
192 | | ... | s_limit=${s_24.5G} | search_type=NDR
193
194 | tc20-IMIX-2t2c-eth-l2bdbasemaclrn-ndrdisc
195 | | [Documentation]
196 | | ... | [Cfg] DUT runs L2BD switching config with with\
197 | | ... | 2 phy cores, 1 receive queue per NIC port.
198 | | ... | [Ver] Find NDR for IMIX_v4_1 frames using binary search start at\
199 | | ... | 24.5G rate, step 50kpps.
200 | | [Tags] | IMIX | 2C | NDRDISC | SKIP_PATCH
201 | | [Template] | L2 Bridge Domain Binary Search BW limit
202 | | framesize=IMIX_v4_1  | phy_cores=${2}
203 | | ... | s_limit=${s_24.5G} | search_type=NDR
204
205 | tc21-IMIX-4t4c-eth-l2bdbasemaclrn-ndrdisc
206 | | [Documentation]
207 | | ... | [Cfg] DUT runs L2BD switching config with with\
208 | | ... | 4 phy cores, 2 receive queues per NIC port.
209 | | ... | [Ver] Find NDR for IMIX_v4_1 frames using binary search start at\
210 | | ... | 24.5G rate, step 50kpps.
211 | | [Tags] | IMIX | 4C | NDRDISC | SKIP_PATCH
212 | | [Template] | L2 Bridge Domain Binary Search BW limit
213 | | framesize=IMIX_v4_1  | phy_cores=${4}
214 | | ... | s_limit=${s_24.5G} | search_type=NDR
215