[Haskell-cafe] Re: Support for lock-free/wait-free programming?
Gabriel Wicke
wicke at wikidev.net
Fri Aug 27 09:14:36 EDT 2010
On Tue, 17 Aug 2010 01:09:41 -0400, Gregory Collins wrote:
> Hello all,
>
> Does GHC expose any primitives for things like atomic compare-and-swap?
> I can't seem to find anything in the docs.
Hello Gregory,
I have recently published experimental and low-level FFI bindings to
GCC's
atomic primitives including CAS as 'bits-extras' on Hackage [1].
Instances for Int and Word types are included.
This is likely lower-level than what you are after, but might still be
handy for experimentation.
Kind regards
Gabriel
[1]: http://hackage.haskell.org/packages/archive/bits-extras/0.1.0/doc/
html/Data-Bits-Atomic.html
More information about the Haskell-Cafe
mailing list