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 1lm4O0-0004sl-H3 for pgsql-hackers@arkaria.postgresql.org; Thu, 27 May 2021 01:00:32 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lm4Nz-0004N3-4K for pgsql-hackers@arkaria.postgresql.org; Thu, 27 May 2021 01:00:31 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lm4Nx-0004Mu-SQ for pgsql-hackers@lists.postgresql.org; Thu, 27 May 2021 01:00:30 +0000 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lm4Nr-0004pO-Cn for pgsql-hackers@postgresql.org; Thu, 27 May 2021 01:00:28 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 79FC95C0100; Wed, 26 May 2021 21:00:22 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Wed, 26 May 2021 21:00:22 -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=fm1; bh=qj6F6qQSFkTusWTnoI8QivOtKHL 0ZxNiOEGR2BkIugc=; b=ovB9V2G3wclM4Um5fV3J11BPHk8iskEQXG0UXGCn9ay NoB9dDBV/qq82ySBqGrVP5D0fXuQDW1sP/7805OhCes5qAmBac1srnaXBOtatBMC j/pjY9IvZ8nt1t2ZCMaalwIuaC2llDnAtccaSRul3bRQip+ZmzRuA4u4Z6rEAQQ3 +qbaKcHC9XwXGT3PkVF1Kw0xh1pmB7a/PuIaUDwfv2Ofze0y4COkV/7lbN8pxQRj c2GoVgDbQ4cB2wDUyE/2DOjRC2FNawGfFMKnpMn+WOksGV0rZrZ7yRR29vqck1wW O71/MViYUvxB/1+pkC1MjU0tYJR4RZ0xYRLAdm7SVrQ== 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=fm2; bh=qj6F6q QSFkTusWTnoI8QivOtKHL0ZxNiOEGR2BkIugc=; b=eb8uQ5bRLTsWOK2XG0vjjw 30S2P11NkVBaH0TynSz9z/Ja0QIhaYrLHMwHcG22DSApF/ouLvGC6EVyugDtRDzz fzby9ypW/5khSSb3ODlSzzslyKuSMDj2Ui/z2B1eN5jcKuzIh7HcwSrr5cjM2e21 CxLIbXdGtAAvpVKgX5tfYxApTHqIa6PNfPYb3N7h2jI9/OX512iyeznV1WD5oT0C I0v0STCBKraAJvtkAxoZYq4c/nZJVF4XjJGUKXh1cvxuy3PzdGbyYiiQsdW9/T9l aPLPSPDHsN0jfuTh0ZUs0wDm3xOK8caG4Egz2SGtofBE8x9iV/68BvHLJmcjxRhQ == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrvdekgedgfeelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne gfrhhlucfvnfffucdlfeehmdenucfjughrpeffhffvuffkfhggtggujgesghdtreertddt vdenucfhrhhomhepofhitghhrggvlhcurfgrqhhuihgvrhcuoehmihgthhgrvghlsehprg hquhhivghrrdighiiiqeenucggtffrrghtthgvrhhnpedvgeduuefhtdeuleettdevjeeh heeiveeuieegleetgeeljeelieeuieehgeevhfenucfkphepudduuddruddtvddrudektd drudekheenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhm pehmihgthhgrvghlsehprghquhhivghrrdighiii X-ME-Proxy: Received: from paquier.xyz (ee0822lan1.rev.em-net.ne.jp [111.102.180.185]) by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 26 May 2021 21:00:19 -0400 (EDT) Date: Thu, 27 May 2021 10:00:16 +0900 From: Michael Paquier To: Tom Lane Cc: Andres Freund , Dilip Kumar , pgsql-hackers , Robert Haas Subject: Re: Move pg_attribute.attcompression to earlier in struct for reduced size? Message-ID: References: <3962395.1621609263@sss.pgh.pa.us> <20210521211929.pcehg6f23icwstdb@alap3.anarazel.de> <20210527003144.xxqppojoiwurc2iz@alap3.anarazel.de> <1677691.1622075746@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="wnpkObnFQS+aRQMC" Content-Disposition: inline In-Reply-To: <1677691.1622075746@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --wnpkObnFQS+aRQMC Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, May 26, 2021 at 08:35:46PM -0400, Tom Lane wrote: > Andres Freund writes: > > The efficiency bit is probably going to be swamped by the addition of > > the compression handling, given the amount of additional work we're now > > doing in in reform_and_rewrite_tuple(). >=20 > Only if the user has explicitly requested a change of compression, no? Andres' point is that we'd still initialize and run through values_free at the end of reform_and_rewrite_tuple() for each tuple even if there no need to do so. Well, we could control the initialization and the free() checks at the end of the routine if we know that there has been at least one detoasted value, at the expense of making the code a bit less clear, of course. -- Michael --wnpkObnFQS+aRQMC Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmCu7yAACgkQnvQgOdby QH3Y4Q/9FX1i49AlZPUY4lTsUCGHVSBRDUscR6Bz/29RYazc0kfxRYA0MDa2tSql e5XKHFsjstSTzYKaC1MyV9wdknKhekYlTGlErR9bEjOfWFb4FErA1AtIzLYLbyjM 5NXCEJNSlTVLEZel3OBdPivqo/tXY0GFrwWwVDNpUkl8DYZWrrSadilz2WoPvl6r TmkGsYN+oyihte7zNZ68QTsBOnKUNbVCFhrWm9p6yvS5Cldh6B8Ev83Dsbko1zKr BcPlfkHhE1NMOa+rybT6CkeAew9pAFca8KGA3EyYK3JH+InhOjHtJHtR78ler5hU o6IDXIjO/BhleVjK/5ITJ+l3FqutkKFcgeJzEUfH5gk6Yqnj4sNHWKWzBhFFGbz+ tgOmXOVcQoV1d5XcqulGcRYqYlw8JCcabfoYnQnlAzuKxAS3bYArSNLb6YQPkbjD ytTRwKTyWb+vzozIf0sYwRs8QGqyjeOXr6jtC5IumfofS0ZP1GGyV9fbJ2zHQ4Mj D8W7EOCfLyTDUjiK8cFbY3561ucNnUS1mt5yGXva73PmYMCMNGSi94WqGAZzR2r3 B6OEBFopYV+NUw+OEVPYio6eeYiCDDF0FV8dt+xIVUtvzBR7QvgYZnbGGKWvuh1j Br2K+kcG5bRaoZC/A04WCq9MYmgfQwtwvEH0S29/14hH0OYBtsg= =XiNH -----END PGP SIGNATURE----- --wnpkObnFQS+aRQMC--