[GHC] #14244: ghc-prim: hs_atomicread* and hs_atomicwrite* missing barriers
GHC
ghc-devs at haskell.org
Thu Nov 2 21:04:05 UTC 2017
#14244: ghc-prim: hs_atomicread* and hs_atomicwrite* missing barriers
-------------------------------------+-------------------------------------
Reporter: trommler | Owner: trommler
Type: bug | Status: patch
Priority: high | Milestone: 8.4.1
Component: Prelude | Version: 8.2.1
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
Type of failure: Incorrect result | Unknown/Multiple
at runtime | Test Case:
Blocked By: | Blocking:
Related Tickets: #12537 | Differential Rev(s): Phab:D4009
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by Ben Gamari <ben@…>):
In [changeset:"bd765f4b1332b3d2a7908de3f9ff1d50da0e0b1d/ghc" bd765f4/ghc]:
{{{
#!CommitTicketReference repository="ghc"
revision="bd765f4b1332b3d2a7908de3f9ff1d50da0e0b1d"
Fix atomicread/write operations
In `libraries/ghc-prim/cbits/atomic.c` no barriers were issued for
atomic read and write operations. Starting with gcc 4.7 compiler
intrinsics are offered. The atomic intrinisics are also available in
clang. Use these to implement `hs_atomicread*` and `hs_atomicwrite`.
Test Plan: validate on OSX and Windows
Reviewers: austin, bgamari, simonmar, hvr, erikd, dfeuer
Reviewed By: bgamari
Subscribers: dfeuer, rwbarton, thomie
GHC Trac Issues: #14244
Differential Revision: https://phabricator.haskell.org/D4009
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14244#comment:4>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list