X-Original-To: pgsql-performance-postgresql.org@postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id 9CFDE9FA5C9 for ; Wed, 28 Jun 2006 12:08:31 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 77309-10 for ; Wed, 28 Jun 2006 12:08:19 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from noel.decibel.org (noel.decibel.org [67.100.216.10]) by postgresql.org (Postfix) with ESMTP id 8CB5A9FA5CD for ; Wed, 28 Jun 2006 12:08:17 -0300 (ADT) Received: by noel.decibel.org (Postfix, from userid 1001) id B6E9B56488; Wed, 28 Jun 2006 10:08:16 -0500 (CDT) Received: (hashcash-sendmail, from uid 1001); Wed, 28 Jun 2006 10:08:15 -0500 Date: Wed, 28 Jun 2006 10:08:15 -0500 From: "Jim C. Nasby" To: Tom Lane Cc: Andrew Sagulin , pgsql-performance@postgresql.org Subject: Re: Large index scan perfomance and indexCorrelation (PG 8.1.4 Win32) Message-ID: <20060628150815.GT44573@pervasive.com> References: <463024718.20060627161408@yandex.ru> <1151445858.2479.170.camel@localhost.localdomain> <624168784.20060628133355@yandex.ru> <15072.1151505444@sss.pgh.pa.us> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <15072.1151505444@sss.pgh.pa.us> X-Operating-System: FreeBSD 6.0-RELEASE-p4 amd64 X-Distributed: Join the Effort! http://www.distributed.net User-Agent: Mutt/1.5.11 X-Hashcash: 1:20:060628:tgl@sss.pgh.pa.us::aSUN4H66MQxuIapM:00000000000000000000 0000000000000000000000003JZ3 X-Hashcash: 1:20:060628:andrews42@yandex.ru::+zD9TjbOqKUfBKxe:000000000000000000 00000000000000000000000092GV X-Hashcash: 1:20:060628:pgsql-performance@postgresql.org::2W7lm9Qv5ZmQ4ZcA:00000 00000000000000000000000019wo X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200606/486 X-Sequence-Number: 19843 On Wed, Jun 28, 2006 at 10:37:24AM -0400, Tom Lane wrote: > with a plain indexscan. What you need to do is compare the two > functions and figure out what part of the cost models are out of line > with reality. I tend to agree with the upthread comment that the > nonlinear interpolation between min_IO_cost and max_IO_cost is suspect If you're going to make such a comparison (which is badly needed, imho), http://stats.distributed.net/~decibel/ might be of use to you. It shows that the nonlinear interpolation between the correlated and uncorrelated index scans is way off base, at least for this example. BTW, you'll have a hard time convincing people to increase the cost estimates of index scans, because experience has shown that they're already too high (all the discussions about dropping random_page_cost, for example). -- Jim C. Nasby, Sr. Engineering Consultant jnasby@pervasive.com Pervasive Software http://pervasive.com work: 512-231-6117 vcard: http://jim.nasby.net/pervasive.vcf cell: 512-569-9461