feat(core): Adjust T-Rex for external topologies
[csit.git] / resources / libraries / robot / hoststack / hoststack.robot
index 1033c1c..ece1d8a 100644 (file)
@@ -31,7 +31,6 @@
 | ${quic_crypto_engine}= | nocrypto
 | ${quic_fifo_size}= | 4M
 | &{vpp_hoststack_attr}=
 | ${quic_crypto_engine}= | nocrypto
 | ${quic_fifo_size}= | 4M
 | &{vpp_hoststack_attr}=
-| ... | rxq=${1}
 | ... | rxd=${256}
 | ... | txd=${256}
 | ... | phy_cores=${1}
 | ... | rxd=${256}
 | ... | txd=${256}
 | ... | phy_cores=${1}
 | | ... | Set the VPP HostStack attributes in the vpp_hoststack_attr dictionary.
 | |
 | | ... | *Arguments:*
 | | ... | Set the VPP HostStack attributes in the vpp_hoststack_attr dictionary.
 | |
 | | ... | *Arguments:*
-| | ... | - ${rxq} - Number of Rx Queues Type: int
 | | ... | - ${rxd} - Number of Rx Descriptors Type: int
 | | ... | - ${txd} - Number of Tx Descriptors Type: int
 | | ... | - ${phy_cores} - Number of cores for workers Type: int
 | | ... | - ${rxd} - Number of Rx Descriptors Type: int
 | | ... | - ${txd} - Number of Tx Descriptors Type: int
 | | ... | - ${phy_cores} - Number of cores for workers Type: int
 | | ... | \| Set VPP Hoststack Attributes \| phy_cores=${phy_cores} \|
 | |
 | | [Arguments]
 | | ... | \| Set VPP Hoststack Attributes \| phy_cores=${phy_cores} \|
 | |
 | | [Arguments]
-| | ... | ${rxq}=${vpp_hoststack_attr}[rxq]
 | | ... | ${rxd}=${vpp_hoststack_attr}[rxd]
 | | ... | ${txd}=${vpp_hoststack_attr}[txd]
 | | ... | ${phy_cores}=${vpp_hoststack_attr}[phy_cores]
 | | ... | ${rxd}=${vpp_hoststack_attr}[rxd]
 | | ... | ${txd}=${vpp_hoststack_attr}[txd]
 | | ... | ${phy_cores}=${vpp_hoststack_attr}[phy_cores]
 | | ... | ${sess_lendpt_buckets}=${vpp_hoststack_attr}[sess_lendpt_buckets]
 | | ... | ${sess_lendpt_mem}=${vpp_hoststack_attr}[sess_lendpt_mem]
 | |
 | | ... | ${sess_lendpt_buckets}=${vpp_hoststack_attr}[sess_lendpt_buckets]
 | | ... | ${sess_lendpt_mem}=${vpp_hoststack_attr}[sess_lendpt_mem]
 | |
-| | Set To Dictionary | ${vpp_hoststack_attr} | rxq | ${rxq}
 | | Set To Dictionary | ${vpp_hoststack_attr} | rxd | ${rxd}
 | | Set To Dictionary | ${vpp_hoststack_attr} | txd | ${txd}
 | | Set To Dictionary | ${vpp_hoststack_attr} | phy_cores | ${phy_cores}
 | | Set To Dictionary | ${vpp_hoststack_attr} | rxd | ${rxd}
 | | Set To Dictionary | ${vpp_hoststack_attr} | txd | ${txd}
 | | Set To Dictionary | ${vpp_hoststack_attr} | phy_cores | ${phy_cores}
 | |
 | | Set Max Rate And Jumbo
 | | Add worker threads to all DUTs
 | |
 | | Set Max Rate And Jumbo
 | | Add worker threads to all DUTs
-| | ... | ${vpp_hoststack_attr}[phy_cores] | ${vpp_hoststack_attr}[rxq]
-| | ... | ${vpp_hoststack_attr}[rxd] | ${vpp_hoststack_attr}[txd]
+| | ... | ${vpp_hoststack_attr}[phy_cores]
+| | ... | rxd=${vpp_hoststack_attr}[rxd] | txd=${vpp_hoststack_attr}[txd]
 | | Pre-initialize layer driver | ${nic_driver}
 | | FOR | ${dut} | IN | @{duts}
 | | | Import Library | resources.libraries.python.VppConfigGenerator
 | | Pre-initialize layer driver | ${nic_driver}
 | | FOR | ${dut} | IN | @{duts}
 | | | Import Library | resources.libraries.python.VppConfigGenerator
 | | ${numa}= | Get interfaces numa node | ${dut2} | ${dut2_if1}
 | | ${core_list}= | Cpu list per node str | ${dut2} | ${numa}
 | | ... | skip_cnt=${skip_cnt} | cpu_cnt=${vpp_echo_server_attr}[cpu_cnt]
 | | ${numa}= | Get interfaces numa node | ${dut2} | ${dut2_if1}
 | | ${core_list}= | Cpu list per node str | ${dut2} | ${numa}
 | | ... | skip_cnt=${skip_cnt} | cpu_cnt=${vpp_echo_server_attr}[cpu_cnt]
+| | FOR | ${action} | IN | @{stat_pre_trial}
+| | | Run Keyword | Additional Statistics Action For ${action}
+| | END
 | | ${server_pid}= | Run hoststack test program on DUT
 | | ... | ${dut2} | ${dut2_if1} | ${dut2_if1_ip4_addr} | ${dut2_if1_ip4_prefix}
 | | ... | ${vpp_echo_server_attr}[namespace] | ${core_list}
 | | ${server_pid}= | Run hoststack test program on DUT
 | | ... | ${dut2} | ${dut2_if1} | ${dut2_if1_ip4_addr} | ${dut2_if1_ip4_prefix}
 | | ... | ${vpp_echo_server_attr}[namespace] | ${core_list}
 | | ${server_defer_fail} | ${server_output}=
 | | ... | Analyze hoststack test program output | ${dut2} | Server
 | | ... | ${vpp_nsim_attr} | ${vpp_echo_server}
 | | ${server_defer_fail} | ${server_output}=
 | | ... | Analyze hoststack test program output | ${dut2} | Server
 | | ... | ${vpp_nsim_attr} | ${vpp_echo_server}
+| | FOR | ${action} | IN | @{stat_post_trial}
+| | | Run Keyword | Additional Statistics Action For ${action}
+| | END
 | | Set test message | ${server_output} | append=True
 | | Run Keyword And Return | Hoststack Test Program Defer Fail
 | | ... | ${server_defer_fail} | ${client_defer_fail}
 | | Set test message | ${server_output} | append=True
 | | Run Keyword And Return | Hoststack Test Program Defer Fail
 | | ... | ${server_defer_fail} | ${client_defer_fail}
 | | ${numa}= | Get interfaces numa node | ${dut2} | ${dut2_if1}
 | | ${core_list}= | Cpu list per node str | ${dut2} | ${numa}
 | | ... | skip_cnt=${skip_cnt} | cpu_cnt=${iperf3_server_attr}[cpu_cnt]
 | | ${numa}= | Get interfaces numa node | ${dut2} | ${dut2_if1}
 | | ${core_list}= | Cpu list per node str | ${dut2} | ${numa}
 | | ... | skip_cnt=${skip_cnt} | cpu_cnt=${iperf3_server_attr}[cpu_cnt]
+| | FOR | ${action} | IN | @{stat_pre_trial}
+| | | Run Keyword | Additional Statistics Action For ${action}
+| | END
 | | ${server_pid}= | Run hoststack test program on DUT
 | | ... | ${dut2} | ${dut2_if1} | ${dut2_if1_ip4_addr} | ${dut2_if1_ip4_prefix}
 | | ... | ${iperf3_server_attr}[namespace] | ${core_list}
 | | ${server_pid}= | Run hoststack test program on DUT
 | | ... | ${dut2} | ${dut2_if1} | ${dut2_if1_ip4_addr} | ${dut2_if1_ip4_prefix}
 | | ... | ${iperf3_server_attr}[namespace] | ${core_list}
 | | ... | ${iperf3_client_attr}[cfg_vpp_feature] | ${iperf3_client}
 | | When Hoststack Test Program Finished | ${dut1} | ${client_pid}
 | | ... | ${iperf3_client} | ${dut2} | ${iperf3_server}
 | | ... | ${iperf3_client_attr}[cfg_vpp_feature] | ${iperf3_client}
 | | When Hoststack Test Program Finished | ${dut1} | ${client_pid}
 | | ... | ${iperf3_client} | ${dut2} | ${iperf3_server}
+| | FOR | ${action} | IN | @{stat_post_trial}
+| | | Run Keyword | Additional Statistics Action For ${action}
+| | END
 | | ${client_defer_fail} | ${client_output}=
 | | ... | Analyze hoststack test program output | ${dut1} | Client
 | | ... | ${vpp_nsim_attr} | ${iperf3_client}
 | | ${client_defer_fail} | ${client_output}=
 | | ... | Analyze hoststack test program output | ${dut1} | Client
 | | ... | ${vpp_nsim_attr} | ${iperf3_client}
 | |
 | | ${dut_ip_addrs_str} | Evaluate | ','.join(${dut_ip_addrs})
 | | ${ad_ip_addrs_str} | Evaluate | ','.join(${ab_ip_addrs})
 | |
 | | ${dut_ip_addrs_str} | Evaluate | ','.join(${dut_ip_addrs})
 | | ${ad_ip_addrs_str} | Evaluate | ','.join(${ab_ip_addrs})
+| | FOR | ${action} | IN | @{stat_pre_trial}
+| | | Run Keyword | Additional Statistics Action For ${action}
+| | END
 | | ${output}= | Run ab | ${tg} | ${dut_ip_addrs_str} | ${ad_ip_addrs_str}
 | | ... | ${tls_tcp} | ${ciphers} | ${files} | ${mode} | ${r_total} | ${c_total}
 | | ... | ${listen_port}
 | | ${output}= | Run ab | ${tg} | ${dut_ip_addrs_str} | ${ad_ip_addrs_str}
 | | ... | ${tls_tcp} | ${ciphers} | ${files} | ${mode} | ${r_total} | ${c_total}
 | | ... | ${listen_port}
+| | FOR | ${action} | IN | @{stat_post_trial}
+| | | Run Keyword | Additional Statistics Action For ${action}
+| | END
 | | Set test message | ${output}
 | | Set test message | ${output}
-| | Log VPP Hoststack data | ${dut1}
 
 | Configure VPP startup configuration for NGINX
 | | [Documentation]
 
 | Configure VPP startup configuration for NGINX
 | | [Documentation]
 | | | ... | ${dut}.Add DPDK Dev Default Tso
 | | | Run keyword If | '${nic_driver}' == 'vfio-pci'
 | | | ... | ${dut}.Add DPDK Enable Tcp Udp Checksum
 | | | ... | ${dut}.Add DPDK Dev Default Tso
 | | | Run keyword If | '${nic_driver}' == 'vfio-pci'
 | | | ... | ${dut}.Add DPDK Enable Tcp Udp Checksum
-| | | Run keyword | ${dut}.Add Api Trace
 | | END
 | | END