From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wi0-f179.google.com (mail-wi0-f179.google.com [209.85.212.179]) by dpdk.org (Postfix) with ESMTP id 10CE4C3A4 for ; Fri, 10 Jul 2015 16:34:35 +0200 (CEST) Received: by wifm2 with SMTP id m2so48253863wif.1 for ; Fri, 10 Jul 2015 07:34:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:organization :user-agent:in-reply-to:references:mime-version :content-transfer-encoding:content-type; bh=yOoGhI8/8MK/D61iaHDHiCuqM2xpjOIJm1f/YlnDKxI=; b=B/PnkRKzFrASNF4FBHSmWEBP+NQ1O+dtlHLS1ozfXtXw0NE/ioy97Qoo03tZ9KwoZd xwIEbUxI+d1Dh05E9AHC5MuHtWp/s7NMPdHkz7712aVBQdoKPk+9PT9rmeWLPOkeEbY7 jnvjmC2uVZNo7Fvg3rasf1uXKW7ApxS5AmbNSLdlKIJy6jR/IocWZSQuby4pHfkTBFNM 72Ihgf5uUEJ54N2fYHhyA5a55WM+eZVE26ozxiO48u255v3ltLZPKEwW1VO9LaW1+lyQ chQPhSPGocnMdUisHgmqx3arraU1aM9FGb5vxHkDB9YnpwNi3/CH5UUiCLLFqk0wq69Z ajyw== X-Gm-Message-State: ALoCoQmtV4KPCaiykq5FDYKkTsw9pE282vkQhuxjJqk/jod0VYPIcVC9nm4Q20HyZ1aBQReJIH9g X-Received: by 10.180.86.234 with SMTP id s10mr6779292wiz.50.1436538874927; Fri, 10 Jul 2015 07:34:34 -0700 (PDT) Received: from xps13.localnet (136-92-190-109.dsl.ovh.fr. [109.190.92.136]) by smtp.gmail.com with ESMTPSA id ha4sm3243152wib.0.2015.07.10.07.34.33 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 10 Jul 2015 07:34:34 -0700 (PDT) From: Thomas Monjalon To: Helin Zhang Date: Fri, 10 Jul 2015 16:33:19 +0200 Message-ID: <2993772.ZMHUuAIlz7@xps13> Organization: 6WIND User-Agent: KMail/4.14.8 (Linux/4.0.4-2-ARCH; KDE/4.14.8; x86_64; ; ) In-Reply-To: <1433974765-136411-1-git-send-email-damarion@cisco.com> References: <1433974765-136411-1-git-send-email-damarion@cisco.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Cc: dev@dpdk.org, Damjan Marion Subject: Re: [dpdk-dev] [PATCH] i40e: prefetch next mbuf in rx alloc code X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jul 2015 14:34:35 -0000 Helin, a comment? 2015-06-11 00:19, Damjan Marion: > This patch improves performance of vectored rx on i40e devices. > > Signed-off-by: Damjan Marion > --- > drivers/net/i40e/i40e_rxtx.c | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/drivers/net/i40e/i40e_rxtx.c b/drivers/net/i40e/i40e_rxtx.c > index 2de0ac4..152e9e6 100644 > --- a/drivers/net/i40e/i40e_rxtx.c > +++ b/drivers/net/i40e/i40e_rxtx.c > @@ -778,6 +778,11 @@ i40e_rx_alloc_bufs(struct i40e_rx_queue *rxq) > > rxdp = &rxq->rx_ring[alloc_idx]; > for (i = 0; i < rxq->rx_free_thresh; i++) { > + > + /* Prefetch next mbuf */ > + if (i < (rxq->rx_free_thresh - 1)) > + rte_prefetch0 (rxep[i+1].mbuf); > + > mb = rxep[i].mbuf; > rte_mbuf_refcnt_set(mb, 1); > mb->next = NULL; >