Re: autovectorize page checksum code included elsewhere

From: John Naylor <johncnaylorls(at)gmail(dot)com>
To: Nathan Bossart <nathandbossart(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: autovectorize page checksum code included elsewhere
Date: 2023-11-22 09:44:03
Message-ID: CANWCAZZ9Sb-cW4GWBhGGH7v-40s6gDK+15t1sVfS__VSCvhe8Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Nov 7, 2023 at 9:47 AM Nathan Bossart <nathandbossart(at)gmail(dot)com> wrote:
>
> Presently, we ask compilers to autovectorize checksum.c and numeric.c. The
> page checksum code actually lives in checksum_impl.h, and checksum.c just
> includes it. But checksum_impl.h is also used in pg_upgrade/file.c and
> pg_checksums.c, and since we don't ask compilers to autovectorize those
> files, the page checksum code may remain un-vectorized.

Poking in those files a bit, I also see references to building with
SSE 4.1. Maybe that's an avenue that we should pursue? (an indirect
function call is surely worth it for page-sized data)

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Cédric Villemain 2023-11-22 10:04:59 Re: Extension Enhancement: Buffer Invalidation in pg_buffercache
Previous Message Alvaro Herrera 2023-11-22 09:36:53 Re: Lockless exit path for ReplicationOriginExitCleanup