Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oQ0M3-0008NZ-JI for pgsql-hackers@arkaria.postgresql.org; Mon, 22 Aug 2022 05:52:07 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oQ0M0-0008F3-Nb for pgsql-hackers@arkaria.postgresql.org; Mon, 22 Aug 2022 05:52:04 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oQ0Lz-0008Et-PB for pgsql-hackers@lists.postgresql.org; Mon, 22 Aug 2022 05:52:04 +0000 Received: from smtp-fw-6001.amazon.com ([52.95.48.154]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oQ0Lx-0003rm-AW for pgsql-hackers@lists.postgresql.org; Mon, 22 Aug 2022 05:52:03 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1661147522; x=1692683522; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=fLw05T6ihR77PU9duMGEJJVKeF0N9GQ6qHVJ9ShCSSM=; b=r9epWzBhoeHARBtW0SlRSuhIPa1fSjNfVZr5Fu6YmGRGoWuL6h1MYBPd BdCgPSk2rPOgShsD/Eu3HdgvV/OItyWcDSZzONl7gl/XU41eiGcvwDcxI bKN/bR5HjJQm4x0GmP6+D7SV1DTBLp0VyCJpaT+t/FuWvBY3WYLkuwD+f k=; Received: from iad12-co-svc-p1-lb1-vlan2.amazon.com (HELO email-inbound-relay-iad-1a-c92fe759.us-east-1.amazon.com) ([10.43.8.2]) by smtp-border-fw-6001.iad6.amazon.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Aug 2022 05:51:49 +0000 Received: from EX13D03EUC003.ant.amazon.com (iad12-ws-svc-p26-lb9-vlan2.iad.amazon.com [10.40.163.34]) by email-inbound-relay-iad-1a-c92fe759.us-east-1.amazon.com (Postfix) with ESMTPS id 0B069C0A7C; Mon, 22 Aug 2022 05:51:47 +0000 (UTC) Received: from [192.168.15.161] (10.43.162.247) by EX13D03EUC003.ant.amazon.com (10.43.164.192) with Microsoft SMTP Server (TLS) id 15.0.1497.38; Mon, 22 Aug 2022 05:51:44 +0000 Message-ID: <67f847bb-a1c2-f444-b2e0-333a97f1953a@amazon.com> Date: Mon, 22 Aug 2022 07:51:39 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.1.2 Subject: Re: shared-memory based stats collector - v70 To: Kyotaro Horiguchi CC: , , References: <20220809165319.jdzd225xohqf6o57@awork3.anarazel.de> <20220810.113910.92411510444435201.horikyota.ntt@gmail.com> <3d853c6f-445f-782e-eab0-525729952d4c@amazon.com> <20220822.113214.157880042751504547.horikyota.ntt@gmail.com> Content-Language: en-US From: "Drouvot, Bertrand" In-Reply-To: <20220822.113214.157880042751504547.horikyota.ntt@gmail.com> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.43.162.247] X-ClientProxiedBy: EX13D20UWA004.ant.amazon.com (10.43.160.62) To EX13D03EUC003.ant.amazon.com (10.43.164.192) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi, On 8/22/22 4:32 AM, Kyotaro Horiguchi wrote: > At Wed, 10 Aug 2022 14:02:34 +0200, "Drouvot, Bertrand" wrote in >> what about? >> >> + /* >> + * Acquire the LWLock directly instead of using >> pg_stat_lock_entry_shared() >> + * which requires a reference. >> + */ >> >> >> I think that's more consistent with other comments mentioning LWLock >> acquisition. > Sure. Thaks!. I did that in the attached. Thank you! The patch looks good to me. Regards, Bertrand