
#16044: Transition to C11 memory model -------------------------------------+------------------------------------- Reporter: ulan | Owner: (none) Type: task | Status: new Priority: normal | Milestone: Component: Runtime System | Version: 8.6.3 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by ulan): [re-entering my reply via Trac UI as my email reply was not picked up] That's a good question. I am not sure what would be the best approach for Cmm. I am thinking about extending the existing atomic MachOps (MO_AtomicRead, MO_AtomicWrite, etc) with the memory order that would be similar to LlvmSyncOrdering. Then compiling to LLVM would be straightforward. For other backends, we indeed would have to provide architecture specific implementation of the atomics ops (e.g. https://www.cl.cam.ac.uk/~pes20/cpp/cpp0xmappings.html) -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/16044#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler