Easiest way to extend CAS (casMutVar#) to boxed/unboxed Vector elements?
rrnewton at gmail.com
Tue Jan 10 18:19:17 CET 2012
I was wondering what the recommendations would be for getting CAS on
[mutable] vector elements?
I thought that as a first step I might create an a library that does the
trick only for unboxed vectors, by using bits-atomic (i.e. FFI + GCC
Roman Leshchinskiy recommended against depending on GCC. He thought,
therefore, that not only boxed arrays but unboxed ones would need an extra
PrimOp to be handled properly:
> You can't rely on gcc extensions because code is usually compiled with the
> native code generator nowadays and doesn't go through gcc. The dependency
> on gcc will (hopefully) be dropped eventually anyway. So you'd probably
> also want primops for unboxed arrrays and Addr#.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Glasgow-haskell-users