[PATCH v1 1/1] PostgreSQL Patch: AVX-Optimized ASCII Validation
PostgreSQL Patch: AVX-Optimized ASCII Validation
This patch series introduces Intel AVX2 and AVX-512 optimized ASCII validation
for PostgreSQL's UTF-8 processing pipeline, providing significant performance
improvements for text-heavy workloads through vectorized string validation.
Originally implemented by Matthew Sterrett. Submitting for consideration.
Regards,
Eshé N. Pickett (she/her)
Cloud Software Development Engineer
Intel Corp.
Attachments:
postgresql-avx-ascii-validation-submission-v1.patchapplication/octet-stream; name=postgresql-avx-ascii-validation-submission-v1.patchDownload+315-3
On Tue, Nov 4, 2025 at 2:45 PM Pickett, Eshe N <eshe.n.pickett@intel.com> wrote:
This patch series introduces Intel AVX2 and AVX-512 optimized ASCII validation
for PostgreSQL's UTF-8 processing pipeline, providing significant performance
improvements for text-heavy workloads through vectorized string validation.
We already use SSE2/Neon here, and and a good compiler can unroll 2
vectors to work on 32-bytes per loop iteration. Profiles of COPY FROM
should not show ASCII validation to be a large part of the profile
anymore. The bottlenecks are most likely elsewhere. I don't believe
this is worth it.
--
John Naylor
Amazon Web Services