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 1qY7nY-000qgV-Bp for pgsql-bugs@arkaria.postgresql.org; Mon, 21 Aug 2023 16:30:36 +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 1qY7nW-008RLP-Rl for pgsql-bugs@arkaria.postgresql.org; Mon, 21 Aug 2023 16:30:34 +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 1qY7nW-008RL8-Ie for pgsql-bugs@lists.postgresql.org; Mon, 21 Aug 2023 16:30:34 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qY7nP-000BPi-D3 for pgsql-bugs@lists.postgresql.org; Mon, 21 Aug 2023 16:30:33 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 37LGUMA02863242; Mon, 21 Aug 2023 12:30:22 -0400 From: Tom Lane To: Andrew Dunstan cc: Alvaro Herrera , Andres Freund , exclusion@gmail.com, pgsql-bugs@lists.postgresql.org Subject: Re: BUG #17994: Invalidating relcache corrupts tupDesc inside ExecEvalFieldStoreDeForm() In-reply-to: <7dc0e894-62ff-381c-b633-fa68250dd586@dunslane.net> References: <20230821123337.fytudn7wtjlgtttk@alvherre.pgsql> <7dc0e894-62ff-381c-b633-fa68250dd586@dunslane.net> Comments: In-reply-to Andrew Dunstan message dated "Mon, 21 Aug 2023 12:04:14 -0400" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <2863240.1692635422.1@sss.pgh.pa.us> Date: Mon, 21 Aug 2023 12:30:22 -0400 Message-ID: <2863241.1692635422@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Andrew Dunstan writes: > On 2023-08-21 Mo 08:33, Alvaro Herrera wrote: >> Hmm ... when exactly do these values get freed if no longer needed? Is >> the theory that leaking them is not relevant? > Not sure I understand "relevant" here. They don't get freed. There will > be at most one entry per row in pg_attribute where atthasmissing is > true. Yeah. My feeling is that as long as we don't make duplicate hashtable entries, there will never be so many entries that it'd be worth the cost and intellectual complexity of trying to clean them up. When and if that theory is disproven, we can think harder; but for now I think this approach is good enough. regards, tom lane