pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andres Freund <andres@anarazel.de>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: lwlock: Remove support for disowned lwlwocks
Date: Thu, 15 Jan 2026 19:59:29 +0000
Message-ID: <E1vgTVA-000fhX-39@gemulon.postgresql.org> (raw)

lwlock: Remove support for disowned lwlwocks

This reverts commit f8d7f29b3e81db59b95e4b5baaa6943178c89fd8, plus parts of
subsequent commits fixing a typo in a parameter name.

Support for disowned lwlocks was added for the benefit of AIO, to be able to
have content locks "owned" by the AIO subsystem. But as of commit fcb9c977aa5,
content locks do not use lwlocks anymore.

It does not seem particularly likely that we need this facility outside of the
AIO use-case, therefore remove the now unused functions.

I did choose to keep the comment added in the aforementioned commit about
lock->owner intentionally being left pointing to the last owner.

Reviewed-by: Chao Li <li.evan.chao@gmail.com>
Discussion: https://postgr.es/m/cj5mcjdpucvw4a54hehslr3ctukavrbnxltvuzzhqnimvpju5e@cy3g3mnsefwz

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/d40fd85187d06f7bd16fb4d0067bad0b1d248718

Modified Files
--------------
src/backend/storage/lmgr/lwlock.c | 71 ++++-----------------------------------
src/include/storage/lwlock.h      |  2 --
2 files changed, 6 insertions(+), 67 deletions(-)



Message-ID: <E1vgTVA-000fhX-39@gemulon.postgresql.org>
Permalink:  ../E1vgTVA-000fhX-39@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1vgTVA-000fhX-39@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: andres@anarazel.de, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: lwlock: Remove support for disowned lwlwocks
  In-Reply-To: <E1vgTVA-000fhX-39@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox