From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-eopbgr140041.outbound.protection.outlook.com [40.107.14.41]) by dpdk.org (Postfix) with ESMTP id 30BA51B44D; Mon, 14 Jan 2019 08:12:19 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector1-arm-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=VktJZJvU+bdoLAy/K9P4JIV6qx/W+zsbC93ui0PVvVI=; b=EabkW0iu11/ZNOaZADKLo61mnvZfLCfbivZR1fZHaV1mnNgGZB1Jl2l19Zk/prwZ6pxjOrV1M4FxTHgjHH/OhRvRWjPTIM8l0bD8MsPUcOYM9L+eXkvrJGmaK+/xZXAoiP2HpMPpNXuDoziB1NrcR/qE+PDP0nHD0QqnPcMBbTk= Received: from AM0PR08MB3379.eurprd08.prod.outlook.com (20.177.109.79) by AM0PR08MB3041.eurprd08.prod.outlook.com (52.134.93.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1516.18; Mon, 14 Jan 2019 07:12:17 +0000 Received: from AM0PR08MB3379.eurprd08.prod.outlook.com ([fe80::b069:886:550c:7fda]) by AM0PR08MB3379.eurprd08.prod.outlook.com ([fe80::b069:886:550c:7fda%2]) with mapi id 15.20.1516.019; Mon, 14 Jan 2019 07:12:17 +0000 From: Dharmik Thakkar To: "Wang, Yipeng1" CC: "Yigit, Ferruh" , "Richardson, Bruce" , "De Lara Guarch, Pablo" , "dev@dpdk.org" , "stable@dpdk.org" , nd Thread-Topic: [dpdk-stable] [PATCH] test/hash: reset iter and found in perf test Thread-Index: AQHUiBLcWpI1382vJkqbNs/xCSAzXaWqkN2AgAAYSACAA/RoAA== Date: Mon, 14 Jan 2019 07:12:17 +0000 Message-ID: <9FBB652F-5091-43FF-A6CE-858B7487E745@arm.com> References: <20181129183855.9361-1-dharmik.thakkar@arm.com> <2d2fbf94-02a4-0215-1fd6-65bd9f32305a@intel.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-microsoft-exchange-diagnostics: 1; AM0PR08MB3041; 6:7UFiw/Tpdo8wlGlWRMaSrhmXOHV5aIYvg127NanWrYzC4mmbi+3bv2GEJABgC03OGGUjbjvl8vsLF6NmlRwCyVYLLmCZLFHinoso81pqJRn0ApVJES9at0G9H9ZrnOi/wRAdIDacnNg5T5aaRgvwQBcjlxp1/r/oISGe98wlSxE7FkwPhGeeeEiouSD0F59QBYkr4a5Tz4sQJtWoRSoL+Mo+ldNIu8O7UN9zQ+fztvqlekLqs6qa+EMhL8E4T3HHMOFlrnxQ7z13AZk6uMaoCzs1EQ0HP2wVsiIAG2e+dnpnu8jDAw1WnK0KHv4ZX78+S0D46uhmr2KxQAI100L5g9gON+8LV9gNcaYpIc3+qmwOBXagOxuIybW4BSsKWo24eiH7YluTvDjH8emx9Udyec4120nrg7HDAQL8qXa91LGA7daYG4BPK0JSgkxI4ThPg6V/CfidkFcUhwYXBAjLEQ==; 5:Kf9nYp3Sb6fli73S3nIuzB3ENvNGMbliFh8Oc0ytajISzTYdWsND8qUnD1J9W/AE4XNDM9Q3Z43aSdMAurRYoRxGebX8eY+BYevdPc9LEbVeXD32G+UeniyoumKrdJ0IM4kkMohvpZp6IKxf9xPvs9L0zZ/au/QvyIPCV6BlNXzmIuWv3nBMs2EMspYwB1UwHTpfh4JrbuGFBAjir2ENHA==; 7:EkSYTQRyA6A2Zm13M8Dfh+C/8+eAp/WrjTDg3oC+FX4HKxookXD8hT4fPBK0JO3KiFHJpLh4O3Kq8rCcJPAY41q7SFW634TRrfI2USNDoVNkAkBJmMUiDbiI+7R3L4NRe6h9UKHbKZLdvMrN45UqOw== x-ms-exchange-antispam-srfa-diagnostics: SOS; x-ms-office365-filtering-correlation-id: f6c9fcd7-1546-4c2f-292e-08d679ef9df7 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600109)(711020)(4618075)(2017052603328)(7153060)(7193020); SRVR:AM0PR08MB3041; x-ms-traffictypediagnostic: AM0PR08MB3041: nodisclaimer: True x-microsoft-antispam-prvs: x-forefront-prvs: 0917DFAC67 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(366004)(376002)(346002)(39850400004)(396003)(136003)(51914003)(189003)(199004)(13464003)(7736002)(83716004)(68736007)(305945005)(71190400001)(8936002)(36756003)(486006)(25786009)(72206003)(3846002)(71200400001)(6116002)(6436002)(33656002)(14454004)(229853002)(6486002)(76176011)(2906002)(105586002)(106356001)(97736004)(4326008)(5660300001)(66066001)(99286004)(476003)(11346002)(86362001)(81156014)(81166006)(256004)(102836004)(446003)(26005)(478600001)(53546011)(6506007)(316002)(6916009)(54906003)(8676002)(186003)(6512007)(14444005)(53936002)(6246003)(82746002)(2616005); DIR:OUT; SFP:1101; SCL:1; SRVR:AM0PR08MB3041; 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: 9c4S3AmX4kb9awDFltaclGzm0waiuQmPoYp7FuQ6dK+2LU4NNTMv39ePu4oQkreyp7mVkQ20HXyq5uMjtx9vk2g7nli1ZeP3ZYvvKZaPxK5TluLboEcl9/lpDhO/tdA68uFopjR6avfvycN9Ro36YpD+cxAIpMT2Yr9URN2VZX5c5g3D0Mf0biIZDwotWPfQphK92gPMNvvZ4yLo6n2sWQ76rU+IbAiHxsMogqfuXssFJb3gm/WdsVxDP3vQhaHHebwIwfwZwdrnv3JNbOqdnYawqjee5cjfucv1gpOTtAmhWnfikZ/8htjIhvY0N3VV8BRe3N9vhjM7XOO46iLNQ6TaqPaSeESiwjkloqyyk6B8GD10pldkJ/wFb9p7M3bxLAkUeExc0ULFDUFweRyjZo6ZPEdpKaqkbv3V7q+UzCE= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM 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: f6c9fcd7-1546-4c2f-292e-08d679ef9df7 X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Jan 2019 07:12:17.3088 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR08MB3041 Subject: Re: [dpdk-stable] [PATCH] test/hash: reset iter and found in perf test X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 14 Jan 2019 07:12:19 -0000 Thank you Ferruh and Yipeng! I will make the recommended changes and update= the version. > On Jan 12, 2019, at 12:07 AM, Wang, Yipeng1 wrot= e: >=20 > Thanks for the bug fix! Nice catch! >=20 >> -----Original Message----- >> From: Yigit, Ferruh >> Sent: Friday, January 11, 2019 9:10 AM >> To: Dharmik Thakkar ; Richardson, Bruce ; De Lara Guarch, Pablo >> >> Cc: dev@dpdk.org; stable@dpdk.org; Wang, Yipeng1 >> Subject: Re: [dpdk-stable] [PATCH] test/hash: reset iter and found in pe= rf test >>> uint32_t duplicated_keys =3D 0; >>> @@ -536,6 +535,8 @@ test_hash_readwrite_perf(struct perf *perf_results,= int use_htm, >>>=20 >>> rte_eal_mp_wait_lcore(); >>>=20 >>> + uint32_t iter =3D 0; >>=20 >> Logically looks good. Only we don't tend to declare the variables in the= middle >> of the scope, you may prefer to keep deceleration at its place but set '= iter' to >> zero here. > [Wang, Yipeng] Agree. >>=20 >>> + memset(tbl_rw_test_param.found, 0, TOTAL_ENTRY); >=20 > [Wang, Yipeng] test failed because of this line I think, the found is uin= t32_t array, so should be TOTAL_ENTRY * 4, or just change found to be int8 >=20 >>> while (rte_hash_iterate(tbl_rw_test_param.h, >>> &next_key, &next_data, &iter) >=3D 0) { >>> /* Search for the key in the list of keys added .*/ >>> @@ -619,7 +620,7 @@ test_hash_readwrite_main(void) >>> if (rte_lcore_count() <=3D 2) { >>> printf("More than two lcores are required " >>> "to do read write test\n"); >>> - return 0; >>> + return -1; >>=20 >> This is something not mentioned in the commit log, changes the default r= eturn >> value of test when not enough resources provided, cc'ed Yipeng for comme= nt. >>=20 >> If decided to keep this change, please update commit log to mention from= it. > [Wang, Yipeng] Yes it should be -1. Thanks for the fix. Please fix the co= mmit msg as Ferruh suggested