pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andres Freund <andres@anarazel.de>
To: Alexander Korotkov <a.korotkov@postgrespro.ru>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-committers <pgsql-committers@postgresql.org>
Subject: Re: pgsql: Allow Pin/UnpinBuffer to operate in a lockfree manner.
Date: Mon, 18 Apr 2016 07:27:50 -0700
Message-ID: <20160418142750.p3qwwnnuacb6n7jw@alap3.anarazel.de> (raw)
In-Reply-To: <CAPpHfdusvQcvN++DOXp_+JPAGv=vU4b19zP_JZa8Hdfq8Y536Q@mail.gmail.com>
References: <E1apSHT-0007xJ-Bh@gemulon.postgresql.org>
	<9194.1460908908@sss.pgh.pa.us>
	<CA+TgmoZsjmn6xtFepN86bb8DcTzyARUT+T5wpYBpr-9rLdwvGg@mail.gmail.com>
	<CAPpHfdusvQcvN++DOXp_+JPAGv=vU4b19zP_JZa8Hdfq8Y536Q@mail.gmail.com>
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>

On 2016-04-18 17:12:32 +0300, Alexander Korotkov wrote:
> On Mon, Apr 18, 2016 at 2:34 PM, Robert Haas <robertmhaas@gmail.com> wrote:
> 
> > On Sun, Apr 17, 2016 at 12:01 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> > > Andres Freund <andres@anarazel.de> writes:
> > >> Allow Pin/UnpinBuffer to operate in a lockfree manner.
> > >
> > > Now that I've had some occasion to look around in bufmgr.c, I am very
> > > unhappy that there are still boatloads of comments talking about a buffer
> > > header's spinlock, when there is in fact no spinlock anymore.  Please
> > > expend some effort on making this less confusing for the next hacker.
> > > Maybe make those comments talk about a "lock bit" instead?
> >
> > I was actually going to complain about this, too.  I noticed it over
> > the weekend when noodling around with another patch.  I'm not sure
> > exactly how it should be revised, but I find the current state of
> > things confusing.
> >
> 
> +1
> Do we have consensus on renaming "buffer header spinlock" to "buffer header
> lock bit"?

Personally I think the "spin" part is actually quite relevant, and I
think we shouldn't loose it. It describes concurrency and blocking
behaviour, and how errors need to be handled (i.e. there may not be
any).

Greetings,

Andres Freund


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers



view thread (30+ messages)  latest in thread

Message-ID: <20160418142750.p3qwwnnuacb6n7jw@alap3.anarazel.de>
Permalink:  ../20160418142750.p3qwwnnuacb6n7jw@alap3.anarazel.de/
Also on:    postgresql.org/message-id/20160418142750.p3qwwnnuacb6n7jw@alap3.anarazel.de

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: andres@anarazel.de, a.korotkov@postgrespro.ru, robertmhaas@gmail.com, tgl@sss.pgh.pa.us
  Subject: Re: pgsql: Allow Pin/UnpinBuffer to operate in a lockfree manner.
  In-Reply-To: <20160418142750.p3qwwnnuacb6n7jw@alap3.anarazel.de>
  References: <E1apSHT-0007xJ-Bh@gemulon.postgresql.org> <9194.1460908908@sss.pgh.pa.us> <CA+TgmoZsjmn6xtFepN86bb8DcTzyARUT+T5wpYBpr-9rLdwvGg@mail.gmail.com> <CAPpHfdusvQcvN++DOXp_+JPAGv=vU4b19zP_JZa8Hdfq8Y536Q@mail.gmail.com> <20160418142750.p3qwwnnuacb6n7jw@alap3.anarazel.de>

* 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