Re: Why dose the planner select one bad scan plan. - Mailing list pgsql-performance

From 静安寺
Subject Re: Why dose the planner select one bad scan plan.
Date
Msg-id tencent_7D7D734B000FD7EA1CF49B10@qq.com
Whole thread Raw
In response to Why dose the planner select one bad scan plan.  ("静安寺" <asen_huang@qq.com>)
List pgsql-performance

Thanks for your answer! And I am sorry for trading the question as a bug, and send it to 'bugs' mailing-list.

But I doubt your answer. I think the essence of the problem is when the planner selects 'Bitmap Index Scan' and how the planner computes the cost of 'Bitmap Index Scan'.

Tom Lane said “In principle a bitmap index scan should be significantly faster if the index can return the bitmap more or less "natively" rather than having to construct it. My recollection though is that a significant amount of work is needed to make that happen, and that there is no existing patch that tackled the problem. So I'm not sure that this report should be taken as indicating that there's no chance of a SELECT performance improvement. What it does say is that we have to do that work if we want to make bitmap indexes useful.”

Okay, I want to know how the planner computes the cost of constructing bitmap. And when the planner computes the cost of 'Bitmap Index Scan', if it considers the influence of memory cache? As when I do not clear the memory cache, I find the 'Bitmap Index Scan' is real fast than 'Seq Scan'.

Best Regards!

Asen

pgsql-performance by date:

Previous
From: Robert Haas
Date:
Subject: Re: questions regarding shared_buffers behavior
Next
From: "Kyriacos Kyriacou"
Date:
Subject: MVCC performance issue