model-writtenrun 7046 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
Feb - Apr 2025 · 16 entries
- Raghuveer Devulapalli proposed processing CRC32C input in 64-byte blocks using PCLMUL, with a Chromium-derived algorithm and new regression tests, in #1.
- John Naylor's benchmarks exposed short-input regressions and an inefficient finalization step, so #2 added a benchmark module and a shorter corsix-generated implementation; Raghuveer corrected the original benchmark baseline in #3.
- Raghuveer added the missing PCLMUL runtime check in #5, and John reorganized the generated implementation in #6, removed its single-block loop, selected a conservative 128-byte threshold, and requested tests in the existing strings suite.
- Raghuveer proposed always using runtime selection in #7, but Nathan Bossart warned about function-pointer overhead for existing SSE4.2-targeted builds in #8 and #10.
- John experimented with an unrolled tail in #14, then introduced capability-bit branching and explicit CPU initialization in #15 to preserve short-input performance while allowing PCLMUL selection.
- After CI fixes in #17, Raghuveer encouraged centralized CPU detection in #19, while subsequent discussion exposed portability and initialization difficulties for frontend programs and MSVC in #20 and #23.
- John reorganized detection into pg_cpucap files in #25, and Raghuveer expanded that work into centralized CRC and popcount feature detection in #26, correcting CPUID and ZMM checks after review in #28.
- The centralized design raised disagreements over architectural abstraction and additional dispatch calls in #29 and #30, so John deferred that overhaul and restored function-pointer selection with constant-input inlining in #31.
- John also reported David Rowley's off-list measurements in #31: the 128-bit algorithm regressed on Zen 2 for inputs up to roughly 256 bytes, motivating a single-accumulator AVX-512 alternative.
- Nathan reviewed the revised dispatch in #32, while Raghuveer questioned compiler unrolling in #33; John demonstrated the desired three CRC instructions for the WAL header in #34.
- John made the benchmark more sensitive to dependent-call latency and restricted inlining to constant input in #39, then simplified the inline implementation into compact loops in pg_crc32c.h in #40.
- John introduced the single-accumulator AVX-512 implementation and reused build-support work by Raghuveer and Paul Amonson from thread #49559 in #42; he confirmed in #44 that the older 128-bit variant was omitted because of its Zen 2 regressions.
- Raghuveer reported substantial Tiger Lake speedups in #45, and John consolidated the production patches, limited inlining to inputs below 32 bytes, and strengthened compiler probes against constant folding in #47 and #48.
- After Raghuveer approved the series in #49, e2809e3a10 landed the unchanged inlining component of #47, leaving AVX-512 integration for the remainder posted in #50.
- Nathan reviewed that remainder and found an Autoconf macro-name mismatch, then successfully tested the corrected code on AVX-512 hardware in #54; John fixed the macro and adjusted comments before landing 3c6e8c1238, as announced in #55.
- The benchmark extension and CI-only diagnostic patches were development aids and did not land with the production changes, while centralized SIMD detection remained future work discussed in #49 and #50.
Jun - Jul 2025 · 7 entries
- In June, Andy Fan reported initdb control-file checksum failures and bisected them to the AVX-512 change in #56; Nathan identified the clang -O0 configuration and connected it to an existing report in #58.
- Andy confirmed in #61 that the workaround posted as #692739 in thread #73184 restored normal operation; John announced its landing as f83f14881c in #62, disabling AVX-512 selection for clang without optimization.
- Raghuveer supplied a minimal reproducer in #63, Nathan isolated the suspicious vector cast in #64, and Raghuveer explained in #65 that the cast left the upper 384 bits undefined and required explicit zero extension.
- Raghuveer attached the correction in #68, and John combined it with removal of the temporary workaround in #69; Nathan and Raghuveer approved it in #70 and #71, and Andy and Soumyadeep Chakraborty verified it in #72 and #73.
- The combined patch landed unchanged as 43da394304, but Tom Lane immediately reported that GCC 8.5 lacked the newly required intrinsic and could no longer build the code in #75.
- Tom and Nathan agreed to disable the AVX-512 implementation when the compiler lacked that intrinsic, and Tom's expanded compiler probes in #79 received Nathan's approval in #80 before landing unchanged as ccd5bc93fd.
- By the final message, the performance changes and both corrective rounds had landed; Soumyadeep's #82 supplied a generated-code explanation for why optimized clang builds had masked the undefined upper bits, with no further patch pending in this thread.