« Return to Thread: Lock-free atomic_shared_ptr?

Re: Lock-free atomic_shared_ptr<T>?

by Gpderetta :: Rate this Message:

Reply to Author | View in Thread

On Jan 18, 2008 11:57 PM, Andrey Tcherepanov <moyt63c02@...> wrote:
> Well, according to
> http://en.wikipedia.org/wiki/X86-64#Virtual_address_space_details
> it might be dangerous to rely on the fact that top 16 bits are not
> currently used.
>

You need only to rely on it on older machines that do not have DCAS.
Microsoft has a lock free list that
chooses at runtime whether to use plain CAS with 48 ptr + 16 bit ABA
counter (actually it is probably something like 44/20
by relying on minimum alignment), or DCAS on more recent machines.

--
gpd
_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

 « Return to Thread: Lock-free atomic_shared_ptr?