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 1oAzr0-0001ex-Tg for pgsql-hackers@arkaria.postgresql.org; Mon, 11 Jul 2022 20:18:03 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oAzqz-0003UU-P6 for pgsql-hackers@arkaria.postgresql.org; Mon, 11 Jul 2022 20:18:01 +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 1oAzqz-0003Sm-Fu for pgsql-hackers@lists.postgresql.org; Mon, 11 Jul 2022 20:18:01 +0000 Received: from wout4-smtp.messagingengine.com ([64.147.123.20]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oAzqx-000197-D2 for pgsql-hackers@postgresql.org; Mon, 11 Jul 2022 20:18:01 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 19B8432008FE; Mon, 11 Jul 2022 16:17:57 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Mon, 11 Jul 2022 16:17:57 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=anarazel.de; h= cc:cc:content-type:date:date:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to; s=fm3; t=1657570676; x=1657657076; bh=RQgardYvn1 7ob/aaP5IQHv3SVrUM2N9SbRGgufI21n4=; b=BQM/eeBuwlkKqLItlQtIUpkJlX +ZECIVtwd9FysIyyrrwSJSizoJW7+PBtXxgRHSXVSRkwRlJwNJ7OueQvRlFy3jdk zsZUqqduo19GUFB/eOkfNlJ3HUPH2wqEofHH+mDBYvOTw3o+tlhbhHMkykibAN1M HiizKxCZIjxaCNu7jzpjv02+tD9FHdXcKfT2UAbvwwVLjIDjqS2gMBeoGNb+3SiZ YbcaFHus9vypH9lXskr60/+JeHQLyydmcZHxdvsCa7GRJRn7YdkQSENBkXD7g3Kd 9VRQhhXqh48f9LQymWJ+TdG9fI6lW7G6bFn/w7JXzvzqw88BXEJEY84hPbtw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:date:date:feedback-id :feedback-id:from:from:in-reply-to:in-reply-to:message-id :mime-version:references:reply-to:sender:subject:subject:to:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; t=1657570676; x=1657657076; bh=RQgardYvn17ob/aaP5IQHv3SVrUM 2N9SbRGgufI21n4=; b=wzrBYlwONYsT6gSrqQPGmLRS9Y8LXjdalIit9glUmgf6 53lAaEIdNNN46ydVas51zN61KBuBX/RquSKCBmg/zi9BH+M6HizG3s7UAKhsttFa nn4ZmD8+bd7pvyITU9+/8qSdt8nPOo+sixPbpT4tvBk7LHfBaG6RnkMcP93HcHBj 8zjSaQTPm2vJ7OquAs5Ag0gXP5oelPztqsA8Is6PVGE+0E9MSuXCkraEItBc4gid V9q5lpNcgr32MLJLGqQRv9aOI+/1UIggHu7/npGj1V0Z57sXxRPSyZx6YrT0xKwC ZhygDOqP3FBq7F5hhtW29mZVY79fZM1W3YtdDm9bNQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrudejfedgudegjecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpeffhffvvefukfhfgggtuggjsehttdertddttddvnecuhfhrohhmpeetnhgu rhgvshcuhfhrvghunhguuceorghnughrvghssegrnhgrrhgriigvlhdruggvqeenucggtf frrghtthgvrhhnpeevffetieduvefhueevjeehgedttddtieevjeeftdffiedttdehudel hfdtudfhveenucffohhmrghinhepshholhhuthhiohhnrdhpmhenucevlhhushhtvghruf hiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrnhgurhgvshesrghnrghrrgii vghlrdguvg X-ME-Proxy: Feedback-ID: id4a34324:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 11 Jul 2022 16:17:56 -0400 (EDT) Date: Mon, 11 Jul 2022 13:17:55 -0700 From: Andres Freund To: Tom Lane Cc: Robert Haas , Peter Eisentraut , David Rowley , pgsql-hackers Subject: Re: automatically generating node support functions Message-ID: <20220711201755.x5hmdailt63z2xo2@awork3.anarazel.de> References: <3302658.1657288366@sss.pgh.pa.us> <3488143.1657310625@sss.pgh.pa.us> <11148777-fbe2-5188-195d-48f5083573c5@enterprisedb.com> <20220710214622.haiektrjzisob6rl@awork3.anarazel.de> <815831.1657494597@sss.pgh.pa.us> <45f508cb-e30b-c252-e081-4548deafa34c@enterprisedb.com> <1116889.1657553859@sss.pgh.pa.us> <1201553.1657562258@sss.pgh.pa.us> <1229446.1657569262@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1229446.1657569262@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi, On 2022-07-11 15:54:22 -0400, Tom Lane wrote: > Robert Haas writes: > > On Mon, Jul 11, 2022 at 1:57 PM Tom Lane wrote: > >> More generally, I'm having second thoughts about the wisdom of > >> auto-generating the NodeTag enum at all. With the current setup, > >> I am absolutely petrified about the risk of silent ABI breakage > >> thanks to the enum order changing. > > > I think this is a valid concern, but having it be automatically > > generated is awfully handy, so I think it would be nice to find some > > way of preserving that. > > Agreed. The fundamental problem seems to be that each build toolchain > has its own source of truth about the file processing order, but we now > see that there had better be only one. We could make the sole source > of truth about that be gen_node_support.pl itself, I think. > > We can't simply move the file list into gen_node_support.pl, because > (a) the build system has to know about the dependencies involved Meson has builtin support for tools like gen_node_support.pl reporting which files they've read and then to use those as dependencies. It'd not be a lot of effort to open-code that with make either. Doesn't look like we have dependency handling in Solution.pm? > (b) gen_node_support.pl wouldn't know what to do in VPATH situations. We could easily add a --include-path argument or such. That'd be trivial to set for all of the build solutions. FWIW, for meson I already needed to add an option to specify the location of output files (since scripts are called from the root of the build directory). Greetings, Andres Freund