From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-CY1-obe.outbound.protection.outlook.com (mail-cys01nam02on0065.outbound.protection.outlook.com [104.47.37.65]) by dpdk.org (Postfix) with ESMTP id C704C4CE7 for ; Thu, 14 Jul 2016 19:28:11 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=harmonic.onmicrosoft.com; s=selector1-harmonicinc-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=tnvQD/CQsACHerH+hpQrZp09/1InU5SqiqjqBTsOPTM=; b=l+9qhVHEVfRBNyAooffQFKymdDX/wJIZfu1a9SMkRK2ZaT1BXyOE2N4XAbZXP5g3kl1LkkYdLfu8iMrxQxcsKNEX0fawyaK7Y/n9mjkK3XzS+gBUbr6u/w6eehTO8ljW0tDgYs+QDzkzpCeiEH7PCF6qS6iqtRewQE0LzpnVdR8= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Vladyslav.Buslov@harmonicinc.com; Received: from kms.harmonicinc.com (95.67.66.62) by MWHPR11MB1360.namprd11.prod.outlook.com (10.169.235.22) with Microsoft SMTP Server (TLS) id 15.1.528.16; Thu, 14 Jul 2016 17:28:09 +0000 From: Vladyslav Buslov To: , CC: Date: Thu, 14 Jul 2016 20:27:19 +0300 Message-ID: <20160714172719.17502-2-vladyslav.buslov@harmonicinc.com> X-Mailer: git-send-email 2.8.3 In-Reply-To: <20160714172719.17502-1-vladyslav.buslov@harmonicinc.com> References: <20160714172719.17502-1-vladyslav.buslov@harmonicinc.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [95.67.66.62] X-ClientProxiedBy: CY1PR1101CA0041.namprd11.prod.outlook.com (10.169.17.51) To MWHPR11MB1360.namprd11.prod.outlook.com (10.169.235.22) X-MS-Office365-Filtering-Correlation-Id: 48bd49d8-d405-4536-b5c4-08d3ac0c3a25 X-Microsoft-Exchange-Diagnostics: 1; MWHPR11MB1360; 2:JYv79uFqVexxzAuwZ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1nb80hhGUZsIX+7ICHL1DwDs8aXHLt5fZ5dlcM/qF6+00Yf936sVu3NWELFLwfK+RxWNnGQ4KTszTTpZ8KUkIS5fb3O2OzXtdfYEWMM/v9k/pn0pySyM5x345apCM2vLXUUWTJyrjw== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601004)(2401047)(5005006)(8121501046)(10201501046)(3002001)(6055026); SRVR:MWHPR11MB1360; BCL:0; PCL:0; RULEID:; SRVR:MWHPR11MB1360; X-Forefront-PRVS: 00032065B2 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6009001)(7916002)(189002)(199003)(2906002)(97736004)(5001770100001)(6116002)(77096005)(4326007)(53416004)(2950100001)(3846002)(105586002)(33646002)(42186005)(189998001)(586003)(106356001)(229853001)(1076002)(68736007)(101416001)(81156014)(305945005)(48376002)(86362001)(7846002)(7736002)(50226002)(8676002)(76176999)(47776003)(19580395003)(66066001)(50986999)(36756003)(19580405001)(5003940100001)(69596002)(50466002)(92566002)(81166006)(83323001); DIR:OUT; SFP:1101; SCL:1; SRVR:MWHPR11MB1360; H:kms.harmonicinc.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: harmonicinc.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; MWHPR11MB1360; 23:5vTx/g/wL0kGKzl1gfLrtjDNrLdkor/UyS17oTEXZ?= =?us-ascii?Q?GSKL4bLN4razt92T7awDqlkHMfp6Ak475a1u7p8hclGjw0Fr8JzYsxKFeWBl?= =?us-ascii?Q?xjjwCzBWFn9zPBHX6tvxnCXFPdWC696fvszP05Ukju0uwQh/tRNj+MbM5vrV?= =?us-ascii?Q?V1b764g3EoMngDbYpnozbNNYS+YX/irYyDnJfVtqo+SW6d9ZLOjYMR6l8zwA?= =?us-ascii?Q?oIQO8gM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s2ZREE6pZdUvpU?= =?us-ascii?Q?tHXmZRniXSiN9In/ZOgh9so1TUoN6nR?= X-Microsoft-Exchange-Diagnostics: 1; MWHPR11MB1360; 6:cUP+tLMF7swKB6ggidbbLTtdpAiJeIfYgdFeO5VG3dqKk9Fyq+x7KedfQ2fOzc09fKxX0RhrwRdvSI2NskYTDeMf4/4qoWjyyFPKa7rbkTNGVuPrtuG+ga8vxIWObLxXGLqZUOqUn3OmPWsQ4rWX9uNhoj1cd6pL/sr/Zjh0Tfi6mBhv/TLjEjRvTqkFJmyDvqWpieqAWHLy2/OqmoMnve9xwyUgbcb9OLiESuSF44b0oquP5iC2xdXJTVrbe2GTgRaSrrzSK/EbHEj4Sg+blewXHyXrOZ8DtrJ0MQSxTbeIin4nLutEEGV0ZmTvDzn0tlj34Gw7A1QpS04h3gCMXg==; 5:F9SsqOVpugzXEzKLC++3eyxx9DbJ4bQvCI9tNKdJ+20nyMSGnyFneuI+ywPc/6TIBjdq63KdH0jNvIW0DDwUcIN9P0cd70qTUZGmHQl8d0YRdIKklROpT/Jva3viSSKhaq4wa0YgI8rpr4gA5enDAA==; 24:8o7laBbGxNV+iSZW2p211o95oIFwl21u489LmRRF9SZCuwi6prWp2rW8GbwJ1yo0S0C1iz4BBftkXbY4iIQTA5nKedQTI1l24/FfnW5OGcg=; 7:tCdE6dwP+Q5shSx5UwPU5Oj8wWM2ZvffxgX6RpB/DaPDkTlV6SoD6hQPCYeoiiKyqQMnbZR3l/N/BHsjNMu7+Nc7jqzZRiUPlU/hKZlq/TvTNjj2a3N2A1yuk46TIcgbRjDMTven3azTpmv2fRptBCjdVswlXC0KctNceWssw4E9Li9qiYHkxgLsnK3v1hWEwKBHncG3WaI6tesalW0FYH9qoxD9C16JhmGhBUJsTq1X1Sksxtd8pH23YSnGjK0Q SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; MWHPR11MB1360; 20:IfcHtWM40KyZM4j3077O6i++KJOTjIgL6ME4mGLWNxGBNbMtspNDL+Jm92Skjfq6LhpSrMkiPqXqON8UFHGitSObTzGUhARUJfKTq0lXUfbBHolRDOpewn8Z8KSh61eXMaZOewSAiyxVhm5zl7QRx60WYdrGGPodHep7W+du9/U= X-OriginatorOrg: harmonicinc.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Jul 2016 17:28:09.5169 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR11MB1360 Subject: [dpdk-dev] [PATCH] net/i40e: add additional prefetch instructions for bulk rx 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: Thu, 14 Jul 2016 17:28:12 -0000 Added prefetch of first packet payload cacheline in i40e_rx_scan_hw_ring Added prefetch of second mbuf cacheline in i40e_rx_alloc_bufs Signed-off-by: Vladyslav Buslov --- drivers/net/i40e/i40e_rxtx.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/net/i40e/i40e_rxtx.c b/drivers/net/i40e/i40e_rxtx.c index d3cfb98..e493fb4 100644 --- a/drivers/net/i40e/i40e_rxtx.c +++ b/drivers/net/i40e/i40e_rxtx.c @@ -1003,6 +1003,7 @@ i40e_rx_scan_hw_ring(struct i40e_rx_queue *rxq) /* Translate descriptor info to mbuf parameters */ for (j = 0; j < nb_dd; j++) { mb = rxep[j].mbuf; + rte_prefetch0(RTE_PTR_ADD(mb->buf_addr, RTE_PKTMBUF_HEADROOM)); qword1 = rte_le_to_cpu_64(\ rxdp[j].wb.qword1.status_error_len); pkt_len = ((qword1 & I40E_RXD_QW1_LENGTH_PBUF_MASK) >> @@ -1086,9 +1087,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++) { - if (likely(i < (rxq->rx_free_thresh - 1))) + if (likely(i < (rxq->rx_free_thresh - 1))) { /* Prefetch next mbuf */ - rte_prefetch0(rxep[i + 1].mbuf); + rte_prefetch0(&rxep[i + 1].mbuf->cacheline0); + rte_prefetch0(&rxep[i + 1].mbuf->cacheline1); + } mb = rxep[i].mbuf; rte_mbuf_refcnt_set(mb, 1); -- 2.8.3