From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 875E1A0032; Fri, 22 Apr 2022 10:34:51 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 83154410EF; Fri, 22 Apr 2022 10:34:51 +0200 (CEST) Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by mails.dpdk.org (Postfix) with ESMTP id C06E840042 for ; Fri, 22 Apr 2022 10:34:49 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1650616490; x=1682152490; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=lZ27I6Sjfsnboy9V06a3ultFOf9rapx2CUYz/eYxIDk=; b=M2cI6ZmW/eZtwJPvOWAONLExoEeUG8JWgK5KgSakBzRWpybY5iRtXhzN haSAr82eT1FXXPClOlHVN/pLCsU1Hbg59cyG9hyS0FFrAIVWExbzxdGFb HWNiOSdm6DYru0gTiSoqgZ/D2wZFkNwj8PDLMgsYLHuIsXx2Hqj5QBYpb cK73tcIk7hS67zPXPyT9zEW3AaBYhRm7YKfA2IK+iavWniEe0aCsn2LMI YReox50L3HVCTN+/EWknec50+z1eC12PU1YX89yX0ewNKOUN8fBwbdWdy ysEyccQZgF6N1Xjz6B10HM85A5ITyVwifqvG5ykhRrK9qyw4Auvl8axJW w==; X-IronPort-AV: E=McAfee;i="6400,9594,10324"; a="244546106" X-IronPort-AV: E=Sophos;i="5.90,281,1643702400"; d="scan'208";a="244546106" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Apr 2022 01:34:32 -0700 X-IronPort-AV: E=Sophos;i="5.90,281,1643702400"; d="scan'208";a="577763192" Received: from unknown (HELO localhost.localdomain) ([10.239.251.222]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Apr 2022 01:34:31 -0700 From: Wei Ling To: dts@dpdk.org Cc: Wei Ling Subject: [dts][PATCH V1 1/3] test_plans/vswitch_pvp_multi_paths_performance_with_cbdma_test_plan: add new vswitch_pvp_multi_paths_performance_with_cbdma_test_plan Date: Fri, 22 Apr 2022 16:34:26 +0800 Message-Id: <20220422083426.1561349-1-weix.ling@intel.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org As commit 53d3f4778c(vhost: integrate dmadev in asynchronous data-path), add new testsuite vswitch_pvp_multi_paths_performance_with_cbdma for coverage the dpdk-vhost pvp multi paths performance test with cbdma. 1) Add new testplan test_plans/vswitch_pvp_multi_paths_performance_with_cbdma_test_plan. Signed-off-by: Wei Ling --- ...paths_performance_with_cbdma_test_plan.rst | 395 ++++++++++++++++++ 1 file changed, 395 insertions(+) create mode 100644 test_plans/vswitch_pvp_multi_paths_performance_with_cbdma_test_plan.rst diff --git a/test_plans/vswitch_pvp_multi_paths_performance_with_cbdma_test_plan.rst b/test_plans/vswitch_pvp_multi_paths_performance_with_cbdma_test_plan.rst new file mode 100644 index 00000000..ae4aba7b --- /dev/null +++ b/test_plans/vswitch_pvp_multi_paths_performance_with_cbdma_test_plan.rst @@ -0,0 +1,395 @@ +.. Copyright (c) <2022>, Intel Corporation + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + - Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + - Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. + + - Neither the name of Intel Corporation nor the names of its + contributors may be used to endorse or promote products derived + from this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED + OF THE POSSIBILITY OF SUCH DAMAGE. + +======================================================== +Vswitch PVP multi-paths performance with CBDMA test plan +======================================================== + +Description +=========== + +Benchmark PVP multi-paths performance with CBDMA in vhost sample, +include 10 tx/rx paths: inorder mergeable, inorder non-mergeable, +mergeable, non-mergeable, vectorized_rx, virtio 1.1 inorder mergeable, +virtio 1.1 inorder non-mergeable, virtio 1.1 mergeable, virtio 1.1 non-mergeable, +virtio1.1 vectorized path. Give 1 core for vhost and virtio respectively. +About vswitch sample, a new option --total-num-mbufs is added from dpdk-22.03, +for the user to set larger mbuf pool to avoid launch fail. For example, dpdk-vhost +will fail to launch with a 40G i40e port without setting larger mbuf pool. +For more about vhost switch sample, please refer to the dpdk docs: +http://doc.dpdk.org/guides/sample_app_ug/vhost.html +For virtio-user vdev parameter, you can refer to the dpdk doc: +https://doc.dpdk.org/guides/nics/virtio.html#virtio-paths-selection-and-usage + +Prerequisites +============= + +Topology +-------- + +Test flow: TG-->nic-->vswitch-->virtio-user-->vswitch-->nic-->TG + +Hardware +-------- +Supportted NICs: all except columbiaville that not support VMDQ + +Software +-------- +Trex:http://trex-tgn.cisco.com/trex/release/v2.26.tar.gz + +General set up +-------------- +1. Compile DPDK and vhost example:: + + # meson + # meson configure -Dexamples=vhost + # ninja -C -j 110 + +2. Get the pci device id and DMA device id of DUT. + +For example, 0000:18:00.0 is pci device id, 0000:00:04.0 is DMA device id:: + + # ./usertools/dpdk-devbind.py -s + + Network devices using kernel driver + =================================== + 0000:18:00.0 'Device 159b' if=ens785f0 drv=ice unused=vfio-pci + + DMA devices using kernel driver + =============================== + 0000:00:04.0 'Sky Lake-E CBDMA Registers 2021' drv=ioatdma unused=vfio-pci + +Test case +========= + +Common steps +------------ +1. Bind one physical port and one CBDMA port to vfio-pci:: + + # ./usertools/dpdk-devbind.py -b vfio-pci + # ./usertools/dpdk-devbind.py -b vfio-pci + + For example:: + ./usertools/dpdk-devbind.py -b vfio-pci 0000:00:18.0 + ./usertools/dpdk-devbind.py -b vfio-pci 0000:00:04.0 + +2. Inject different size of packets to NIC by traffic generator:: + + The packet size include [64, 128, 256, 512, 1024, 1518], and the format of packet is as follows. + +-------------+-------------+-------------+-------------+ + | MAC | MAC | IPV4 | IPV4 | + | Src address | Dst address | Src address | Dst address | + |-------------|-------------|-------------|-------------| + | Random MAC | Virtio mac | Random IP | Random IP | + +-------------+-------------+-------------+-------------+ + All the packets in this test plan use the Virtio mac:00:11:22:33:44:10. + +Test Case 1: Vswitch PVP split ring inorder mergeable path performance with CBDMA +--------------------------------------------------------------------------------- +This case uses Vswitch and Traffic generator(For example, Trex) to test performance of split ring inorder mergeable path with CBDMA. + +1. Bind one physical port and one CBDMA port to vfio-pci as common step 1. + +2. Launch dpdk-vhost by below command:: + + #.//examples/dpdk-vhost -l 2-3 -n 4 -a 0000:18:00.0 -a 0000:00:04.0 \ + -- -p 0x1 --mergeable 1 --vm2vm 1 --stats 1 --socket-file /tmp/vhost-net --dmas [txd0@0000:00:04.0] --total-num-mbufs 600000 + +3. Launch virtio-user with split ring inorder mergeable path:: + + #.//app/dpdk-testpmd -l 5-6 -n 4 --no-pci --file-prefix=testpmd0 \ + --vdev=net_virtio_user0,mac=00:11:22:33:44:10,path=/tmp/vhost-net,queues=1,packed_vq=0,mrg_rxbuf=1,in_order=1 \ + -- -i --rxq=1 --txq=1 --txd=1024 --rxd=1024 --nb-cores=1 + +4. Send packets from virtio-user to let vswitch know the mac addr:: + + testpmd> set fwd mac + testpmd> start tx_first + testpmd> stop + testpmd> start + +5. Send packets by traffic generator as common step 2, and check the throughput with below command:: + + testpmd> show port stats all + +Test Case 2: Vswitch PVP split ring inorder non-mergeable path performance with CBDMA +------------------------------------------------------------------------------------- +This case uses Vswitch and Traffic generator(For example, Trex) to test performance of split ring inorder non-mergeable path with CBDMA. + +1. Bind one physical port and one CBDMA port to vfio-pci as common step 1. + +2. Launch dpdk-vhost by below command:: + + #.//examples/dpdk-vhost -l 2-3 -n 4 -a 0000:18:00.0 -a 0000:00:04.0 \ + -- -p 0x1 --mergeable 1 --vm2vm 1 --stats 1 --socket-file /tmp/vhost-net --dmas [txd0@0000:00:04.0] --total-num-mbufs 600000 + +3. Launch virtio-user with split ring non-mergeable path:: + + #.//app/dpdk-testpmd -l 5-6 -n 4 --no-pci --file-prefix=testpmd0 \ + --vdev=net_virtio_user0,mac=00:11:22:33:44:10,path=/tmp/vhost-net,queues=1,packed_vq=0,mrg_rxbuf=0,in_order=1 \ + -- -i --rxq=1 --txq=1 --txd=1024 --rxd=1024 --nb-cores=1 + +4. Send packets from virtio-user to let vswitch know the mac addr:: + + testpmd> set fwd mac + testpmd> start tx_first + testpmd> stop + testpmd> start + +5. Send packets by traffic generator as common step 2, and check the throughput with below command:: + + testpmd> show port stats all + +Test Case 3: Vswitch PVP split ring mergeable path performance with CBDMA +------------------------------------------------------------------------- +This case uses Vswitch and Traffic generator(For example, Trex) to test performance of split ring mergeable path with CBDMA. + +1. Bind one physical port and one CBDMA port to vfio-pci as common step 1. + +2. Launch dpdk-vhost by below command:: + + #.//examples/dpdk-vhost -l 2-3 -n 4 -a 0000:18:00.0 -a 0000:00:04.0 \ + -- -p 0x1 --mergeable 1 --vm2vm 1 --stats 1 --socket-file /tmp/vhost-net --dmas [txd0@0000:00:04.0] --total-num-mbufs 600000 + +3. Launch virtio-user with split ring mergeable path:: + + #.//app/dpdk-testpmd -l 5-6 -n 4 --no-pci --file-prefix=testpmd0 \ + --vdev=net_virtio_user0,mac=00:11:22:33:44:10,path=/tmp/vhost-net,queues=1,packed_vq=0,mrg_rxbuf=1,in_order=0 \ + -- -i --rxq=1 --txq=1 --txd=1024 --rxd=1024 --nb-cores=1 + +4. Send packets from virtio-user to let vswitch know the mac addr:: + + testpmd> set fwd mac + testpmd> start tx_first + testpmd> stop + testpmd> start + +5. Send packets by traffic generator as common step 2, and check the throughput with below command:: + + testpmd> show port stats all + +Test Case 4: Vswitch PVP split ring non-mergeable path performance with CBDMA +----------------------------------------------------------------------------- +This case uses Vswitch and Traffic generator(For example, Trex) to test performance of split ring non-mergeable path with CBDMA. + +1. Bind one physical port and one CBDMA port to vfio-pci as common step 1. + +2. Launch dpdk-vhost by below command:: + + #.//examples/dpdk-vhost -l 2-3 -n 4 -a 0000:18:00.0 -a 0000:00:04.0 \ + -- -p 0x1 --mergeable 1 --vm2vm 1 --stats 1 --socket-file /tmp/vhost-net --dmas [txd0@0000:00:04.0] --total-num-mbufs 600000 + +3. Launch virtio-user with split ring non-mergeable path:: + + #.//app/dpdk-testpmd -l 5-6 -n 4 --no-pci --file-prefix=testpmd0 \ + --vdev=net_virtio_user0,mac=00:11:22:33:44:10,path=/tmp/vhost-net,queues=1,packed_vq=0,mrg_rxbuf=0,in_order=0 \ + -- -i --enable-hw-vlan-strip --rxq=1 --txq=1 --txd=1024 --rxd=1024 --nb-cores=1 + +4. Send packets from virtio-user to let vswitch know the mac addr:: + + testpmd> set fwd mac + testpmd> start tx_first + testpmd> stop + testpmd> start + +5. Send packets by traffic generator as common step 2, and check the throughput with below command:: + + testpmd> show port stats all + +Test Case 5: Vswitch PVP split ring vectorized path performance with CBDMA +-------------------------------------------------------------------------- +This case uses Vswitch and Traffic generator(For example, Trex) to test performance of split ring vectorized path with CBDMA. + +1. Bind one physical port and one CBDMA port to vfio-pci as common step 1. + +2. Launch dpdk-vhost by below command:: + + #.//examples/dpdk-vhost -l 2-3 -n 4 -a 0000:18:00.0 -a 0000:00:04.0 \ + -- -p 0x1 --mergeable 1 --vm2vm 1 --stats 1 --socket-file /tmp/vhost-net --dmas [txd0@0000:00:04.0] --total-num-mbufs 600000 + +3. Launch virtio-user with split ring vectorized path:: + + #.//app/dpdk-testpmd -l 5-6 -n 4 --no-pci --file-prefix=testpmd0 \ + --vdev=net_virtio_user0,mac=00:11:22:33:44:10,path=/tmp/vhost-net,queues=1,packed_vq=0,mrg_rxbuf=0,in_order=1,vectorized=1 \ + -- -i --rxq=1 --txq=1 --txd=1024 --rxd=1024 --nb-cores=1 + +4. Send packets from virtio-user to let vswitch know the mac addr:: + + testpmd> set fwd mac + testpmd> start tx_first + testpmd> stop + testpmd> start + +5. Send packets by traffic generator as common step 2, and check the throughput with below command:: + + testpmd> show port stats all + + +Test Case 6: Vswitch PVP packed ring inorder mergeable path performance with CBDMA +---------------------------------------------------------------------------------- +This case uses Vswitch and Traffic generator(For example, Trex) to test performance of packed ring inorder mergeable path with CBDMA. + +1. Bind one physical port and one CBDMA port to vfio-pci as common step 1. + +2. Launch dpdk-vhost by below command:: + + #.//examples/dpdk-vhost -l 2-3 -n 4 -a 0000:18:00.0 -a 0000:00:04.0 \ + -- -p 0x1 --mergeable 1 --vm2vm 1 --stats 1 --socket-file /tmp/vhost-net --dmas [txd0@0000:00:04.0] --total-num-mbufs 600000 + +3. Launch virtio-user with packed ring inorder mergeable path:: + + #.//app/dpdk-testpmd -l 5-6 -n 4 --no-pci --file-prefix=testpmd0 \ + --vdev=net_virtio_user0,mac=00:11:22:33:44:10,path=/tmp/vhost-net,queues=1,packed_vq=1,mrg_rxbuf=1,in_order=1 \ + -- -i --rxq=1 --txq=1 --txd=1024 --rxd=1024 --nb-cores=1 + +4. Send packets from virtio-user to let vswitch know the mac addr:: + + testpmd> set fwd mac + testpmd> start tx_first + testpmd> stop + testpmd> start + +5. Send packets by traffic generator as common step 2, and check the throughput with below command:: + + testpmd> show port stats all + +Test Case 7: Vswitch PVP packed ring inorder non-mergeable path performance with CBDMA +-------------------------------------------------------------------------------------- +This case uses Vswitch and Traffic generator(For example, Trex) to test performance of packed ring inorder non-mergeable path with CBDMA. + +1. Bind one physical port and one CBDMA port to vfio-pci as common step 1. + +2. Launch dpdk-vhost by below command:: + + #.//examples/dpdk-vhost -l 2-3 -n 4 -a 0000:18:00.0 -a 0000:00:04.0 \ + -- -p 0x1 --mergeable 1 --vm2vm 1 --stats 1 --socket-file /tmp/vhost-net --dmas [txd0@0000:00:04.0] --total-num-mbufs 600000 + +3. Launch virtio-user with packed ring inorder non-mergeable path:: + + #.//app/dpdk-testpmd -l 5-6 -n 4 --no-pci --file-prefix=testpmd0 \ + --vdev=net_virtio_user0,mac=00:11:22:33:44:10,path=/tmp/vhost-net,queues=1,packed_vq=1,mrg_rxbuf=0,in_order=1 \ + -- -i --rxq=1 --txq=1 --txd=1024 --rxd=1024 --nb-cores=1 + +4. Send packets from virtio-user to let vswitch know the mac addr:: + + testpmd> set fwd mac + testpmd> start tx_first + testpmd> stop + testpmd> start + +5. Send packets by traffic generator as common step 2, and check the throughput with below command:: + + testpmd> show port stats all + +Test Case 8: Vswitch PVP packed ring mergeable path performance with CBDMA +-------------------------------------------------------------------------- +This case uses Vswitch and Traffic generator(For example, Trex) to test performance of packed ring mergeable path with CBDMA. + +1. Bind one physical port and one CBDMA port to vfio-pci as common step 1. + +2. Launch dpdk-vhost by below command:: + + #.//examples/dpdk-vhost -l 2-3 -n 4 -a 0000:18:00.0 -a 0000:00:04.0 \ + -- -p 0x1 --mergeable 1 --vm2vm 1 --stats 1 --socket-file /tmp/vhost-net --dmas [txd0@0000:00:04.0] --total-num-mbufs 600000 + +3. Launch virtio-user with packed ring mergeable path:: + + #.//app/dpdk-testpmd -l 5-6 -n 4 --no-pci --file-prefix=testpmd0 \ + --vdev=net_virtio_user0,mac=00:11:22:33:44:10,path=/tmp/vhost-net,queues=1,packed_vq=1,mrg_rxbuf=1,in_order=0 \ + -- -i --rxq=1 --txq=1 --txd=1024 --rxd=1024 --nb-cores=1 + +4. Send packets from virtio-user to let vswitch know the mac addr:: + + testpmd> set fwd mac + testpmd> start tx_first + testpmd> stop + testpmd> start + +5. Send packets by traffic generator as common step 2, and check the throughput with below command:: + + testpmd> show port stats all + +Test Case 9: Vswitch PVP packed ring non-mergeable path performance with CBDMA +------------------------------------------------------------------------------ +This case uses Vswitch and Traffic generator(For example, Trex) to test performance of packed ring non-mergeable path with CBDMA. + +1. Bind one physical port and one CBDMA port to vfio-pci as common step 1. + +2. Launch dpdk-vhost by below command:: + + #.//examples/dpdk-vhost -l 2-3 -n 4 -a 0000:18:00.0 -a 0000:00:04.0 \ + -- -p 0x1 --mergeable 1 --vm2vm 1 --stats 1 --socket-file /tmp/vhost-net --dmas [txd0@0000:00:04.0] --total-num-mbufs 600000 + +3. Launch virtio-user with packed ring non-mergeable path:: + + #.//app/dpdk-testpmd -l 5-6 -n 4 --no-pci --file-prefix=testpmd0 \ + --vdev=net_virtio_user0,mac=00:11:22:33:44:10,path=/tmp/vhost-net,queues=1,packed_vq=1,mrg_rxbuf=0,in_order=0 \ + -- -i --rxq=1 --txq=1 --txd=1024 --rxd=1024 --nb-cores=1 + +4. Send packets from virtio-user to let vswitch know the mac addr:: + + testpmd> set fwd mac + testpmd> start tx_first + testpmd> stop + testpmd> start + +5. Send packets by traffic generator as common step 2, and check the throughput with below command:: + + testpmd> show port stats all + +Test Case 10: Vswitch PVP packed ring vectorized path performance with CBDMA +---------------------------------------------------------------------------- +This case uses Vswitch and Traffic generator(For example, Trex) to test performance of packed ring vectorized path with CBDMA. + +1. Bind one physical port and one CBDMA port to vfio-pci as common step 1. + +2. Launch dpdk-vhost by below command:: + + #.//examples/dpdk-vhost -l 2-3 -n 4 -a 0000:18:00.0 -a 0000:00:04.0 \ + -- -p 0x1 --mergeable 1 --vm2vm 1 --stats 1 --socket-file /tmp/vhost-net --dmas [txd0@0000:00:04.0] --total-num-mbufs 600000 + +3. Launch virtio-user with packed ring vectorized path:: + + #.//app/dpdk-testpmd -l 5-6 -n 4 --no-pci --file-prefix=testpmd0 --force-max-simd-bitwidth=512 \ + --vdev=net_virtio_user0,mac=00:11:22:33:44:10,path=/tmp/vhost-net,queues=1,packed_vq=1,mrg_rxbuf=0,in_order=1,vectorized=1 \ + -- -i --rxq=1 --txq=1 --txd=1024 --rxd=1024 --nb-cores=1 + +4. Send packets from virtio-user to let vswitch know the mac addr:: + + testpmd> set fwd mac + testpmd> start tx_first + testpmd> stop + testpmd> start + +5. Send packets by traffic generator as common step 2, and check the throughput with below command:: + + testpmd> show port stats all -- 2.25.1