Re: Speed up COPY FROM text/CSV parsing using SIMD

From: Nathan Bossart <nathandbossart(at)gmail(dot)com>
To: Manni Wood <manni(dot)wood(at)enterprisedb(dot)com>
Cc: Nazir Bilal Yavuz <byavuz81(at)gmail(dot)com>, KAZAR Ayoub <ma_kazar(at)esi(dot)dz>, Neil Conway <neil(dot)conway(at)gmail(dot)com>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Shinya Kato <shinya11(dot)kato(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Speed up COPY FROM text/CSV parsing using SIMD
Date: 2026-03-13 15:00:23
Message-ID: abQmh6W9bq-JBoYt@nathan
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Mar 12, 2026 at 09:39:38PM -0500, Manni Wood wrote:
> I found some time this evening to run some benchmarks using your v15 patch.
> I hope these help.

Thanks!

> x86 NARROW v15 default_toast_compression = lz4
> TXT : 26019.629000 ms 0.347215% improvement
> CSV : 26379.889000 ms 5.526984% improvement
> TXT with 1/3 escapes: 28865.322750 ms -3.147600% regression
> CSV with 1/3 quotes: 33218.293250 ms 3.399359% improvement

> x86 NARROW v15 default_toast_compression = pglz
> TXT : 26438.415000 ms -0.128382% regression
> CSV : 26869.718000 ms 4.509804% improvement
> TXT with 1/3 escapes: 29379.299750 ms -4.610819% regression
> CSV with 1/3 quotes: 33371.390250 ms 3.278908% improvement

Those 3-5% regressions are interesting, but given there are similar
"improvements" for the surrounding cases, I'm going to consider them as
noise for now and proceed with the patch. If folks feel strongly about
digging deeper here, I'm happy to revisit the subject.

--
nathan

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Antonin Houska 2026-03-13 15:01:40 Re: Buffer locking is special (hints, checksums, AIO writes)
Previous Message Fujii Masao 2026-03-13 14:38:57 Re: [PATCH] Docs: clarify default values of EXPLAIN BUFFERS and SERIALIZE