Manfred Spraul <[EMAIL PROTECTED]> writes:
> Tom Lane wrote:
>> The bigger problem here is that the SMP locking bottlenecks we are
>> currently seeing are *hardware* issues (AFAICT anyway).  The only way
>> that futexes can offer a performance win is if they have a smarter way
>> of executing the basic atomic-test-and-set sequence than we do;
>> 
> lwlocks operations are not a basic atomic-test-and-set sequence. They 
> are spinlock, several nonatomic operations, spin_unlock.

Right, and it is the spinlock that is the problem.  See discussions a
few months back: at least on Intel SMP machines, most of the problem
seems to have to do with trading the spinlock's cache line back and
forth between CPUs.  It's difficult to see how a futex is going to avoid
that.

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
      subscribe-nomail command to [EMAIL PROTECTED] so that your
      message can get through to the mailing list cleanly

Reply via email to