Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fBQi9-0007VX-Tr for pgsql-hackers@arkaria.postgresql.org; Wed, 25 Apr 2018 20:08:18 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1fBQi8-0004ZQ-Sm for pgsql-hackers@arkaria.postgresql.org; Wed, 25 Apr 2018 20:08:16 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fBQi8-0004ZG-I5 for pgsql-hackers@lists.postgresql.org; Wed, 25 Apr 2018 20:08:16 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fBQi3-0004J5-3g for pgsql-hackers@postgresql.org; Wed, 25 Apr 2018 20:08:15 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id w3PK83O3019974; Wed, 25 Apr 2018 16:08:03 -0400 From: Tom Lane To: John Naylor cc: Stas Kelvich , andreas@proxel.se, Andrew Dunstan , PostgreSQL Hackers , David Fetter Subject: Re: unused_oids script is broken with bsd sed In-reply-to: References: <37D774E4-FE1F-437E-B3D2-593F314B7505@postgrespro.ru> <34a54c54-9132-1254-2bc3-d3489fb79728@2ndQuadrant.com> <4473.1524665917@sss.pgh.pa.us> <4DE444D1-DDE9-460F-AC2F-EB1B73D94A2D@postgrespro.ru> <26728623-7783-4103-9BED-08D443C1729F@postgrespro.ru> Comments: In-reply-to John Naylor message dated "Thu, 26 Apr 2018 02:09:47 +0700" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <19972.1524686883.1@sss.pgh.pa.us> Date: Wed, 25 Apr 2018 16:08:03 -0400 Message-ID: <19973.1524686883@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk John Naylor writes: > Just after you posted, I sent a patch that tweaks the API of > Catalog.pm for toast and index oids. If you use that API in your > patch, you can get rid of the extra bookkeeping you added for those > oids. I've adjusted these two patches to play together, and pushed them. > The original scripts skipped the relation and rowtype oids for > bootstrap catalogs. You've replaced that with two data-level tests for > pg_class plus pg_type composite types. I think the original test was a > bit cleaner in this regard. Yeah, I thought so too. Changed. > For those following along, these scripts still assume we're in the > catalog directory. I can hack on that part tomorrow if no one else > has. I didn't touch this point. I notice that duplicate_oids is now a good factor of 10 slower than it was before (~0.04 sec to ~0.4 sec, on my machine). While this doesn't seem like a problem for manual use, it seems annoying as part of the standard build process, especially on slower buildfarm critters. I think we should do what you said upthread and teach genbki.pl to complain about duplicate oids, so that we can remove duplicate_oids from the build process. I went ahead and pushed things as-is so we can confirm that duplicate_oids has no portability issues that the buildfarm could find. But let's try to get the build process change in place after a day or so. regards, tom lane