From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 3AB0AA09EF; Mon, 21 Dec 2020 16:51:12 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id BBE93CAAE; Mon, 21 Dec 2020 16:51:10 +0100 (CET) Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by dpdk.org (Postfix) with ESMTP id 22872C9C0 for ; Mon, 21 Dec 2020 16:51:08 +0100 (CET) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 8ADFF1FB; Mon, 21 Dec 2020 07:51:06 -0800 (PST) Received: from net-arm-thunderx2-03.shanghai.arm.com (net-arm-thunderx2-03.shanghai.arm.com [10.169.208.206]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 650B43F6CF; Mon, 21 Dec 2020 07:51:04 -0800 (PST) From: Joyce Kong To: maxime.coquelin@redhat.com, chenbo.xia@intel.com, honnappa.nagarahalli@arm.com, ruifeng.wang@arm.com Cc: dev@dpdk.org, nd@arm.com Date: Mon, 21 Dec 2020 23:50:25 +0800 Message-Id: <20201221155033.6771-1-joyce.kong@arm.com> X-Mailer: git-send-email 2.29.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH v1 0/8] replace smp barriers in vhost with C11 atomic X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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 patchset is to replace rte smp barriers in vhost with C11 atomic built-ins. The rte_smp_*mb APIs provide full barrier functionality. However, many use cases do not require full barriers. To support such use cases, DPDK will adopt C11 barrier semantics and provide wrappers using C11 atomic built-ins.[1] With this patchset, PVP case(vhost-user + virtio-user) has 9.8% perf uplift for the split in_order path and no perf degradation for the packed in_order path under 0.001% acceptable loss on ThunderX2 platform. [1] http://code.dpdk.org/dpdk/latest/source/doc/guides/rel_notes/deprecation.rst Joyce Kong (8): examples/vhost: relax memory ordering when enqueue/dequeue examples/vhost_blk: replace smp with thread fence vhost: remove unnecessary smp barrier for desc flags vhost: remove unnecessary smp barrier for avail idx vhost: relax full barriers for desc flags vhost: relax full barriers for used idx vhost: replace smp with thread fence for packed vring vhost: replace smp with thread fence for control path examples/vhost/virtio_net.c | 12 ++++-------- examples/vhost_blk/vhost_blk.c | 8 ++++---- lib/librte_vhost/vdpa.c | 4 ++-- lib/librte_vhost/vhost.c | 18 +++++++++--------- lib/librte_vhost/vhost.h | 6 +++--- lib/librte_vhost/vhost_user.c | 2 +- lib/librte_vhost/virtio_net.c | 26 +++++++++++--------------- 7 files changed, 34 insertions(+), 42 deletions(-) -- 2.29.2