diff options
author | Johan Tibell <johan.tibell@gmail.com> | 2014-06-27 13:48:24 +0200 |
---|---|---|
committer | Johan Tibell <johan.tibell@gmail.com> | 2014-06-30 22:12:45 +0200 |
commit | 4ee4ab01c1d97845aecb7707ad2f9a80933e7a49 (patch) | |
tree | 08991e97b0109b81447968ba62e4753e8209a738 /libraries/ghc-prim/ghc-prim.cabal | |
parent | aed1723f97e0539d5ab35222b180c1552a5f4cfc (diff) | |
download | haskell-4ee4ab01c1d97845aecb7707ad2f9a80933e7a49.tar.gz |
Re-add more primops for atomic ops on byte arrays
This is the second attempt to add this functionality. The first
attempt was reverted in 950fcae46a82569e7cd1fba1637a23b419e00ecd, due
to register allocator failure on x86. Given how the register
allocator currently works, we don't have enough registers on x86 to
support cmpxchg using complicated addressing modes. Instead we fall
back to a simpler addressing mode on x86.
Adds the following primops:
* atomicReadIntArray#
* atomicWriteIntArray#
* fetchSubIntArray#
* fetchOrIntArray#
* fetchXorIntArray#
* fetchAndIntArray#
Makes these pre-existing out-of-line primops inline:
* fetchAddIntArray#
* casIntArray#
Diffstat (limited to 'libraries/ghc-prim/ghc-prim.cabal')
-rw-r--r-- | libraries/ghc-prim/ghc-prim.cabal | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libraries/ghc-prim/ghc-prim.cabal b/libraries/ghc-prim/ghc-prim.cabal index c861342b56..bc9f57126a 100644 --- a/libraries/ghc-prim/ghc-prim.cabal +++ b/libraries/ghc-prim/ghc-prim.cabal @@ -52,6 +52,7 @@ Library exposed-modules: GHC.Prim c-sources: + cbits/atomic.c cbits/bswap.c cbits/debug.c cbits/longlong.c |