Re: Plan stability versus near-exact ties in cost estimates

Поиск
Список
Период
Сортировка
От Stephen Frost
Тема Re: Plan stability versus near-exact ties in cost estimates
Дата
Msg-id 20120420153007.GY1267@tamriel.snowman.net
обсуждение исходный текст
Ответ на Plan stability versus near-exact ties in cost estimates  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Plan stability versus near-exact ties in cost estimates  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: Plan stability versus near-exact ties in cost estimates  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
* Tom Lane (tgl@sss.pgh.pa.us) wrote:
> This change would mean that, when two paths have the same pathkeys,
> parameterization, and rowcount, and fuzzily the same cost, that we
> arbitrarily keep the first-submitted one rather than looking at low
> order digits of the costs.

+1 on this approach from me.

> Since the order in which different paths
> are generated is a property of our code and not platform-specific,
> this should eliminate platform dependencies in cases where two paths
> are essentially identical to the cost model.

And the above is why.

> A variant idea would be to replace the exact cost comparison with a
> second round of fuzzy cost comparison, but with a much tighter fuzz
> factor, maybe 1e-6 instead of 0.01.

Not impressed with this idea- the notion that our model is good enough
to produce valid values out to that many digits is, well, unlikely.

I haev to disagree about users noticing this and complaining about it
too, to be honest, that strikes me as very unlikely..  For starters,
they'd have to be debugging the planner sufficiently to see that there
are two nearly-identical plans under consideration and that we picked
one over the other based on which came first..
Thanks,
    Stephen

В списке pgsql-hackers по дате отправления:

Предыдущее
От: "Albe Laurenz"
Дата:
Сообщение: Re: Plan stability versus near-exact ties in cost estimates
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Foreign table scan estimates