model-writtenrun 3000 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Thomas Munro proposed batching latch wakeups until after releasing internal locks, explaining that heavyweight-lock waiters otherwise wake only to contend on the same partition lock; his initial sketches also covered condition variables, synchronous replication, and SERIALIZABLE DEFERRABLE wakeups #1.
- Thomas replaced the fixed latch buffer with a growable group that falls back to flushing on allocation failure, and proposed allowing MCXT_ALLOC_NO_OOM allocations inside critical sections, while acknowledging that the current callers did not require that exception #2.
- After the series stopped applying, Thomas rebased it and dropped the condition-variable patch for the time being; his original proposal had already identified that implementation as needing further work #1 #4.
- Peter Eisentraut questioned whether allocation errors other than out-of-memory could still cause panics, leaving the critical-section assumptions unresolved #5; Aleksander Alekseev subsequently clarified the latch-array mutation contract, rebased the series, and reported successful installcheck-world runs on macOS x64, Linux x64, and Linux RISC-V #6.
- Heikki Linnakangas argued that eliminating ProcSleep()'s partition-lock reacquisition should be split from latch batching, endorsed its safety, and considered explicit interrupt holds to document the assumptions #7.
- After a long gap and substantial conflicts, Heikki rewrote that optimization as separate JoinWaitQueue() and ProcSleep() functions, keeping partition-lock acquisition and release in LockAcquireExtended(); he supplied seven preparatory patches and decided explicit interrupt holds were unnecessary because the relevant sections contain no CHECK_FOR_INTERRUPTS() calls #8.
- Maxim Orlov reviewed the eight-patch series positively, rebased it, and fixed a non-assert build warning by marking partitionLock as assertion-only #9.
- Heikki committed the LockReleaseAll() comment correction unchanged as 1fe0466cf2, the heldLocks relocation with a later PGPROC assignment as 0464f25b6a, and the TRACE-call relocation unchanged as 6ae0897e42, all from Maxim's submission #9 #10.
- Heikki combined the remaining five patches from #9 into 3c0fd64fec, with further control-flow and cleanup edits; he explained that removing LOCK_PRINT() was necessary for the new locking arrangement rather than an existing bugfix, and left Thomas's remaining SetLatches work needing review #10.
- Alexander Lakhin later supplied a lock-timeout workload that crashed in GrantLockLocal() during abort processing and bisected the regression to 3c0fd64fec #11.
- Using Alexander's reproducer, Heikki determined that repeated LockErrorCleanup() calls could reuse a released LOCALLOCK because the refactoring had removed the awaited-lock reset, and restored that reset through ResetAwaitedLock() in 51a0382e8d #12.
- The thread ends with the lock-wakeup refactoring committed and its reported crash fixed, while the broader SetLatches batching work remains at the previously stated needs-review stage #10 #12.