Skip site navigation (1) Skip section navigation (2)

LWLock Queue Jumping

From: Simon Riggs <simon(at)2ndQuadrant(dot)com>
To: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: LWLock Queue Jumping
Date: 2009-08-28 19:07:32
Message-ID: 1251486452.4839.1457.camel@ebony.2ndQuadrant (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
WALInsertLock is heavily contended and likely always will be even if we
apply some of the planned fixes.

Some callers of WALInsertLock are more important than others

* Writing new Clog or Multixact pages (serialized by ClogControlLock)
* For Hot Standby, writing SnapshotData (serialized by ProcArrayLock)

In these cases it seems like we can skip straight to the front of the
WALInsertLock queue without problem.

Most other items cannot be safely reordered, possibly no other items.

We already re-order the lock queues when we hold shared locks, so we
know in principle it is OK to do so. This is an extension of that

Implementing this would do much to remove my objection to performance
issues associated with simplifying the Hot Standby patch, as recently
suggested by Heikki.

Possible? If so, we can discuss implementation. No worries if not, but
just a side thought that may be fruitful.

 Simon Riggs 


pgsql-hackers by date

Next:From: Andrew DunstanDate: 2009-08-28 19:32:55
Subject: Re: Add YAML option to explain
Previous:From: David FetterDate: 2009-08-28 18:52:23

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group