From patchwork Fri Jun 18 20:03:01 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Ma, WenwuX" X-Patchwork-Id: 94394 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 1F681A0C46; Fri, 18 Jun 2021 10:10:03 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id CD535410F5; Fri, 18 Jun 2021 10:09:57 +0200 (CEST) Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by mails.dpdk.org (Postfix) with ESMTP id 574CD40142 for ; Fri, 18 Jun 2021 10:09:54 +0200 (CEST) IronPort-SDR: QIsqzm0B09aETmXaeWiTsMQyj5v+1R8FNfDPPhK/c9sWkx3UUpjOeM3SX6cAJby7kDx1HS5F/e zJUxep/Z2ATA== X-IronPort-AV: E=McAfee;i="6200,9189,10018"; a="206334381" X-IronPort-AV: E=Sophos;i="5.83,283,1616482800"; d="scan'208";a="206334381" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Jun 2021 01:09:49 -0700 IronPort-SDR: uLxp/UWXf+e5xuqUt6tJofkCX3gDHEXsf4Ybuc3tzYwy3Iiy7NTztrIjQSJVn4Gw+pcEp6K/N2 kZJBcjprk2FQ== X-IronPort-AV: E=Sophos;i="5.83,283,1616482800"; d="scan'208";a="451307783" Received: from unknown (HELO localhost.localdomain) ([10.240.183.109]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Jun 2021 01:09:47 -0700 From: Wenwu Ma To: dev@dpdk.org Cc: maxime.coquelin@redhat.com, chenbo.xia@intel.com, cheng1.jiang@intel.com, Wenwu Ma Date: Fri, 18 Jun 2021 20:03:01 +0000 Message-Id: <20210618200305.662515-1-wenwux.ma@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210602083110.5530-1-yuanx.wang@intel.com> References: <20210602083110.5530-1-yuanx.wang@intel.com> MIME-Version: 1.0 Subject: [dpdk-dev] [PATCH v2 0/4] vhost: support async dequeue for split ring X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" This patch implements asynchronous dequeue data path for split ring. A new asynchronous dequeue function is introduced. With this function, the application can try to receive packets from the guest with offloading large copies to the DMA engine, thus saving precious CPU cycles. v2: - Refactor vhost datapath as preliminary patch for this series. - The change of using new API in examples/vhost is put into a dedicated patch. - Check queue_id value before using it. - Async dequeue performance enhancement. 160% performance improvement for v2 vs. v1. - Async dequeue API name change from rte_vhost_try_dequeue_burst to rte_vhost_async_try_dequeue_burst. - The completed package updates the used ring directly. Wenwu Ma (3): examples/vhost: refactor vhost enqueue and dequeue datapaths. examples/vhost: use a new API to query remaining ring space examples/vhost: support vhost async dequeue data path Yuan Wang (1): vhost: support async dequeue for split ring doc/guides/prog_guide/vhost_lib.rst | 10 + doc/guides/sample_app_ug/vhost.rst | 9 +- examples/vhost/ioat.c | 40 +- examples/vhost/ioat.h | 4 + examples/vhost/main.c | 225 +++++++---- examples/vhost/main.h | 38 +- examples/vhost/virtio_net.c | 16 +- lib/vhost/rte_vhost_async.h | 44 ++- lib/vhost/version.map | 3 + lib/vhost/virtio_net.c | 553 ++++++++++++++++++++++++++++ 10 files changed, 839 insertions(+), 103 deletions(-)