model-writtenrun 8800 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Kasahara Tatsuhito reported that PostgreSQL 12 TID scans incremented seq_scan without incrementing seq_tup_read, unlike PostgreSQL 11, and traced the regression to their new use of table_beginscan() in #1.
- Kasahara introduced table_beginscan_tid() without SO_TYPE_SEQSCAN in #2; Fujii Masao questioned the inconsistent counters in #3, while Kyotaro Horiguchi argued for a dedicated TID scan-type flag and treated sample-scan statistics as a separate issue in #4.
- Kasahara added SO_TYPE_TIDSCAN and retained relation-wide predicate locking in #7, believing that preserved historical behavior, but Fujii's questions in #8 and #10 exposed that older TID scans had never entered the relevant scan-initialization path.
- Kasahara demonstrated that the extra relation-wide predicate lock could cause unexpected serialization failures and restored the original patch unchanged in #12, now explicitly fixing both statistics and locking.
- Andres Freund requested isolation coverage for the locking bug while noting the difficulty of reliable statistics tests in #13; Kasahara added isolation tests in #14, then replaced them with Fujii's simpler pg_locks regression check in #16 following #15.
- Masahiko Sawada tested predicate locking, including promotion cases, and identified unnecessary SO_ALLOW_* options in #17; Kasahara consequently restored SO_TYPE_TIDSCAN as the sole scan option in #18, without restoring relation-wide locking.
- Kyotaro identified unused helper arguments in #19, which Kasahara removed in #20; Fujii then found the same inappropriate table_beginscan() use in two currtid functions in #21, and Kasahara included those fixes in #22.
- Kyotaro supported correcting the currtid scan initialization in #23, and Fujii committed #22 as cb5b28613d with only comment editing and a backport to PostgreSQL 12.
- Fujii announced the push in #24, and Kasahara acknowledged it in #25, closing the thread with the complete TID-scan fix landed and no remaining patch under review.