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 1kX9f9-0001oj-2w for pgsql-hackers@arkaria.postgresql.org; Mon, 26 Oct 2020 21:04:19 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kX9f5-0008TN-UE for pgsql-hackers@arkaria.postgresql.org; Mon, 26 Oct 2020 21:04:15 +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 1kX9f5-0008TG-NR for pgsql-hackers@lists.postgresql.org; Mon, 26 Oct 2020 21:04:15 +0000 Received: from momjian.us ([72.94.173.45]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kX9f2-0000fO-RO for pgsql-hackers@lists.postgresql.org; Mon, 26 Oct 2020 21:04:14 +0000 Received: from bruce by momjian.us with local (Exim 4.92) (envelope-from ) id 1kX9ez-0004s5-Fa; Mon, 26 Oct 2020 17:04:09 -0400 Date: Mon, 26 Oct 2020 17:04:09 -0400 From: Bruce Momjian To: "Daniel Westermann (DWE)" Cc: Tom Lane , PostgreSQL Hackers Subject: Re: Wrong example in the bloom documentation Message-ID: <20201026210409.GA4951@momjian.us> References: <20201008162310.GA13054@momjian.us> <2622731.1602186212@sss.pgh.pa.us> <20201008195352.GA5062@momjian.us> <20201009150832.GB1459@momjian.us> <20201015235019.GH3797@momjian.us> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Sat, Oct 17, 2020 at 01:50:26PM +0000, Daniel Westermann (DWE) wrote: > On Fri, Oct  9, 2020 at 11:08:32AM -0400, Bruce Momjian wrote: > >This is not applying to PG 12 or earlier because the patch mentions JIT, > >which was only mentioned in the PG bloom docs in PG 13+. > > Does that mean we need separate patches for each release starting with 10? > As I am not frequently writing patches, I would need some help here. I can regenerate the output for older versions using your patch. However, I am confused about the parallelism you are seeing. Your patch shows: Without the two indexes being created, a parallel sequential scan will happen for the query below: ------------------- =# EXPLAIN ANALYZE SELECT * FROM tbloom WHERE i2 = 898732 AND i5 = 123451; QUERY PLAN --------------------------------------------------------------------------------------------------- Seq Scan on tbloom (cost=0.00..214.00 rows=1 width=24) (actual time=2.729..2.731 rows=0 loops=1) Filter: ((i2 = 898732) AND (i5 = 123451)) Rows Removed by Filter: 10000 Planning Time: 0.257 ms Execution Time: 2.764 ms (5 rows) However, I don't see any parallelism in this output. Also, I don't see any parallelism once the indexes are created. What PG version is this? and what config settings did you use? Thanks. -- Bruce Momjian https://momjian.us EnterpriseDB https://enterprisedb.com The usefulness of a cup is in its emptiness, Bruce Lee