"Dmitriy V'jukov" <dvyukov@[EMAIL PROTECTED]
> wrote in message
news:dd05d47f-9502-43a0-ac49-844bbe34c6c7@[EMAIL PROTECTED]
Sep 29, 5:02 pm, "Chris M. Thomasson" <n...@[EMAIL PROTECTED]
> wrote:
> > You mean:
> >
> > 1 atomic RMW and 1 StoreLoad membar for lock
> > 1 atomic RMW and 1 LoadStore membar for unlock
> >
> > 2 atomics, and 2 membars; fairly expensive... Well... You indeed have
a
> > good
> > point in the case that stealing is rare...
> No, I mean for spin-mutex:
> 1 atomic RMW + 1 StoreLoad membar for lock
> store-release for unlock
Ahhh, I fail see spin-mutex and thing adaptive mutex. Sorry for my
confusion.
> Which for x86 means:
> 1 atomic RMW for lock (StoreLoad is implied, and so basically
> costless)
IMHO, its not costless. Not at all...
> plain store for unlock (release is implied)
Indeed.


|