diff options
| author | Robert Haas | 2026-09-17 13:28:31 +0000 |
|---|---|---|
| committer | Robert Haas | 2026-09-17 13:28:31 +0000 |
| commit | c9c660e6ae03027615adff90cf4b26da5f8f97c1 (patch) | |
| tree | f745ebd370507340e26a52ff9c411b88b5487941 /src/tools/msvc_gendef.pl | |
| parent | bca67e5a33b07180c2f1703faf4443f2a1b92134 (diff) | |
Change GEQO fitness comparisons to consider disabled_nodes.
Prior to v18, the total cost of a plan was just one number, a
floating-point value. Commit e22253467942fdb100087787c3e1e3a8620c54b2
introduced a second component, the number of disabled_nodes at or
below that level of the plan tree. Unfortunately, I (rhaas) failed
to realize that GEQO extracts the cost from each candidate plan and
compares it directly as a measure of fitness.
This means that, at least in principle, it's possible for GEQO to
prefer a plan with more disabled_nodes and lower cost over one with
fewer disabled_nodes and higher cost, which is incorrect. It may be
possible for that to become a practical issue in v18, but it's much
more likely to become an issue in v19 due to pg_plan_advice. Hence,
since the straightforward fix breaks ABI compatibility, back-patch
only to v19.
Backpatch-through: 19
Discussion: https://postgr.es/m/CA+TgmoYmXy-jiP5qDhqNEiYFEBzQsArO6O2d9E8szNZqi1bePQ@mail.gmail.com
Diffstat (limited to 'src/tools/msvc_gendef.pl')
0 files changed, 0 insertions, 0 deletions
