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 48826A0613 for ; Fri, 30 Aug 2019 18:07:59 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 46E181E96A; Fri, 30 Aug 2019 18:07:58 +0200 (CEST) Received: from mail-qt1-f194.google.com (mail-qt1-f194.google.com [209.85.160.194]) by dpdk.org (Postfix) with ESMTP id BCC991E968 for ; Fri, 30 Aug 2019 18:07:57 +0200 (CEST) Received: by mail-qt1-f194.google.com with SMTP id b2so4660333qtq.5 for ; Fri, 30 Aug 2019 09:07:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=A9TobIoXvep4CUr5LLAMV+bAP2Q9QvTC00HccA7cMlY=; b=q6zF+3gil8M6TSRv72beS8M+8EiDtEuKQaKHPFqAQEU0zfiFV5k8dLEE5Ebas6Y7lz wvhOIjH5XUQ4kN1/frfZZUSMXhG003h5hnYHuiIjMIWRDASqR4Vzb+MpT+6cIbdBOUK5 RtUvd/C4wKz6SGBhXIDUorv7AqVEaoofZfxONk+oBYmKLrYO+9AiPZUMAfR/e5zwR4xN nXKBVdAjeG0WEoYCfJ3hKim6wGT2kUdR3kHf8Ob7gS108TcOvqF5dd+/mojXw32RnKep mzVvVPEKx0C0XtYv7/wFqmDRq5oWUZhFtD1Z2k8/8CcIDCfTWksDILPFUSaI6EJmkcOf y+mg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=A9TobIoXvep4CUr5LLAMV+bAP2Q9QvTC00HccA7cMlY=; b=NHT5XPXkJohF1zgj6pSDzpPq8akRz1k4X/RxC7+eCgwnMfQTnqPbAxan3GD2nvDJt/ hIBpKZDJSDaet7zHgnC0TDC2OGnSSoqRtTDPSEZ3b9EFVtAJ558M2QO224gCq9Bg4s32 vB+uUx68ZMTd/QTEEBZqafV2O+bdbhpwX3UcW+e9C+irWPzaKcuocZ3+E9q+x8CgKWGb DxLbRnTVFVuYMQvd6S09hE2veNkWisWTgmlXgCIJMHrmasjDwcP74ZHlRyBsZjtLwB0O C+hrWn26zNGnbCgXF/7egIIxspJY/zODwQAT5IVmFkwFDVu8VkrGLZhMWhN75qMKCQqS 5urw== X-Gm-Message-State: APjAAAX1pBU/sDgn8yvWKWHdkjwSD4gxkcFrmlNRri9S5VQSKhZ2G5tr NvP7pnCpM8Mw0Yw2uMtwaBldvjxNaD5yTwtoQLU= X-Google-Smtp-Source: APXvYqzS9pURZaeTQtakC+4wase849QQmTQba45BTG+9VdRzFX8fJoGtArX47lrOfDuXIFI8OO13c7IRuib52TXEwAk= X-Received: by 2002:ac8:3332:: with SMTP id t47mr16310585qta.35.1567181277045; Fri, 30 Aug 2019 09:07:57 -0700 (PDT) MIME-Version: 1.0 References: <20190829150259.22206-1-ciara.loftus@intel.com> In-Reply-To: <20190829150259.22206-1-ciara.loftus@intel.com> From: William Tu Date: Fri, 30 Aug 2019 09:07:20 -0700 Message-ID: To: Ciara Loftus Cc: dev@dpdk.org, Xiaolong Ye , bruce.richardson@intel.com, Kevin Laatz Content-Type: text/plain; charset="UTF-8" Subject: Re: [dpdk-dev] [PATCH] net/af_xdp: enable support for unaligned umem chunks 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" Hi Ciara, I haven't tried this patch but have a question. On Thu, Aug 29, 2019 at 8:04 AM Ciara Loftus wrote: > > This patch enables the unaligned chunks feature for AF_XDP which allows > chunks to be placed at arbitrary places in the umem, as opposed to them > being required to be aligned to 2k. This allows for DPDK application > mempools to be mapped directly into the umem and in turn enable zero copy > transfer between umem and the PMD. > > This patch replaces the zero copy via external mbuf mechanism introduced > in commit e9ff8bb71943 ("net/af_xdp: enable zero copy by external mbuf"). > The pmd_zero copy vdev argument is also removed as now the PMD will > auto-detect presence of the unaligned chunks feature and enable it if so > and otherwise fall back to copy mode if not detected. > > When enabled, this feature significantly improves single-core performance > of the PMD. Why using unaligned chunk feature improve performance? Existing external mbuf already has zero copy between umem and PMD, and your patch also does the same thing. So the improvement is from somewhere else? Thank you William > > Signed-off-by: Ciara Loftus > Signed-off-by: Kevin Laatz > --- > doc/guides/nics/af_xdp.rst | 1 - > doc/guides/rel_notes/release_19_11.rst | 9 + > drivers/net/af_xdp/rte_eth_af_xdp.c | 304 ++++++++++++++++++------- > 3 files changed, 231 insertions(+), 83 deletions(-) >