Oct 2022

1 commit
Simplify some maths in xlogreader.c
12 Oct 2022Michael Paquiermaster16beta1REL_19_STABLE16beta1REL_18_STABLE16beta1REL_17_STABLE16beta1REL_16_STABLE16beta1
LLM analysis, 100% surelanded as postedfrom patchset #14 of 4 reviewers saw the final version

All three hunks in src/backend/access/transam/xlogreader.c match #1: remove recaddr, remove XLogSegNoOffsetToRecPtr(), and compare xlp_pageaddr with recptr. Michael Paquier confirmed applying the mathematically equivalent simplification #7.

  • Richard Guosaw the final versiontrailerRichard endorsed the patch, checked other XLogSegNoOffsetToRecPtr() callers for the same issue, and examined the historical refactoring #3 #5.
  • Álvaro Herrerasaw the final versiontrailerÁlvaro examined the historical change from global components to a locally reconstructed LSN and explained how the redundant calculation arose #6.
  • Kyotaro Horiguchisaw the final versiontrailerKyotaro confirmed the calculation was unnecessary, connected it to the switch to a caller-supplied recptr, and explicitly said the patch looked good #2.
  • Michael Paquiersaw the final versioncommittercommitted the patch

Credits across 1 commit

Author
Bharath Rupireddy1
Reviewer
Alvaro Herrera1
Kyotaro Horiguchi1
Michael Paquiercommitter1
Richard Guo1
Committer
Michael Paquier1