Re: [HACKERS] Final Thoughts for 8.3 on LWLocking and Scalability

2008-03-19 Thread Simon Riggs
On Wed, 2008-03-19 at 12:24 -0400, Tom Lane wrote: > > [ sinval lock management needs redesign ] > > Yup it does. I wrote a redesigned, simplified version of my earlier patch. Enclosed here for discussion only, not expecting this to be the final version. Comments at top of patch explain it. The

Re: [HACKERS] Final Thoughts for 8.3 on LWLocking and Scalability

2008-03-19 Thread Tom Lane
Simon Riggs <[EMAIL PROTECTED]> writes: > I've completed a review of all of the LWlocking in the backends. This is > documented in the enclosed file. I would propose that we use this as > comments in lwlock.h or in the README, if people agree. I don't think that putting this list in as documentati

Re: [HACKERS] Final Thoughts for 8.3 on LWLocking and Scalability

2007-09-11 Thread Simon Riggs
On Tue, 2007-09-11 at 19:32 +0200, Florian G. Pflug wrote: > Simon Riggs wrote: > > On Tue, 2007-09-11 at 10:21 -0400, Tom Lane wrote: > >> Simon Riggs <[EMAIL PROTECTED]> writes: > >>> 1. The ProcArrayLock is acquired Exclusive-ly by only one > >>> remaining operation: XidCacheRemoveRunningXids()

Re: [HACKERS] Final Thoughts for 8.3 on LWLocking and Scalability

2007-09-11 Thread Florian G. Pflug
Simon Riggs wrote: On Tue, 2007-09-11 at 10:21 -0400, Tom Lane wrote: Simon Riggs <[EMAIL PROTECTED]> writes: 1. The ProcArrayLock is acquired Exclusive-ly by only one remaining operation: XidCacheRemoveRunningXids(). Reducing things to that level is brilliant work, Florian and Tom. It would

Re: [HACKERS] Final Thoughts for 8.3 on LWLocking and Scalability

2007-09-11 Thread Simon Riggs
On Tue, 2007-09-11 at 10:21 -0400, Tom Lane wrote: > Simon Riggs <[EMAIL PROTECTED]> writes: > > 1. The ProcArrayLock is acquired Exclusive-ly by only one remaining > > operation: XidCacheRemoveRunningXids(). Reducing things to that level is > > brilliant work, Florian and Tom. > > It would be bri

Re: [HACKERS] Final Thoughts for 8.3 on LWLocking and Scalability

2007-09-11 Thread Tom Lane
Simon Riggs <[EMAIL PROTECTED]> writes: > 1. The ProcArrayLock is acquired Exclusive-ly by only one remaining > operation: XidCacheRemoveRunningXids(). Reducing things to that level is > brilliant work, Florian and Tom. It would be brilliant if it were true, but it isn't. Better look again.

Re: [HACKERS] Final Thoughts for 8.3 on LWLocking and Scalability

2007-09-11 Thread Simon Riggs
On Tue, 2007-09-11 at 13:31 +0300, Marko Kreen wrote: > On 9/11/07, Simon Riggs <[EMAIL PROTECTED]> wrote: > > 5. ReadNewTransactionId() is only called now by GetNextXidAndEpoch(), > > but I can't find a caller of that anywhere in core or contrib. Can those > > now be removed? > > GetNextXidAndEpo

Re: [HACKERS] Final Thoughts for 8.3 on LWLocking and Scalability

2007-09-11 Thread Marko Kreen
On 9/11/07, Simon Riggs <[EMAIL PROTECTED]> wrote: > 5. ReadNewTransactionId() is only called now by GetNextXidAndEpoch(), > but I can't find a caller of that anywhere in core or contrib. Can those > now be removed? GetNextXidAndEpoch() is needed for external modules to use 8-byte transaction ids

[HACKERS] Final Thoughts for 8.3 on LWLocking and Scalability

2007-09-11 Thread Simon Riggs
I've completed a review of all of the LWlocking in the backends. This is documented in the enclosed file. I would propose that we use this as comments in lwlock.h or in the README, if people agree. A number of points emerge from that analysis: 1. The ProcArrayLock is acquired Exclusive-ly by only