Re: Proposal for enabling auto-vectorization for checksum calculations
Stepan Neretin <slpmcf@gmail.com>
From: Stepan Neretin <slpmcf@gmail.com>
To: Matthew Sterrett <matthewsterrett2@gmail.com>
Cc: pgsql-hackers@lists.postgresql.org, "Devulapalli, Raghuveer" <raghuveer.devulapalli@intel.com>, "Shankaran, Akash" <akash.shankaran@intel.com>
Date: 2025-05-10T11:01:54Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Use AVX2 for calculating page checksums where available
- 5e13b0f24039 19 (unreleased) landed
Attachments
- v2-0001-Enable-autovectorizing-pg_checksum_block.patch (text/x-patch) patch v2-0001
- v2-0002-Fix-compilation-on-systems-where-immintrin.h-is-n.patch (text/x-patch) patch v2-0002
- v2-0003-Benchmark-code-for-postgres-checksums.patch (text/x-patch) patch v2-0003
- v2-0004-fix-bench-compiling.patch (text/x-patch) patch v2-0004
On Sat, May 10, 2025 at 6:01 PM Stepan Neretin <slpmcf@gmail.com> wrote: > > > On Thu, May 8, 2025 at 6:57 AM Matthew Sterrett < > matthewsterrett2@gmail.com> wrote: > >> Hello! I'm still trying to figure out those CI failures, I just wanted >> to update things. >> >> From my testing, with this patch repeatedly disabling/enabling >> checksums is about 12.4% on an approximately 15 GB database. >> >> By the way, I'd love it if anyone could help me figure out how to >> replicate a CI failure in the Cirrus CI. >> I haven't been able to figure out how to test CI runs locally, does >> anyone know a good method to do that? >> >> >> > Hi Matthew, > > Thanks for the patch! > > I ran some timing tests: > > (without avx2) > > Time: 4034.351 ms > SELECT drive_pg_checksum(512); > > (with avx2) > > > Time: 3559.076 ms > SELECT drive_pg_checksum(512); > > Also attached two patches that should fix the CI issues. > > Best, > > Stepan Neretin > > > Oops, forgot to attach patches :) Best, Stepan Neretin