Re: Spinlocks, yet again: analysis and proposed patches

From: "Michael Paesold" <mpaesold(at)gmx(dot)at>
To: "Marko Kreen" <marko(at)l-t(dot)ee>, "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Spinlocks, yet again: analysis and proposed patches
Date: 2005-09-14 20:56:22
Message-ID: 002c01c5b96e$c3c95560$0f01a8c0@zaphod
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:

>I wrote:
>> We could ameliorate this if there were a way to acquire ownership of the
>> cache line without necessarily winning the spinlock. I'm imagining
>> that we insert a "dummy" locked instruction just ahead of the xchgb,
>> which touches the spinlock in such a way as to not change its state.
>
> I tried this, using this tas code:
...

I have tried it on the P4 w/ HT.

CVS tip 1: 37s 2: 78s 4: 159s 8: 324
only slock-no-cmpb 1: 37s 2: 82s 4: 178s 8: 362
only dummy-locking 1: 44s 2: 96s 4: 197s ...

I guess there is no reason to try any more.

Best Regards,
Michael Paesold

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Kris Jurka 2005-09-14 21:00:22 Re: GSSAPI or Kerberos authentication problems
Previous Message Mike Warnecke 2005-09-14 20:08:06 GSSAPI or Kerberos authentication problems