Re: On disable_cost

Robert Haas <robertmhaas@gmail.com>

From: Robert Haas <robertmhaas@gmail.com>
To: Peter Geoghegan <pg@bowt.ie>
Cc: David Rowley <dgrowleyml@gmail.com>, Tom Lane <tgl@sss.pgh.pa.us>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2024-06-28T15:46:24Z
Lists: pgsql-hackers

Attachments

On Wed, Jun 12, 2024 at 11:35 AM Robert Haas <robertmhaas@gmail.com> wrote:
> Well, that didn't generate much discussion, but here I am trying
> again. Here I've got patches 0001 and 0002 from my previous posting;
> I've dropped 0003 and 0004 from the previous set for now so as not to
> distract from the main event, but they may still be a good idea.
> Instead I've got an 0003 and an 0004 that implement the "count of
> disabled nodes" approach that we have discussed previously. This seems
> to work fine, unlike the approaches I tried earlier. I think this is
> the right direction to go, but I'd like to know what concerns people
> might have.

Here is a rebased patch set, where I also fixed pgindent damage and a
couple of small oversights in 0004.

I am hoping to get these committed some time in July. So if somebody
thinks that's too soon or thinks it shouldn't happen at all, please
don't wait too long to let me know about that.

Thanks,

-- 
Robert Haas
EDB: http://www.enterprisedb.com

Commits

  1. Doc: add detail about EXPLAIN's "Disabled" property

  2. Adjust EXPLAIN's output for disabled nodes

  3. Fix order of parameters in a cost_sort call

  4. Show number of disabled nodes in EXPLAIN ANALYZE output.

  5. Treat number of disabled nodes in a path as a separate cost metric.

  6. Remove grotty use of disable_cost for TID scan plans.