model-writtenrun 4944 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Jakub Wartak reported planner endpoint searches taking seconds or even over an hour and supplied Simon Riggs’s cost-limiting patch, a reproducer, and substantially improved planning timings in #1.
- The opening discussion considered observability as well as limits: Alvaro Herrera supported instrumentation in #2, while Robert Haas explained that wait events cannot represent an entire planner phase and advocated bounded probing with a statistics fallback in #3; Tom Lane supported falling back to pg_statistic rather than using a definitely dead value in #4.
- Robert proposed replacing configurable planner costs with a predictable page count in #6, Simon agreed in #7, and Tom argued for 100 pages to preserve useful estimate improvements in #8, leading to Jakub’s revised patch in #10.
- Andres Freund and Justin Pryzby found that the revised patch’s misplaced continue bypassed the intended limit in #11, #12, and #17; Robert also identified the missing last_block update in #21.
- Simon repaired the heap-loop defects and experimentally added limits inside the index machinery in #18, but Andres opposed adding fields and work to common paths in #19, and Tom considered that API change unsafe to backpatch in #20.
- Robert raised the possibility of extremely sparse indexes defeating a heap-only bound in #22; Andres and Tom argued that such indexes would make ordinary lookups slow too and favored fixing the demonstrated heap-fetch problem in #23 and #24, with Robert accepting the narrower scope in #25 and #27.
- Jakub corrected his original 100-page heap-only implementation in #28, while Simon withdrew the experimental index extension in #29 and supplied a documented heap-only revision in #31.
- Tom questioned both the extra interrupt check and counting page transitions instead of tuples in #32; Robert defended allowing more probes when they reuse the same heap page in #33, and Tom retained that heuristic in #34.
- After verifying that existing code already responded promptly to cancellation, Tom removed the redundant interrupt check and improved nearby comments in #35, then committed Simon’s final patch #31 with light cleanup as 9c6ad5eaa9, backpatching it to all supported branches.
- Simon thanked Tom for the streamlined result in the final message #37; the heap-limit fix had landed, while index-internal limits remained deferred pending evidence of a real problem as stated in #26, and Simon’s broader concern about queue-table index scans in #30 remained unresolved.