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 1k1OVD-000699-7s for pgsql-committers@arkaria.postgresql.org; Fri, 31 Jul 2020 06:26:47 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1k1OVB-0005CN-DC for pgsql-committers@arkaria.postgresql.org; Fri, 31 Jul 2020 06:26:45 +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 1k1OVB-0005CG-7I for pgsql-committers@lists.postgresql.org; Fri, 31 Jul 2020 06:26:45 +0000 Received: from [66.111.4.25] (helo=out1-smtp.messagingengine.com) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k1OV7-00045a-PL for pgsql-committers@lists.postgresql.org; Fri, 31 Jul 2020 06:26:44 +0000 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 6DC105C0132; Fri, 31 Jul 2020 02:26:30 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute3.internal (MEProxy); Fri, 31 Jul 2020 02:26:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm2; bh=1a850nO8h//1cJyuA+QgW2RLfIw VUEXw2g4iko8RYiQ=; b=dCl+nIPb7OldGAl58WY+URO8FRSLSmv7Fb6Ai5Aar4i Q3d8+nEv4QrW84GseG8KgyN+Qwug0plP9nxwcU8MbYGBQXGvl+xuj7gI4OZyZmMh ROp6NBR62cjw9+Ek200eP1mr8JTkuYynTW4bndUYZDuknGg9EdXSxvlz0uTKnsn1 dCznm8OiHfkU8gYytphN4sSDEu07XSxyZxsHs6JZfZ69baGbQfsOZIovrl2Tpdzw dwR3ZKI9ydoGBBpeL34lw1I13iOjRF4AEScESRzAdpi/qcrKfdm+9alGgOsdiVf/ gV9WML8u5iNC+wlDs7bmohhL3r7jLYfkDnTDMWZM10A== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=1a850n O8h//1cJyuA+QgW2RLfIwVUEXw2g4iko8RYiQ=; b=Y5rLge8/1I1C4OACzszYt6 NKEGSoNSbP0xL2ATBcSS6NOfmBdyrN0unaPwnXTsliXYOdZTPKtOYd1ehZdjUQ89 xwXrIB+X6N+lUubcGCA7goXLgzBWdAHg2VcJaBUOHbDqfQ0S+lgwAykg0I/zeESA 5g41KiLuek3ii8AmpLnoMxABFkMzLTOKtAFhIo3N3guSA55bF9c8lHAuxNj8Yc4Z QgSiTC+dwp7v/YT+jlhELifjB7WZTz8QQuVnAJILSH59z22QDdbq+Rs7pZqFNmlO b/LQ7vBmyAGQyweFkZFzBaYNcRzQbQCIW4lrBKMHmdjcs6diSu47xIYzzd/tWfbA == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduiedrieejgddutdehucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne gfrhhlucfvnfffucdlfeehmdenucfjughrpeffhffvuffkfhggtggujgesghdtreertddt vdenucfhrhhomhepofhitghhrggvlhcurfgrqhhuihgvrhcuoehmihgthhgrvghlsehprg hquhhivghrrdighiiiqeenucggtffrrghtthgvrhhnpeffudeffeelgffhkedukeekvedv udfgieetkeekudelfeevhffhffdtudffieeutdenucffohhmrghinhepphhoshhtghhrvg hsqhhlrdhorhhgnecukfhppeduuddurddutddvrddukedtrddukeehnecuvehluhhsthgv rhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepmhhitghhrggvlhesphgrqh huihgvrhdrgiihii X-ME-Proxy: Received: from paquier.xyz (ee0822lan1.rev.em-net.ne.jp [111.102.180.185]) by mail.messagingengine.com (Postfix) with ESMTPA id ED76130600B2; Fri, 31 Jul 2020 02:26:28 -0400 (EDT) Date: Fri, 31 Jul 2020 15:26:26 +0900 From: Michael Paquier To: Thomas Munro Cc: pgsql-committers@lists.postgresql.org Subject: Re: pgsql: Preallocate some DSM space at startup. Message-ID: <20200731062626.GD3317@paquier.xyz> References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="cYtjc4pxslFTELvY" Content-Disposition: inline In-Reply-To: X-Host-Lookup-Failed: Reverse DNS lookup failed for 66.111.4.25 (deferred) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --cYtjc4pxslFTELvY Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Thomas, On Fri, Jul 31, 2020 at 05:54:45AM +0000, Thomas Munro wrote: > Preallocate some DSM space at startup. >=20 > Create an optional region in the main shared memory segment that can be > used to acquire and release "fast" DSM segments, and can benefit from > huge pages allocated at cluster startup time, if configured. Fall back > to the existing mechanisms when that space is full. The size is > controlled by a new GUC min_dynamic_shared_memory, defaulting to 0. >=20 > Main region DSM segments initially contain whatever garbage the memory > held last time they were used, rather than zeroes. That change revealed > that DSA areas failed to initialize themselves correctly in memory that > wasn't zeroed first, so fix that problem. longfin is complaning on this one: https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=3Dlongfin&dt=3D2020= -07-31%2005%3A59%3A08 guc.c:2241:38: error: implicit conversion from 'unsigned long' to 'int' changes value from 17592186044415 to -1 [-Werror,-Wconstant-conversion] 0, 0, Min(INT_MAX, SIZE_MAX / 1024 / 1024), ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~ =2E./../../../src/include/c.h:927:40: note: expanded from macro 'Min' #define Min(x, y) ((x) < (y) ? (x) : (y)) ^ 1 error generated. -- Michael --cYtjc4pxslFTELvY Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAl8juZIACgkQnvQgOdby QH0TLhAAiEb6z0aJLmhAV/jlsSErpvP6HFMesUMZxDylmBwyntTGKuUdOCnhb4Ri JfHrIwdcCYVPvE3sDWUIrzxkgk1qsD4EaQaPF0KxrtFOfcv8Wh7flVTl02xJX6/Z URnjyuu1HdF+HMq7SY7QRGxEzJlVJANDJLP3smN+KxatMYQPS0VnIxTW/tRWCtJd /kSIL2qy0Z7qXxHgF5ZhJFuUgbahP75d9UaM1YXyKVir5ROsq4zxERe1TLDuJkq/ +BQwCOWBLexzSZHfNMKC9A7W7VFNzh/f0aq51kN1FP8O2M+jVkDzQ55f3AcPrfRj marOkUi+ppWIcE+Syd5f2xgnYbDBwYVsx6AKD/mNapWFDsEelR+ZhhzGui05FtEo cNUM+We5NvqgCFrFGWO973QO+mcNSWW0goo3LfjeNLPJf6rOTvOUos0dmtdti2td kMIymSxm+Ta481Uoux4DUOAExCvzJJblYBJXK+KSaXZHSeB/Usxc3qUHUQfRYYYy O6CUp94oSSJ9JHN6g7qiGPHdAJUKBWSsNjgKNHrSo2FP8GRqlFCNMregQfZx9CTq T4W/Wa7jq/xOASAT8HBYrRIw183OENfFAr8GnP7mnB39+NUTHI+JqPdBgzs0ncnM WZrN5euoAaaD/qEX+9zlIAclaxXzqcA33g6OOOrnp0IPdFxb8Cw= =1zcY -----END PGP SIGNATURE----- --cYtjc4pxslFTELvY--