Re: better atomics - Mailing list pgsql-hackers

From Robert Haas
Subject Re: better atomics
Date
Msg-id CA+TgmoZj_e5D9W5Qm1q07HdUKzpV7tvk3FL_C2q3e4wYg6HBDQ@mail.gmail.com
Whole thread Raw
In response to Re: better atomics  (Andres Freund <andres@2ndquadrant.com>)
List pgsql-hackers
On Mon, Oct 28, 2013 at 3:32 PM, Andres Freund <andres@2ndquadrant.com> wrote:
>> I wonder whether it'd be safe to assume that any machine where
>> pointers are 8 bytes has 8-byte atomic loads and stores.  I bet there
>> is a counterexample somewhere.  :-(
>
> Sparc64 :(.
>
> Btw, could you quickly give some keywords what you're thinking about
> making lockless?
> I mainly am thinking about lwlocks and buffer pins so far. Nothing
> really ambitious.

Well, I was going to use it for some code I'm working on for
parallelism, but I just tested the overhead of a spinlock, and it was
zero, possibly negative.  So I may not have an immediate application.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: OSX doesn't accept identical source/target for strcpy() anymore
Next
From: Tom Lane
Date:
Subject: Re: OSX doesn't accept identical source/target for strcpy() anymore