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 2A436A0679 for ; Mon, 1 Apr 2019 20:20:19 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id C60A75B1E; Mon, 1 Apr 2019 20:20:17 +0200 (CEST) Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by dpdk.org (Postfix) with ESMTP id 9C1CF58C6 for ; Mon, 1 Apr 2019 20:20:15 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga106.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 01 Apr 2019 11:20:12 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,297,1549958400"; d="scan'208";a="334009916" Received: from orsmsx106.amr.corp.intel.com ([10.22.225.133]) by fmsmga005.fm.intel.com with ESMTP; 01 Apr 2019 11:20:12 -0700 Received: from orsmsx104.amr.corp.intel.com ([169.254.4.204]) by ORSMSX106.amr.corp.intel.com ([169.254.1.19]) with mapi id 14.03.0415.000; Mon, 1 Apr 2019 11:20:11 -0700 From: "Wang, Yipeng1" To: Dharmik Thakkar , "Gobriel, Sameh" , "Richardson, Bruce" , "De Lara Guarch, Pablo" , "Mcnamara, John" , "Kovacevic, Marko" CC: "dev@dpdk.org" Thread-Topic: [PATCH v2 1/2] hash: add lock free support for extendable bucket Thread-Index: AQHU4075hh0LpQoIeEeGbk4SpF903KYnp04w Date: Mon, 1 Apr 2019 18:20:06 +0000 Message-ID: References: <20190320223513.31249-1-dharmik.thakkar@arm.com> <20190325210838.2853-1-dharmik.thakkar@arm.com> <20190325210838.2853-2-dharmik.thakkar@arm.com> In-Reply-To: <20190325210838.2853-2-dharmik.thakkar@arm.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-ctpclassification: CTP_NT x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiNjIxY2FlNTctNzI3My00Yzg4LWE4NzQtYTFmNTNkMmZiODFjIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiSWdLM2xYNXJmcHdONlRpMytUZ0VQZDdaNCs1dHJiVXVuK2h1RWFheHdQMlY5SVA1b3JQYkdsMTNCUTVhVFltayJ9 x-originating-ip: [10.22.254.139] Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v2 1/2] hash: add lock free support for extendable bucket 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" Message-ID: <20190401182006.9_QyqdnRANEfwkZzaz0LrTPbbaSfjAVN2vYFAG6lBVQ@z> >-----Original Message----- >From: Dharmik Thakkar [mailto:dharmik.thakkar@arm.com] >Sent: Monday, March 25, 2019 2:09 PM >To: Wang, Yipeng1 ; Gobriel, Sameh ; Richardson, Bruce >; De Lara Guarch, Pablo ; Mcnamara, John >; Kovacevic, Marko >Cc: dev@dpdk.org; Dharmik Thakkar >Subject: [PATCH v2 1/2] hash: add lock free support for extendable bucket > >This patch enables lock-free read-write concurrency support for >extendable bucket feature. > >Suggested-by: Honnappa Nagarahalli >Signed-off-by: Dharmik Thakkar >Reviewed-by: Ruifeng Wang >Reviewed-by: Gavin Hu >Reviewed-by: Honnappa Nagarahalli >@@ -1072,7 +1082,15 @@ __rte_hash_add_key_with_hash(const struct rte_hash = *h, const void *key, > bkt_id =3D (uint32_t)((uintptr_t)ext_bkt_id) - 1; > /* Use the first location of the new bucket */ > (h->buckets_ext[bkt_id]).sig_current[0] =3D short_sig; >- (h->buckets_ext[bkt_id]).key_idx[0] =3D new_idx; >+ /* Key can be of arbitrary length, so it is >+ * not possible to store it atomically. >+ * Hence the new key element's memory stores >+ * (key as well as data) should be complete >+ * before it is referenced. >+ */ [Wang, Yipeng] Minor issue: does this comment need to be fixed too? If so y= ou could include my ack for next version. Acked-by: Yipeng Wang Thanks Yipeng!