From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-BL2-obe.outbound.protection.outlook.com (mail-bl2nam02on0053.outbound.protection.outlook.com [104.47.38.53]) by dpdk.org (Postfix) with ESMTP id 9A533199B5 for ; Fri, 8 Dec 2017 06:22:58 +0100 (CET) Received: from MWHPR03CA0015.namprd03.prod.outlook.com (10.175.133.153) by MWHSPR00MB229.namprd03.prod.outlook.com (10.175.8.151) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.302.9; Fri, 8 Dec 2017 05:22:57 +0000 Received: from BN1BFFO11FD022.protection.gbl (2a01:111:f400:7c10::1:112) by MWHPR03CA0015.outlook.office365.com (2603:10b6:300:117::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.302.9 via Frontend Transport; Fri, 8 Dec 2017 05:22:57 +0000 Authentication-Results: spf=fail (sender IP is 192.88.168.50) smtp.mailfrom=nxp.com; NXP1.onmicrosoft.com; dkim=none (message not signed) header.d=none;NXP1.onmicrosoft.com; dmarc=fail action=none header.from=nxp.com; Received-SPF: Fail (protection.outlook.com: domain of nxp.com does not designate 192.88.168.50 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.168.50; helo=tx30smr01.am.freescale.net; Received: from tx30smr01.am.freescale.net (192.88.168.50) by BN1BFFO11FD022.mail.protection.outlook.com (10.58.144.85) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.282.5 via Frontend Transport; Fri, 8 Dec 2017 05:22:53 +0000 Received: from bf-netperf1.ap.freescale.net (bf-netperf1.ap.freescale.net [10.232.134.28]) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id vB85MKGl013022; Thu, 7 Dec 2017 22:22:53 -0700 From: Hemant Agrawal To: CC: , , Nipun Gupta Date: Fri, 8 Dec 2017 10:51:27 +0530 Message-ID: <1512710487-32388-15-git-send-email-hemant.agrawal@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1512710487-32388-1-git-send-email-hemant.agrawal@nxp.com> References: <1512710487-32388-1-git-send-email-hemant.agrawal@nxp.com> X-EOPAttributedMessage: 0 X-Matching-Connectors: 131571841738588327; (91ab9b29-cfa4-454e-5278-08d120cd25b8); () X-Forefront-Antispam-Report: CIP:192.88.168.50; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(7966004)(336005)(346002)(376002)(39380400002)(39860400002)(2980300002)(1109001)(1110001)(339900001)(199004)(189003)(5660300001)(106466001)(2351001)(105606002)(81156014)(81166006)(50466002)(8676002)(48376002)(8656006)(51416003)(76176011)(498600001)(97736004)(104016004)(296002)(47776003)(16586007)(4326008)(2906002)(316002)(77096006)(68736007)(6916009)(54906003)(86362001)(85426001)(50226002)(2950100002)(53936002)(305945005)(6666003)(8936002)(33646002)(356003)(36756003); DIR:OUT; SFP:1101; SCL:1; SRVR:MWHSPR00MB229; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; A:1; MX:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BN1BFFO11FD022; 1:6/B6PTN8iCJNiD3G5V9Z1q2m7HhS1RplEoYaWza7zb4XgMU6RkoSMozAIRe/EMctHqvhi6h3Ha7h7+vQWXv95U7/hIDa8fw49dy558GMo4CMREEZJ2CwW2l2b+1WQ51c MIME-Version: 1.0 Content-Type: text/plain X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 6d02ade2-4201-43ad-5f48-08d53dfbbbba X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(5600026)(4604075)(4534020)(4628075)(201703131517081)(2017052603307); SRVR:MWHSPR00MB229; X-Microsoft-Exchange-Diagnostics: 1; MWHSPR00MB229; 3:tHMlZ/aWGkoCZHAIKhZknis4oWrH8q5JqeUoISHlRaC2YeCJHhgcvnrMULztG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iMxiVnQv6EfWTiqa0xWVxT8XB4GydoHbjSMy0wo1mIgidxv72/bIw7Zr1XRxU9f/cAb8z9tj1NtXj1BOqH2YqcOJUTWfWo/i6Ro71W5zY7PSyWWBURgB1PtDo+20lAKilPFTHklnY/hMlBqKK6ks94W+f/8TnJd5EtVmD3JByyW9zixm8YFXFm3wfwhdgg/5 X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6095135)(2401047)(8121501046)(5005006)(93006095)(93001095)(10201501046)(3231022)(3002001)(6055026)(6096035)(20161123556025)(20161123565025)(20161123561025)(201703131430075)(201703131520075)(201703131441075)(201703131448075)(201703131433075)(201703161259150)(20161123563025)(20161123559100)(201708071742011); SRVR:MWHSPR00MB229; BCL:0; PCL:0; RULEID:(100000803101)(100110400095)(400006); SRVR:MWHSPR00MB229; X-Forefront-PRVS: 0515208626 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; MWHSPR00MB229; 23:vlgxtlqEZ/WZsxGmoFjsB3iRpzCbM8DR1Di+xUMgG?= =?us-ascii?Q?xNWwxROh033b8dS2ZzkvG05Urs451dA3EjeUtviyljsyELS/UWWdtQewsywu?= =?us-ascii?Q?MuttYxWOZ/GAnec4kyjjrNa+Z3UV+M3tLvBAYGaw2RCHi3kF562H7ro6oHxz?= =?us-ascii?Q?6zyM/hAX2pWkf/ROsrUFBPbmz/tIyu/XT+Pua5JBAqP7H2hA1BKmHkbo9bC8?= =?us-ascii?Q?pt9tZ1hG32fAmYJ6iakKowk4dyBkjh/OFt12Z+UesoTmL7HeErJ0ewK8dPeC?= =?us-ascii?Q?5nETcByqK89D48nVi2JXB9N/HSHUHFWOmufo/Uoy2roBqtuUAP3NAekbaOAl?= =?us-ascii?Q?79KgnD7Mkd8NNurWIJ+NeKAwtzijm1FGOhBGw2SgndHXt3MCAO2I7MSDAU0D?= =?us-ascii?Q?8GWn9UhAllnX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des10hDjeBIqjttvG7vSJYyRkSdQIVyVqEnQaj/bf/hzu1Tihqg7FBps4zHpFn1dKV0MV9GjQebUTGF+xHn1+uIgE3/u9Moew6FSbpfT2pe+FWk0Mdjp5F73Q4x0w5tXAdO3T+bgqm/JaN4jumIn9q+v5A6XTNEjOZX+o+1ttHtiR8d24bdmh1lYs4j/w8vpPp9xmaG74Mj34SqHQzXJrynjT8xXoVkvF+si9SLVo=; 5:WGwcPy7IOl/46x+oINETYVdxWjznty2ZiBl679I+wTIlImuGNSI6gCvanv2sixm5FM5qn9iXXmFGv7r+CLLKKEhTmqduFxo3sCYdan6vEXjpRxzwtu/4bOvgKBWYBxtERy9c3qw/9kyAriQh6U8ofPodTQFutys5yQLLBShVOW4=; 24:f9jZm2ZmzaTTlECCOdIuAp12CId8S/SaEIGCuYgvuiG92AECiblDD7hVsjbk3ie9EcHC+imxN7zbAjRNnfjWBwRN9qgc27NqgwpOk+TwyCk=; 7:KxumyqjdQIzKIn6y86cIpIF9hAhyFvTGxyAMBQUy0U6+WjsYPBlpUmOdPdm8qakU4XA5haMNOVHS81KUwZwZxr8Urm5Fw5cXLZVWf6YtRzAYAODX+Ow+QDaiCyS4RnV0LhLZtoeM1/u1qmjzWBvT+zsjKfJmxKS5V1kn+DVTKIglW+T/V4UZ5IzrqtHs/Dbe6P2cyAwfESFDCXUCAvznNfjLaaOW3UdFn5L2/PSUlC3BMJXh+RD4uMTMxuTi4xDf SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Dec 2017 05:22:53.6716 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 6d02ade2-4201-43ad-5f48-08d53dfbbbba X-MS-Exchange-CrossTenant-Id: 5afe0b00-7697-4969-b663-5eab37d5f47e X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5afe0b00-7697-4969-b663-5eab37d5f47e; Ip=[192.88.168.50]; Helo=[tx30smr01.am.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHSPR00MB229 Subject: [dpdk-dev] [PATCH 14/14] net/dpaa2: prefetch the parse results from next fd 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: , X-List-Received-Date: Fri, 08 Dec 2017 05:22:59 -0000 From: Nipun Gupta As there were less number of cpu cycles in between when we access the parse results and when we prefetch them, this patch modifies the prefetch of the next parse result. Signed-off-by: Nipun Gupta --- drivers/net/dpaa2/dpaa2_rxtx.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/net/dpaa2/dpaa2_rxtx.c b/drivers/net/dpaa2/dpaa2_rxtx.c index e8edc67..9b66bd3 100644 --- a/drivers/net/dpaa2/dpaa2_rxtx.c +++ b/drivers/net/dpaa2/dpaa2_rxtx.c @@ -526,7 +526,7 @@ dpaa2_dev_prefetch_rx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts) int ret, num_rx = 0; uint8_t is_last = 0, status; struct qbman_swp *swp; - const struct qbman_fd *fd[DPAA2_DQRR_RING_SIZE]; + const struct qbman_fd *fd[DPAA2_DQRR_RING_SIZE], *next_fd; struct qbman_pull_desc pulldesc; struct queue_storage_info_t *q_storage = dpaa2_q->q_storage; struct rte_eth_dev *dev = dpaa2_q->dev; @@ -569,6 +569,7 @@ dpaa2_dev_prefetch_rx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts) set_swp_active_dqs(DPAA2_PER_LCORE_DPIO->index, dq_storage); } dq_storage = q_storage->active_dqs; + rte_prefetch0((void *)((uint64_t)(dq_storage + 1))); /* Check if the previous issued command is completed. * Also seems like the SWP is shared between the Ethernet Driver * and the SEC driver. @@ -583,7 +584,7 @@ dpaa2_dev_prefetch_rx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts) */ while (!qbman_check_new_result(dq_storage)) ; - rte_prefetch0((void *)((uint64_t)(dq_storage + 1))); + rte_prefetch0((void *)((uint64_t)(dq_storage + 2))); /* Check whether Last Pull command is Expired and * setting Condition for Loop termination */ @@ -596,8 +597,9 @@ dpaa2_dev_prefetch_rx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts) } fd[num_rx] = qbman_result_DQ_fd(dq_storage); + next_fd = qbman_result_DQ_fd(dq_storage + 1); /* Prefetch Annotation address for the parse results */ - rte_prefetch0((void *)((uint64_t)DPAA2_GET_FD_ADDR(fd[num_rx]) + rte_prefetch0((void *)((uint64_t)DPAA2_GET_FD_ADDR(next_fd) + DPAA2_FD_PTA_SIZE + 16)); if (unlikely(DPAA2_FD_GET_FORMAT(fd[num_rx]) == qbman_fd_sg)) -- 2.7.4