On 2013-11-15 20:47:26 +0100, Andres Freund wrote:
> Hi,
> 
> On 2013-09-27 00:55:45 +0200, Andres Freund wrote:
> > So what's todo? The file header tells us:
> >  * - revive pure-spinlock implementation
> >  * - abstract away atomic ops, we really only need a few.
> >  *   - CAS
> >  *   - LOCK XADD
> >  * - convert PGPROC->lwWaitLink to ilist.h slist or even dlist.
> >  * - remove LWLockWakeup dealing with MyProc
> >  * - overhaul the mask offsets, make SHARED/EXCLUSIVE_LOCK_MASK wider, 
> > MAX_BACKENDS
> 
> So, here's the next version of this patchset:
> 1) I've added an abstracted atomic ops implementation. Needs a fair
>    amount of work, also submitted as a separate CF entry. (Patch 1 & 2)
> 2) I've converted PGPROC->lwWaiting into a dlist. That makes a fair bit
>    of code easier to read and reduces the size of the patchset. Also
>    fixes a bug in the xlog-scalability code. (Patch 3)
> 3) Alvaro and I updated the comments in lwlock.c. (Patch 4)
> 
> I think 2) should be committable pretty soon. It's imo a pretty clear
> win in readability. 1) will need a good bit of more work.
> 
> With regard to the scalable lwlock work, what's most needed now is a
> good amount of testing.
> 
> Please note that you need to 'autoreconf' after applying the patchset. I
> don't have a compatible autoconf version on this computer causing the
> diff to be humongous if I include those changes.

Please also note that due to the current state of the atomics
implementation this likely will only work on a somewhat recent gcc and
that the performance might be slightly worse than in the previous
version because the atomic add is implemented using the CAS fallback.

Greetings,

Andres Freund

-- 
 Andres Freund                     http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services


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

Reply via email to