postgresql/src/backend/optimizer/path
Tom Lane 3f56ca1d49 Reduce the rescan cost estimate for Materialize nodes to cpu_operator_cost per
tuple, instead of the former cpu_tuple_cost.  It is sane to charge less than
cpu_tuple_cost because Materialize never does any qual-checking or projection,
so it's got less overhead than most plan node types.  In particular, we want
to have the same charge here as is charged for readout in cost_sort.  That
avoids the problem recently exhibited by Teodor wherein the planner prefers
a useless sort over a materialize step in a context where a lot of rescanning
will happen.  The rescan costs should be just about the same for both node
types, so make their estimates the same.

Not back-patching because all of the current logic for rescan cost estimates
is new in 9.0.  The old handling of rescans is sufficiently not-sane that
changing this in that structure is a bit pointless, and might indeed cause
regressions.
2010-02-19 21:49:10 +00:00
..
Makefile Refactor backend makefiles to remove lots of duplicate code 2008-02-19 10:30:09 +00:00
allpaths.c Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
clausesel.c Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
costsize.c Reduce the rescan cost estimate for Materialize nodes to cpu_operator_cost per 2010-02-19 21:49:10 +00:00
equivclass.c Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
indxpath.c Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
joinpath.c Add support for doing FULL JOIN ON FALSE. While this is really a rather 2010-01-05 23:25:36 +00:00
joinrels.c Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
orindxpath.c Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
pathkeys.c Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
tidpath.c Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00