model-writtenrun 7867 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Peter Geoghegan reported that index deletion could underestimate latestRemovedXid because heap_compute_xid_horizon_for_tuples() followed redirects but omitted HOT-chain members; his instrumentation detected seven discrepancies across 389 calls during a regression run #1.
- Peter explained that heap pruning usually masks the problem, limiting its likely practical impact despite the bug's long history #1.
- Peter supplied a concrete fix that traversed redirects and HOT links in one loop and explained that LP_DEAD heap items can safely be skipped because pruning already generated the necessary conflict horizon #2.
- Peter proposed backpatching only to PostgreSQL 12 and later, where the calculation runs during original execution, avoiding changes to older recovery-time implementations given their risks and the lack of field reports #2.
- Peter committed the fix as 4228817449, adding bounds and transaction-chain validation plus comment improvements to #2, and confirmed it was pushed in the thread's final message #3; no further work remained stated.