Re: Rationalizing SInval/PGPROC data structures and locking

From: Alvaro Herrera <alvherre(at)surnet(dot)cl>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Rationalizing SInval/PGPROC data structures and locking
Date: 2005-05-19 00:45:50
Message-ID: 20050519004550.GC12557@surnet.cl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, May 18, 2005 at 08:16:47PM -0400, Tom Lane wrote:

> The reason things got this way is that we've been loading more and more
> functionality onto the array of PGPROC pointers that is, more or less
> incidentally, maintained by sinval.c. I'm thinking that it'd be a good
> idea to remove most of that stuff from sinval.c and put it into a
> separate module that maintains its own array of PGPROC pointers with a
> separate lock. There's no reason why, eg, GetSnapshotData needs to
> conflict with transfer of SI inval messages, which is what SInvalLock
> was originally designed to protect.

I agree this is a good idea. I might mention that I was going to put
some things in the PGPROC array for MultiXactId, then saw that getting
the SInvalLock for operations on those would abuse the lock too much --
that's when I decided to move them to a separate struct.

--
Alvaro Herrera (<alvherre[a]surnet.cl>)
"In Europe they call me Niklaus Wirth; in the US they call me Nickel's worth.
That's because in Europe they call me by name, and in the US by value!"

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2005-05-19 01:32:52 Re: Learning curves and such (was Re: pgFoundry)
Previous Message Alvaro Herrera 2005-05-19 00:22:23 Re: Two-phase commit issues