Re: injection_points: Switch wait/wakeup to use atomics rather than latches

From: Andrey Borodin <x4mmm(at)yandex-team(dot)ru>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Postgres hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
Subject: Re: injection_points: Switch wait/wakeup to use atomics rather than latches
Date: 2026-06-02 18:46:52
Message-ID: 688F6266-3901-4C84-B27A-AF5904801A3A@yandex-team.ru
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> On 2 Jun 2026, at 10:27, Michael Paquier <michael(at)paquier(dot)xyz> wrote:
>
> Rewording my question a bit: did you consider some options regarding
> what an equivalent of a wait event lookup should look like when we
> don't have a PGPROC? My idea of printing a LOG and do a server log
> lookup would work, just asking if others have better ideas than the
> only one I got.

For tests without PGPROC we can mmap() inj_state to a fixed file in
PGDATA/injection_points.shm. TAP can poll name[] to detect that a wait
point was reached and bump wait_counts[] to wake.

Best regards, Andrey Borodin.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2026-06-02 18:57:14 Re: Broken build on macOS (Universal / Intel): cpuid instruction not available
Previous Message Andres Freund 2026-06-02 18:43:31 Re: Heads Up: cirrus-ci is shutting down June 1st