So, there's a small regression on low client counts. That's worth addressing.
Interesting. I'll try to reproduce it.
> Attached patch is rebased and have better comments. > Also, there is one comment which survive since original version by Andres. > > /* Add exponential backoff? Should seldomly be contended tho. */ > > > Andres, did you mean we should twice the delay with each unsuccessful try > to lock?
Spinning on a lock as fast as possible leads to rapid cacheline bouncing without anybody making progress. See s_lock() in s_lock.c.
I didn't notice that s_lock() behaves so. Thank you.
------ Alexander Korotkov Postgres Professional: http://www.postgrespro.com The Russian Postgres Company