Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dSPJq-0003aY-IP for pgsql-hackers@arkaria.postgresql.org; Tue, 04 Jul 2017 15:00:50 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dSPJq-0006ju-3e for pgsql-hackers@arkaria.postgresql.org; Tue, 04 Jul 2017 15:00:50 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dSPII-0003yP-Sp for pgsql-hackers@postgresql.org; Tue, 04 Jul 2017 14:59:14 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dSPIG-0004hc-5M for pgsql-hackers@postgresql.org; Tue, 04 Jul 2017 14:59:14 +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 v64ExAhf002278; Tue, 4 Jul 2017 10:59:10 -0400 From: Tom Lane To: Ashutosh Bapat cc: pgsql-hackers Subject: Re: WIP patch: distinguish selectivity of < from <= and > from >= In-reply-to: References: <12232.1499140410@sss.pgh.pa.us> Comments: In-reply-to Ashutosh Bapat message dated "Tue, 04 Jul 2017 15:07:36 +0530" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <2276.1499180350.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Tue, 04 Jul 2017 10:59:10 -0400 Message-ID: <2277.1499180350@sss.pgh.pa.us> List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Ashutosh Bapat writes: > On Tue, Jul 4, 2017 at 9:23 AM, Tom Lane wrote: >> regression=3D# explain analyze select * from tenk1 where thousand < 10; >> before: >> Bitmap Heap Scan on tenk1 (cost=3D5.14..241.38 rows=3D110 width=3D244) = (actual time=3D0.121..0.623 rows=3D100 loops=3D1) >> with patch: >> Bitmap Heap Scan on tenk1 (cost=3D5.06..227.42 rows=3D100 width=3D244) = (actual time=3D0.054..0.300 rows=3D100 loops=3D1) > It's expected that the estimates will change with this patch. But I am > wondering why should actual times vary so much. May be that's just > accidental. Butthe actual timings are consistently lower with the > patch except the last one I didn't intend those examples to illustrate anything except row counts, so I didn't worry about making the timings comparable. Some of the examples were probably the first query in a session and so would've faced cache-populating costs the others didn't. Also, the "before" examples were all done on 9.6 not HEAD. regards, tom lane --=20 Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers