Jan 2024

1 commit
Add EXPLAIN (MEMORY) to report planner memory consumption
29 Jan 2024Alvaro Herreramaster17beta1REL_19_STABLE17beta1REL_18_STABLE17beta1REL_17_STABLE17beta1
LLM analysis, 100% suremodified before commitmoderate changesfrom patchset #401 of 5 reviewers saw the final version

The commit retains the MEMORY option, dedicated planner context, and MemoryContextMemConsumed() implementation from #40. Alvaro rewrites explain.c grouping around a new peek_buffer_usage(), adds an EXPLAIN EXECUTE regression test, and makes naming, comment, and formatting edits, explicitly described in #41.

  • David Rowleysaw an earlier versiontrailerQuestioned the original metric and advocated tracking allocated memory in #4 and #9, leading to the dedicated-context implementation before subsequent accounting and output rewrites.
  • Andrey Lepikhovsaw an earlier versiontrailerReported passing tests in #7, used the expanded patch to find excessive planner memory use in #15, and supported disabling reporting by default in #23, before later implementation rewrites.
  • Jian Hesaw an earlier versiontrailerTested prepared-statement reporting in #13 and questioned the memory-definition documentation in #25, before the accounting simplification and output-grouping changes.
  • Andy Fansaw an earlier versiontrailerReviewed the first component's rationale and terminology in #16 and endorsed it in #18, explicitly giving little attention to the allocated-memory and dedicated-context components.
  • Alvaro Herrerasaw the final versioncommittercommitted the patch

Credits across 1 commit

Author
Ashutosh Bapat1
Reviewer
Alvaro Herreracommitter1
Andrei Lepikhov1
Andy Fan1
David Rowley1
jian he1
Committer
Alvaro Herrera1