Re: Speed up JSON escape processing with SIMD plus other optimisations

From: David Rowley <dgrowleyml(at)gmail(dot)com>
To: Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
Cc: Melih Mutlu <m(dot)melihmutlu(at)gmail(dot)com>, Andrew Dunstan <andrew(at)dunslane(dot)net>, PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Speed up JSON escape processing with SIMD plus other optimisations
Date: 2024-08-05 11:26:23
Message-ID: CAApHDvqnnF=+6muS6EGDe29V2PRm7d_9qrtgMuO7CJvJAuihTQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sun, 4 Aug 2024 at 02:11, David Rowley <dgrowleyml(at)gmail(dot)com> wrote:
> I did some more testing on this on a few different machines; apple M2
> Ultra, AMD 7945HX and with a Raspberry Pi 4.

I did some more testing on this patch today as I wanted to see what
Intel CPUs thought about it. The only modern Intel CPU I have is a
13th-generation laptop CPU. It's an i7-1370P. It's in a laptop with
solid-state cooling. At least, I've never heard a fan running on it.
Watching the clock speed during the test had it jumping around wildly,
so I assume it was thermally throttling.

I've attached the results here anyway. They're very noisy.

I also did a test where I removed all the escaping logic and had the
code copy the source string to the destination without checking for
chars to escape. I wanted to see how much was left performance-wise.
There was only a further 10% increase.

I tidied up the patch a bit more and pushed it.

Thanks for the reviews.

David

Attachment Content-Type Size
image/png 65.4 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tomas Vondra 2024-08-05 11:38:31 Re: scalability bottlenecks with (many) partitions (and more)
Previous Message Marcos Pegoraro 2024-08-05 11:16:23 Re: Detailed release notes