Message ID | 20171030073126.1662-1-gprathyusha@caviumnetworks.com (mailing list archive) |
---|---|
State | Accepted, archived |
Delegated to: | Ferruh Yigit |
Headers |
Return-Path: <dev-bounces@dpdk.org> X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 35F7B1B325; Mon, 30 Oct 2017 08:31:57 +0100 (CET) Received: from NAM02-CY1-obe.outbound.protection.outlook.com (mail-cys01nam02on0087.outbound.protection.outlook.com [104.47.37.87]) by dpdk.org (Postfix) with ESMTP id B1D721B324 for <dev@dpdk.org>; Mon, 30 Oct 2017 08:31:55 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=LqzEn1DIdsq5EAXYRUrA8xTPhXfvaRx6KYgjZTSLw+4=; b=QAvKbgUNww995ctT9dcEh4KJcQsNjUU3+Dj/APEalqvN01DkgaXEV0Q75CSfpQMdJ66YAFjwTwxCFJmsa3wP5rUfnFe1y3vhPV5dNrFr+tz9J3yFojDSHGCCnI38IHvbFeIDnSA+/qMDyeJpesW1bnSX1WPLiu2Jp49Sms6Vfwk= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Guduri.Prathyusha@cavium.com; Received: from prathyusha-Precision-Tower-5810.caveonetworks.com (111.93.218.67) by SN1PR07MB1517.namprd07.prod.outlook.com (10.161.223.154) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.178.6; Mon, 30 Oct 2017 07:31:51 +0000 From: Guduri Prathyusha <gprathyusha@caviumnetworks.com> To: tomasz.kantecki@intel.com Cc: Jianbo.Liu@arm.com, guduriprathyusha@gmail.com, dev@dpdk.org, Guduri Prathyusha <gprathyusha@caviumnetworks.com> Date: Mon, 30 Oct 2017 13:01:26 +0530 Message-Id: <20171030073126.1662-1-gprathyusha@caviumnetworks.com> X-Mailer: git-send-email 2.14.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [111.93.218.67] X-ClientProxiedBy: MA1PR01CA0105.INDPRD01.PROD.OUTLOOK.COM (10.174.56.149) To SN1PR07MB1517.namprd07.prod.outlook.com (10.161.223.154) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 736bb393-0132-45ad-5773-08d51f684aa4 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(4534020)(4602075)(2017052603238); SRVR:SN1PR07MB1517; X-Microsoft-Exchange-Diagnostics: 1; SN1PR07MB1517; 3:L+4lXpDljUJX3l/8fYl+N8SvDIdonXG0k6MGrNCZnCrjtBlIfXSeOGj7lfzJfLYQfxpRKOOtiRAx+U3lmyVdPCJZtmsx/vgTcSG65sAq9U9INoO1HaS8w2pIP+GywBQ126rnfDrClk+AVU8tVhGBzIb581tLBGitzXcY1qq1P7jLv66ijs8HtuCArE9blpIzPx2RH6mJ8m286ci/UAt8igotqu7MdhqD21NpVfx+C/Bxx2DDYr3Pam++pJaLRelH; 25:py+Po0H+FN8AOb/pWtomnAJfy31cphlF4ZU9CxB6b6B6xk/qT673z2MUiN1y4i97B7BFcsbVLgNhdi7AVrDmQY/ZOKEpdhFllhmEzHIionPunW9en8pKVWX87xXME9hQpCY81W5hE4AnmRekYyBZWPF4WZRZTUcTWlO5As7x7WxoUyQ+gmxgYSAMccRNnor8lH8NttxPOuImWYVcwnhLvOnMmlQSB4DQsE/JjVbM5eVV6CSJDGo/kzS5IstEclFMQzZ8orJb5neXEqxHPRfrC5WnYoMYbmsJ2Dan60fEdKiuMYF+SIKvGu79sdXhD8Xm09fRVTKlvIpiilvBR3Eqcr3LNsgx37gEo9xDAOOgxeQ=; 31:IG46NhwkWELerxWX5DG+clobzyHCXdX8VCD4kKJb53e2ot8lxtjuDHmgQRA6ojcGsRBI0EI0g7aHEWHj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XlVup5IiqX+kAfVe01Lij641gaERTnqIwg6CIaPLnZZw== X-Exchange-Antispam-Report-Test: UriScan:; X-Microsoft-Antispam-PRVS: <SN1PR07MB15175F44A0A60B9FD22DFFFF8F590@SN1PR07MB1517.namprd07.prod.outlook.com> X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(2401047)(5005006)(8121501046)(3002001)(10201501046)(3231020)(93006095)(100000703101)(100105400095)(6041248)(20161123558100)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123564025)(20161123555025)(20161123560025)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:SN1PR07MB1517; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:SN1PR07MB1517; X-Forefront-PRVS: 0476D4AB88 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6009001)(376002)(346002)(189002)(199003)(72206003)(305945005)(6486002)(6916009)(101416001)(42882006)(8676002)(81166006)(8936002)(7736002)(33646002)(81156014)(50986999)(36756003)(53936002)(68736007)(189998001)(6506006)(48376002)(25786009)(50466002)(50226002)(6512007)(5660300001)(2906002)(97736004)(69596002)(4326008)(106356001)(16526018)(105586002)(6116002)(1076002)(3846002)(316002)(66066001)(16586007)(47776003)(107886003)(39060400002)(2361001)(53416004)(478600001)(6666003)(2351001)(5003940100001)(5009440100003); DIR:OUT; SFP:1101; SCL:1; SRVR:SN1PR07MB1517; H:prathyusha-Precision-Tower-5810.caveonetworks.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; SN1PR07MB1517; 23:lwF0hPceIlspspnd+XVat91rzshNHoSg+9AV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:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Oct 2017 07:31:51.5418 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 736bb393-0132-45ad-5773-08d51f684aa4 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN1PR07MB1517 Subject: [dpdk-dev] [PATCH v2] examples/l3fwd: fix NEON instructions X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions <dev.dpdk.org> List-Unsubscribe: <http://dpdk.org/ml/options/dev>, <mailto:dev-request@dpdk.org?subject=unsubscribe> List-Archive: <http://dpdk.org/ml/archives/dev/> List-Post: <mailto:dev@dpdk.org> List-Help: <mailto:dev-request@dpdk.org?subject=help> List-Subscribe: <http://dpdk.org/ml/listinfo/dev>, <mailto:dev-request@dpdk.org?subject=subscribe> Errors-To: dev-bounces@dpdk.org Sender: "dev" <dev-bounces@dpdk.org> |
Checks
Context | Check | Description |
---|---|---|
ci/checkpatch | success | coding style OK |
ci/Intel-compilation | success | Compilation OK |
Commit Message
Guduri Prathyusha
Oct. 30, 2017, 7:31 a.m. UTC
To group consecutive packets with same destination port in bursts of 4
neon intrinsic data types dp1 and dp2 are calculated such that if
dst_port[]={a,b,c,d,e,f,g,h,i...} dp1 should contain: <a,b,c,d> and
dp2 should contain: <b,c,d,e> in the first iteration. dp1 should
be <e,f,g,h> and dp2 should be <f,g,h,i> in the next iteration.
Whereas the existing code incorrectly calculates dp1 as <d,e,f,g> from
second iteration.
This patch fixes the incorrect ARM NEON instructions on dp1.
Fixes: 569b290cdb36 ("examples/l3fwd: add NEON implementation")
Signed-off-by: Guduri Prathyusha <gprathyusha@caviumnetworks.com>
---
v2:
* fix as suggested by Jianbo Liu
---
examples/l3fwd/l3fwd_neon.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Comments
The 10/30/2017 13:01, Guduri Prathyusha wrote: > To group consecutive packets with same destination port in bursts of 4 > neon intrinsic data types dp1 and dp2 are calculated such that if > dst_port[]={a,b,c,d,e,f,g,h,i...} dp1 should contain: <a,b,c,d> and > dp2 should contain: <b,c,d,e> in the first iteration. dp1 should > be <e,f,g,h> and dp2 should be <f,g,h,i> in the next iteration. > > Whereas the existing code incorrectly calculates dp1 as <d,e,f,g> from > second iteration. > > This patch fixes the incorrect ARM NEON instructions on dp1. > > Fixes: 569b290cdb36 ("examples/l3fwd: add NEON implementation") > > Signed-off-by: Guduri Prathyusha <gprathyusha@caviumnetworks.com> Acked-by: Jianbo Liu <jianbo.liu@arm.com> > --- > > v2: > > * fix as suggested by Jianbo Liu > --- > examples/l3fwd/l3fwd_neon.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/examples/l3fwd/l3fwd_neon.h b/examples/l3fwd/l3fwd_neon.h > index 42d50d3c2..4bc161394 100644 > --- a/examples/l3fwd/l3fwd_neon.h > +++ b/examples/l3fwd/l3fwd_neon.h > @@ -192,7 +192,7 @@ send_packets_multi(struct lcore_conf *qconf, struct rte_mbuf **pkts_burst, > * dp1: > * <d[j], d[j+1], d[j+2], d[j+3], ... > > */ > - dp1 = vextq_u16(dp1, dp1, FWDSTEP - 1); > + dp1 = vextq_u16(dp2, dp1, FWDSTEP - 1); > } > > /* > -- > 2.14.1 > -- IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
-----Original Message----- > Date: Mon, 30 Oct 2017 15:36:15 +0800 > From: Jianbo Liu <Jianbo.Liu@arm.com> > To: Guduri Prathyusha <gprathyusha@caviumnetworks.com> > CC: tomasz.kantecki@intel.com, guduriprathyusha@gmail.com, dev@dpdk.org > Subject: Re: [dpdk-dev] [PATCH v2] examples/l3fwd: fix NEON instructions > User-Agent: Mutt/1.5.21 (2010-09-15) > > The 10/30/2017 13:01, Guduri Prathyusha wrote: > > To group consecutive packets with same destination port in bursts of 4 > > neon intrinsic data types dp1 and dp2 are calculated such that if > > dst_port[]={a,b,c,d,e,f,g,h,i...} dp1 should contain: <a,b,c,d> and > > dp2 should contain: <b,c,d,e> in the first iteration. dp1 should > > be <e,f,g,h> and dp2 should be <f,g,h,i> in the next iteration. > > > > Whereas the existing code incorrectly calculates dp1 as <d,e,f,g> from > > second iteration. > > > > This patch fixes the incorrect ARM NEON instructions on dp1. > > > > Fixes: 569b290cdb36 ("examples/l3fwd: add NEON implementation") > > > > Signed-off-by: Guduri Prathyusha <gprathyusha@caviumnetworks.com> > > Acked-by: Jianbo Liu <jianbo.liu@arm.com> Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com> Cc: Thomas Monjalon <thomas@monjalon.net> to add this patch in RC3 > > > --- > > > > v2: > > > > * fix as suggested by Jianbo Liu > > --- > > examples/l3fwd/l3fwd_neon.h | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/examples/l3fwd/l3fwd_neon.h b/examples/l3fwd/l3fwd_neon.h > > index 42d50d3c2..4bc161394 100644 > > --- a/examples/l3fwd/l3fwd_neon.h > > +++ b/examples/l3fwd/l3fwd_neon.h > > @@ -192,7 +192,7 @@ send_packets_multi(struct lcore_conf *qconf, struct rte_mbuf **pkts_burst, > > * dp1: > > * <d[j], d[j+1], d[j+2], d[j+3], ... > > > */ > > - dp1 = vextq_u16(dp1, dp1, FWDSTEP - 1); > > + dp1 = vextq_u16(dp2, dp1, FWDSTEP - 1); > > } > > > > /* > > -- > > 2.14.1 > > > > -- > IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
On 11/2/2017 3:33 AM, Jerin Jacob wrote: > -----Original Message----- >> Date: Mon, 30 Oct 2017 15:36:15 +0800 >> From: Jianbo Liu <Jianbo.Liu@arm.com> >> To: Guduri Prathyusha <gprathyusha@caviumnetworks.com> >> CC: tomasz.kantecki@intel.com, guduriprathyusha@gmail.com, dev@dpdk.org >> Subject: Re: [dpdk-dev] [PATCH v2] examples/l3fwd: fix NEON instructions >> User-Agent: Mutt/1.5.21 (2010-09-15) >> >> The 10/30/2017 13:01, Guduri Prathyusha wrote: >>> To group consecutive packets with same destination port in bursts of 4 >>> neon intrinsic data types dp1 and dp2 are calculated such that if >>> dst_port[]={a,b,c,d,e,f,g,h,i...} dp1 should contain: <a,b,c,d> and >>> dp2 should contain: <b,c,d,e> in the first iteration. dp1 should >>> be <e,f,g,h> and dp2 should be <f,g,h,i> in the next iteration. >>> >>> Whereas the existing code incorrectly calculates dp1 as <d,e,f,g> from >>> second iteration. >>> >>> This patch fixes the incorrect ARM NEON instructions on dp1. >>> >>> Fixes: 569b290cdb36 ("examples/l3fwd: add NEON implementation") >>> >>> Signed-off-by: Guduri Prathyusha <gprathyusha@caviumnetworks.com> >> >> Acked-by: Jianbo Liu <jianbo.liu@arm.com> > > Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com> Applied to dpdk/master, thanks.
diff --git a/examples/l3fwd/l3fwd_neon.h b/examples/l3fwd/l3fwd_neon.h index 42d50d3c2..4bc161394 100644 --- a/examples/l3fwd/l3fwd_neon.h +++ b/examples/l3fwd/l3fwd_neon.h @@ -192,7 +192,7 @@ send_packets_multi(struct lcore_conf *qconf, struct rte_mbuf **pkts_burst, * dp1: * <d[j], d[j+1], d[j+2], d[j+3], ... > */ - dp1 = vextq_u16(dp1, dp1, FWDSTEP - 1); + dp1 = vextq_u16(dp2, dp1, FWDSTEP - 1); } /*