Re: Proposal: Improve bitmap costing for lossy pages
Dilip Kumar <dilipbalaut@gmail.com>
From: Dilip Kumar <dilipbalaut@gmail.com>
To: Robert Haas <robertmhaas@gmail.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2017-06-08T14:44:05Z
Lists: pgsql-hackers
On Thu, May 18, 2017 at 8:07 PM, Robert Haas <robertmhaas@gmail.com> wrote: Thanks for the feedback and sorry for the delayed response. > You might need to adjust effective_cache_size. You are right. But, effective_cache_size will have the impact on the number of pages_fetched when it's used as parameterized path (i.e inner side of the nested loop). But for our case where we see the wrong number of pages got estimated (Q10), it was for the non-parameterized path. However, I have also tested with high effective cache size but did not observe any change. > The Mackert and Lohman > formula isn't exactly counting unique pages fetched. Right. >It will count > the same page twice if it thinks the page will be evicted from the > cache after the first fetch and before the second one. That too when loop count > 1. If loop_count =1 then seems like it doesn't consider the effective_cache size. But, actually, multiple tuples can fall into the same page. -- Regards, Dilip Kumar EnterpriseDB: http://www.enterprisedb.com
Commits
-
Account for the effect of lossy pages when costing bitmap scans.
- 5edc63bda68a 11.0 landed