model-writtenrun 7642 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Movead Li proposed counting space discarded by WAL switches as part of XLOG_SWITCH record size in #1; Kyotaro Horiguchi argued that the record itself remained 24 bytes in #2, leading to a separate trailing-bytes display in #3.
- Michael Paquier recommended placing switch-specific descriptions in xlog_desc() and identified segment-boundary and page-header problems in #4 and #7, while Kyotaro Horiguchi explained why the generic record-length helper was the wrong place in #6.
- Andres Freund argued that discarded-space accounting was chiefly useful in statistics output in #8; Kyotaro Horiguchi proposed a separate statistics category and independently supplied a fix for duplicate Transaction/COMMIT rows in #9.
- Movead Li's revision in #10 introduced separate discarded-space statistics, moved the shared calculation into xlogdesc.c, corrected the segment-end calculation, and temporarily incorporated Kyotaro Horiguchi's transaction-statistics fix.
- Kyotaro Horiguchi supplied an alternative using an OTHERS resource-manager entry in #11, but Movead Li declined that design because of naming and resource-manager filtering concerns, retaining the display-side approach and removing the independent transaction fix in #13.
- Kyotaro Horiguchi explained how a switch record can cross either a short or long page header in #14, and Movead Li added short-header handling in #15.
- Shinya Kato's testing exposed duplicate SWITCH_JUNK rows in #16, which Kyotaro Horiguchi traced to a missing resource-manager check in #17; Kato also reviewed formatting and questioned zero-valued fields in #18.
- After a gap, Movead Li fixed the duplicate rows, cleaned up formatting, and displayed dashes for inapplicable counts and FPI sizes in #19; Shinya Kato clarified that the dashes could remain and considered the patch ready for a committer in #22.
- Fujii Masao questioned the use case for discarded-space reporting and prioritized the separate transaction-statistics bug in #23, then revived Kyotaro Horiguchi's original fix with a fuller comment in #24.
- Shinya Kato caught a comment typo in #25, Fujii Masao corrected it in #26, and Kyotaro Horiguchi confirmed that the resulting patch applied cleanly in #27.
- Fujii Masao committed #26 unchanged as 51893c8463, back-patched the transaction-statistics fix to all supported branches, and announced the push in #28; the discarded-space reporting proposal remained uncommitted, with its usefulness still questioned.