Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rBhYx-00BzsH-LK for pgsql-hackers@arkaria.postgresql.org; Fri, 08 Dec 2023 20:35:07 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1rBhYu-00BYVM-Pc for pgsql-hackers@arkaria.postgresql.org; Fri, 08 Dec 2023 20:35:04 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rBhYu-00BYVE-Fj for pgsql-hackers@lists.postgresql.org; Fri, 08 Dec 2023 20:35:04 +0000 Received: from mail-pj1-x1036.google.com ([2607:f8b0:4864:20::1036]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1rBhYs-009Ssy-5X for pgsql-hackers@postgresql.org; Fri, 08 Dec 2023 20:35:03 +0000 Received: by mail-pj1-x1036.google.com with SMTP id 98e67ed59e1d1-2866af9d73bso2126351a91.3 for ; Fri, 08 Dec 2023 12:35:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=j-davis-com.20230601.gappssmtp.com; s=20230601; t=1702067701; x=1702672501; darn=postgresql.org; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:from:to:cc:subject :date:message-id:reply-to; bh=+hPKlTlnGSmNlQJYBnOcGBRumusWp6eoNG+k9i6mB38=; b=k6RWUIAqrcqWWz3aHH38m2jZVGdqq8SKYK/zudRfqR2QZTnapdtFzv4kAgBtEUz3jk yIZZmyCvE2YdedHQteGqRfuQRzp4YMOC+YIIUZzy6EibrmFMX+whsEBOJmtROL+yzbw0 rguACXUG3GVfM+GLG0qTHvCh/yr8aJK9PyS6DJ46kRKZjuSkPdMtEwS2YOKe5ef4r+OO DhNd/aMW+mkSalv4xeSQX1nsbfXBKM17n2c8l5sgi+dwcrHdkVaS7dxwWG4nuzVHvFFY 6SbhyqCwtk+FUi6pZ/SNCl0YP8fvH5HXBDyfAEaTjPDCT2yTMjPI70PEWFnxoCjBG5i9 yHLg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702067701; x=1702672501; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=+hPKlTlnGSmNlQJYBnOcGBRumusWp6eoNG+k9i6mB38=; b=JuzdBLrCcg2+l/Hx8tN/TX0FSUR4iO7ZqPM2NUYcknE5iQRxBy4JTqm57JU0uzebxS TPRY8PRxCKpGRqXYQxqMP/KUciImXKy9eii5vP9bFtJ/AJDWX48vJTVePOlNr6UCjy2P C969q+8Wy/3+EWF9Inv36jVQ/CmswBOcbOydpv4f85q6vsw5NySM1Rd3bmRGKMhSOl87 Koe6w4/FN1G2bbTER/jRuUBRyGVT0waJsuwF2PyVWF/0PxcSeJRClQYZcGp3SJHHQBDE xrkW7uh/rM8vpZJMg+CeGrNLslB5Tv1b7GU+9iFvpLc4/XMac2hwhfpKk03sww61LiC0 youw== X-Gm-Message-State: AOJu0Yws/vPfMiHbZCV59yMfjh4mLGM5u0NXbvF3pzvRmeCR601QGEqK jPmBn2/LnVb/8clRIYh6g/1ynSeQOiJaP1gbpe0= X-Google-Smtp-Source: AGHT+IGIkcTFzeLgS70tJZz8sKLsz4geBnUOjWVP/4WmlUykqQ4ak4VM+XIqw1nEdeprMY5SDmxF6A== X-Received: by 2002:a17:90a:c7cc:b0:285:dbc9:dc18 with SMTP id gf12-20020a17090ac7cc00b00285dbc9dc18mr627647pjb.38.1702067701338; Fri, 08 Dec 2023 12:35:01 -0800 (PST) Received: from jeff-laptop.lan (c-76-102-242-158.hsd1.ca.comcast.net. [76.102.242.158]) by smtp.gmail.com with ESMTPSA id c11-20020a17090a020b00b00286d75e10e4sm4071897pjc.37.2023.12.08.12.35.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Dec 2023 12:35:00 -0800 (PST) Message-ID: <456e1822959638b93af779582cc7c2cbc0a178ca.camel@j-davis.com> Subject: Re: Change GUC hashtable to use simplehash? From: Jeff Davis To: John Naylor Cc: Andres Freund , Tom Lane , Gurjeet Singh , pgsql-hackers@postgresql.org Date: Fri, 08 Dec 2023 12:34:59 -0800 In-Reply-To: References: <20231117232712.mpnzsho7ydssg2oc@awork3.anarazel.de> <7fee9f31c2e82948fa56fe57d68eecb0cce36f10.camel@j-davis.com> <20231118001003.n2d7tvdgeckun2y6@awork3.anarazel.de> <27a7a289d5b8f42e1b1e79b1bcaeef3a40583bd2.camel@j-davis.com> <20231122205030.v6yllmmj6dgxpg5f@awork3.anarazel.de> <2330615.1700686581@sss.pgh.pa.us> <20231122212221.ahmlio2yfx7jla6z@awork3.anarazel.de> <2334462.1700688476@sss.pgh.pa.us> <20231122223432.lywt4yz2bn7tlp27@awork3.anarazel.de> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.44.4-0ubuntu2 MIME-Version: 1.0 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk I committed 867dd2dc87, which means my use case for a fast GUC hash table (quickly setting proconfigs) is now solved. Andres mentioned that it could still be useful to reduce overhead in a few other places: https://postgr.es/m/20231117220830.t6sb7di6h6am4ep5@awork3.anarazel.de How should we evaluate GUC hash table performance optimizations? Just microbenchmarks, or are there end-to-end tests where the costs are showing up? (As I said in another email, I think the hash function APIs justify themselves regardless of improvements to the GUC hash table.) On Wed, 2023-12-06 at 07:39 +0700, John Naylor wrote: > > There's already a patch to use simplehash, and the API is a bit > > cleaner, and there's a minor performance improvement. It seems > > fairly > > non-controversial -- should I just proceed with that patch? >=20 > I won't object if you want to commit that piece now, but I hesitate > to > call it a performance improvement on its own. >=20 > - The runtime measurements I saw reported were well within the noise > level. > - The memory usage starts out better, but with more entries is worse. I suppose I'll wait until there's a reason to commit it, then. Regards, Jeff Davis