[GHC] #4001: Implement an atomic readMVar
GHC
ghc-devs at haskell.org
Wed Jul 10 01:15:37 CEST 2013
#4001: Implement an atomic readMVar
----------------------------+----------------------------------------------
Reporter: | Owner: ezyang
simonmar | Status: closed
Type: task | Milestone: 7.6.2
Priority: low | Version: 6.12.2
Component: Runtime | Keywords:
System | Architecture: Unknown/Multiple
Resolution: fixed | Difficulty: Moderate (less than a day)
Operating System: | Blocked By:
Unknown/Multiple | Related Tickets:
Type of failure: |
None/Unknown |
Test Case: |
Blocking: |
----------------------------+----------------------------------------------
Changes (by ezyang):
* status: new => closed
* resolution: => fixed
Comment:
{{{
commit 70e20631742e516c6a11c3c112fbd5b4a08c15ac
Author: Edward Z. Yang <ezyang at mit.edu>
Date: Mon Jul 8 11:03:35 2013 -0700
Implement atomicReadMVar, fixing #4001.
We add the invariant to the MVar blocked threads queue that
threads blocked on an atomic read are always at the front of
the queue. This invariant is easy to maintain, since takers
are only ever added to the end of the queue.
Signed-off-by: Edward Z. Yang <ezyang at mit.edu>
commit 1cb6aee7fd81175fe0af81146e878aaf7cda87d2
Author: Edward Z. Yang <ezyang at mit.edu>
Date: Fri Jun 14 14:21:02 2013 -0700
Tests for atomicReadMVar.
Signed-off-by: Edward Z. Yang <ezyang at mit.edu>
commit c464def32f8ba65927ecfcbe34a5f06c21774ecc
Author: Edward Z. Yang <ezyang at mit.edu>
Date: Fri Jun 14 14:19:58 2013 -0700
Add atomicReadMVar to Control.Concurrent.MVar and friends.
Also renumber thread statuses as necessary.
Signed-off-by: Edward Z. Yang <ezyang at mit.edu>
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/4001#comment:21>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list