From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 15C76A046B for ; Tue, 28 May 2019 16:16:03 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 74B952C55; Tue, 28 May 2019 16:16:01 +0200 (CEST) Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-eopbgr60041.outbound.protection.outlook.com [40.107.6.41]) by dpdk.org (Postfix) with ESMTP id 0ACA21B05; Tue, 28 May 2019 16:15:59 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=EsF15rinWrHYrcsp/xJFGJj+H2CNFuqPiR50aBoQfC4=; b=MgAnMT736HEnC3x1qcDN60mBXNO6VvmXtn43LRBP9/41AqiioOPu1G9sddcKfU7s/dAySh2LArCwju9Vx/DISwQOa1Ne2p2l6NGf9kGVfBDmFZg8BxullC0Yi5prKJJjuaTMumqgjz2bGdWB1zvFMRx5Fgdx2kRnsKmk5m3Xyz8= Received: from AM0PR08MB3379.eurprd08.prod.outlook.com (20.177.109.142) by AM0PR08MB5331.eurprd08.prod.outlook.com (52.132.212.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1943.16; Tue, 28 May 2019 14:15:59 +0000 Received: from AM0PR08MB3379.eurprd08.prod.outlook.com ([fe80::1163:3f6:3219:55ed]) by AM0PR08MB3379.eurprd08.prod.outlook.com ([fe80::1163:3f6:3219:55ed%3]) with mapi id 15.20.1922.021; Tue, 28 May 2019 14:15:59 +0000 From: Dharmik Thakkar To: David Marchand CC: "dev@dpdk.org" , "thomas@monjalon.net" , Stephen Hemminger , "maxime.coquelin@redhat.com" , "stable@dpdk.org" , Yipeng Wang , Sameh Gobriel , Bruce Richardson , Pablo de Lara , nd Thread-Topic: [PATCH v2 1/2] test/hash: use existing lcore API Thread-Index: AQHVELBHveV4sz8jtkC3zeQ0ToSAAKZ3VLWAgAAOUYCAACc0AIAHPoWAgAHVnQA= Date: Tue, 28 May 2019 14:15:59 +0000 Message-ID: References: <1557907020-1548-1-git-send-email-david.marchand@redhat.com> <1558537617-27813-1-git-send-email-david.marchand@redhat.com> <9B028D36-C801-49AC-B529-C8721F0B7D8C@arm.com> <86110770-2603-480C-9D25-371773EC1916@arm.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Dharmik.Thakkar@arm.com; x-originating-ip: [217.140.111.135] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: ce06a900-5dca-4b1c-35c9-08d6e37701d5 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(4618075)(2017052603328)(7193020); SRVR:AM0PR08MB5331; x-ms-traffictypediagnostic: AM0PR08MB5331: x-ld-processed: f34e5979-57d9-4aaa-ad4d-b122a662184d,ExtAddr nodisclaimer: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:6430; x-forefront-prvs: 00514A2FE6 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(346002)(39860400002)(136003)(376002)(396003)(366004)(189003)(199004)(2906002)(73956011)(66946007)(4326008)(486006)(91956017)(25786009)(33656002)(76116006)(186003)(26005)(305945005)(6436002)(6486002)(6512007)(7736002)(81166006)(8936002)(8676002)(229853002)(81156014)(11346002)(2616005)(476003)(64756008)(66556008)(446003)(66476007)(14454004)(36756003)(102836004)(66446008)(53546011)(316002)(478600001)(72206003)(66066001)(99286004)(68736007)(6506007)(54906003)(6916009)(3846002)(6116002)(82746002)(6246003)(53936002)(7416002)(83716004)(86362001)(71200400001)(71190400001)(76176011)(256004)(5660300002); DIR:OUT; SFP:1101; SCL:1; SRVR:AM0PR08MB5331; H:AM0PR08MB3379.eurprd08.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: arm.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: lXDuwjz+m65uvkSejy0eR7oVbqSFLTepFkfOoqdNlw6XK7BjCd39PsDkWfXDtjnoBCZLM4X6km81Bi8u8JsyaQz44MhYlzpaRfE0hhKyUDnmkrAhtBDAigXFSALsM5/tyupSh6r8h0CK2O16XBrlPrCorjq1LOZXk+JDSmA4+lJtO3lSvIAdhLqZkngbAze2bcYYR+tN7k24Ru6ZudsW960SyCd3FF0deknpNBbhqmhMiT6gCQv/EE8q74Ynp+An4h+CkyKtQScHYf7xXvT4p9AleS5HwZEIbI7ZauDHkHmEvxUlf5rk4NPi8VoOP3/XukfOYZ4+iBQGk/dsDTB40ZYVc/1SG/1qtUww7n4tRjOSHFVsLqmZacemfFWy+unu8W3QVj2vasbXggWM4jYf/x1CL2LslH0Yy3JpXLvHyj8= Content-Type: text/plain; charset="us-ascii" Content-ID: Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-Network-Message-Id: ce06a900-5dca-4b1c-35c9-08d6e37701d5 X-MS-Exchange-CrossTenant-originalarrivaltime: 28 May 2019 14:15:59.0447 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: Dharmik.Thakkar@arm.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR08MB5331 Subject: Re: [dpdk-dev] [PATCH v2 1/2] test/hash: use existing lcore API 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" > On May 27, 2019, at 5:15 AM, David Marchand w= rote: >=20 > Hello Dharmik, Hi David, >=20 > On Wed, May 22, 2019 at 9:38 PM Dharmik Thakkar = wrote: > > On May 22, 2019, at 12:17 PM, David Marchand wrote: > > On Wed, May 22, 2019 at 6:27 PM Dharmik Thakkar wrote: > > > @@ -738,10 +736,9 @@ struct { > > > rte_eal_remote_launch(test_rwc_reader, > > > (void *)(uintptr_t)read= _type, > > > enabled_core_id= s[i]); > > > - rte_eal_mp_wait_lcore(); > > >=20 > > > for (i =3D 1; i <=3D rwc_core_cnt[n]; i++) > > > - if (lcore_config[i].ret < 0) > > > + if (rte_eal_wait_lcore(i) < 0) > > if (rte_eal_wait_lcore(enabled_core_ids[i]) < 0) > >=20 > > (There are similar changes in other functions too. > > I realize that this is a separate issue than what the patch is aimed fo= r. > > If you see fit, please integrate it, else I will put out a patch once y= our patch has been merged.) > >=20 > > Indeed, reproduced. > >=20 >=20 > Did you have a chance to look at this ? > These loops could be reworked by using RTE_LCORE_FOREACH_SLAVE() (so that= it automatically skips the master lcore) removing the need for enabled_cor= e_ids[]. >=20 Yes, I have tried to use RTE_LCORE_FOREACH_SLAVE() and eliminate enabled_co= re_ids[]. However, the code becomes quite complicated to read with if state= ments within RTE_LCORE_FOREACH_SLAVE(), to break the loop (since not all slave co= res are checked for). This is a snip from test_hash_multi_add_lookup(): /* snip */ RTE_LCORE_FOREACH_SLAVE(core_id) { if (i < rwc_core_cnt[n]) rte_eal_remote_launch(test_rwc_reader, (void *)(uintptr_t)read_type, core_id); else if (i >=3D rwc_core_cnt[n] && i < (rwc_core_cnt[n] + rwc_core_cnt[m])) { rte_eal_remote_launch(test_rwc_multi_writer, (void *)(uintptr_t)pos_core, core_id); pos_core++; } else break; i++; } >=20 > --=20 > David Marchand