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 1nQG2d-0004U8-F4 for pgsql-general@arkaria.postgresql.org; Fri, 04 Mar 2022 22:04:51 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nQG2b-00079X-Oz for pgsql-general@arkaria.postgresql.org; Fri, 04 Mar 2022 22:04:49 +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 1nQG1H-0000Qw-E4 for pgsql-general@lists.postgresql.org; Fri, 04 Mar 2022 22:03:27 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nQG1A-0004oB-GW for pgsql-general@lists.postgresql.org; Fri, 04 Mar 2022 22:03:27 +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 224M3EZw3984385; Fri, 4 Mar 2022 17:03:14 -0500 From: Tom Lane To: depesz@depesz.com cc: PostgreSQL General , Andres Freund Subject: Re: Interesting fail when migrating Pg from Ubuntu Bionic to Focal In-reply-to: <20220304204510.GA21340@depesz.com> References: <20220303150428.GA26036@depesz.com> <20220303151156.GB26036@depesz.com> <20220303163921.GA10776@depesz.com> <20220303164401.GA13056@depesz.com> <3969790.1646420992@sss.pgh.pa.us> <20220304204510.GA21340@depesz.com> Comments: In-reply-to hubert depesz lubaczewski message dated "Fri, 04 Mar 2022 21:45:10 +0100" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <3984383.1646431394.1@sss.pgh.pa.us> Date: Fri, 04 Mar 2022 17:03:14 -0500 Message-ID: <3984384.1646431394@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk hubert depesz lubaczewski writes: > On Fri, Mar 04, 2022 at 02:09:52PM -0500, Tom Lane wrote: >> I tried and failed to reproduce this on Fedora 35 on aarch64, >> but that has what I think is a newer LLVM version: > I have suspicion that it also kinda depends on number of rows in there. > When I deleted some schemas, which included some functions, the problem > disappeared. > I wasn't able to pinpoint specific thing, though, and when I called the > pg_proc + pg_roles query for each separate row - it worked flawlessly. Mmm ... it might have just been that the planner chose not to use JIT when it thought there were fewer rows involved. Did you check with EXPLAIN that these cut-down cases still used JIT? regards, tom lane