Commit Graph

506 Commits

Author SHA1 Message Date
Michael Walker
f626e79553 Implement the new primitives in stepThread 2015-02-23 17:32:08 +00:00
Michael Walker
b8ff9a77f5 Add primitives for the new testing functions 2015-02-23 17:27:26 +00:00
Michael Walker
e72b84c613 Add an internal STM module 2015-02-23 17:24:02 +00:00
Michael Walker
2a6cbe8951 Add functions to MonadConc to record known vars 2015-02-23 17:23:26 +00:00
Michael Walker
0e3ba970bd Make CRefs interesting 2015-02-20 18:49:19 +00:00
Michael Walker
5862d536ca Use default writeCRef for IO 2015-02-20 16:53:38 +00:00
Michael Walker
0ea2930862 Implement CRefs in stepThread 2015-02-20 16:24:21 +00:00
Michael Walker
a4a291368d Add primitives for CRefs 2015-02-20 16:14:50 +00:00
Michael Walker
2f61cf6557 Add mutable non-blocking atomically-modifiable references 2015-02-20 15:59:53 +00:00
Michael Walker
0dba84f9a8 Add forkOn and getNumCapabilities 2015-02-18 00:13:12 +00:00
Michael Walker
9609823dd5 Add exception checking to autocheck 2015-02-17 11:22:17 +00:00
Michael Walker
998fdeb833 Update the deadlocks* predicates to handle STMDeadlock, and add exceptions* predicates 2015-02-17 05:58:25 +00:00
Michael Walker
22a15dfe95 Resolve all name conflicts with Prelude.catch in base-4.5 2015-02-16 03:47:14 +00:00
Michael Walker
6a371e6994 Use cabal-1.22 in travis 2015-02-16 03:38:50 +00:00
Michael Walker
1063b36fbd Resolve conflict with Prelude.catch in base-4.5 in STM 2015-02-16 03:37:16 +00:00
Michael Walker
6f253df520 Drop base dependency to 4.5 2015-02-16 03:33:37 +00:00
Michael Walker
5d0545b198 Test more GHC versions in travis 2015-02-16 03:29:40 +00:00
Michael Walker
ab6e411c38 Tidy up Deterministic.Internal 2015-02-16 03:16:55 +00:00
Michael Walker
f41a39e490 Add ImpredicativeTypes everywhere to make mask (grr, exceptions) work with GHC 7.8.4 2015-02-16 02:50:52 +00:00
Michael Walker
ad98bb6d90 Fix a => typo (why did that ever compile and run!?) 2015-02-16 02:50:20 +00:00
Michael Walker
392a8c54c6 Add some STM tests. Closes #7. 2015-02-14 23:55:58 +00:00
Michael Walker
921d505015 Merge branch 'exceptions'
Closes #4.
2015-02-14 23:45:42 +00:00
Michael Walker
62711d9025 Add some exception tests 2015-02-14 23:45:14 +00:00
Michael Walker
7409bc67cd Re-export MaskingState from Deterministic 2015-02-14 21:24:41 +00:00
Michael Walker
99dd56adfe Implement forkWithUnmask 2015-02-14 21:16:44 +00:00
Michael Walker
abc31aa165 Have throwTo get blocked on mask state 2015-02-14 21:01:33 +00:00
Michael Walker
8af7b814c2 Consider masking changes interesting for SCT 2015-02-14 18:59:11 +00:00
Michael Walker
f75db99713 Implement AMasking and AResetMask (but don't yet consider masking in throwTo!) 2015-02-14 18:54:43 +00:00
Michael Walker
5dc8476cac Threads inherit the masking state of their parent 2015-02-14 16:05:16 +00:00
Michael Walker
3a4c58b4ee Turn threads into records 2015-02-14 16:02:07 +00:00
Michael Walker
8f4007ed59 Add a AResetMasking action 2015-02-14 15:47:48 +00:00
Michael Walker
825b135dc1 Add AMasking primitive 2015-02-13 18:30:21 +00:00
Michael Walker
f18209f2e0 Make MonadMask a requirement for MonadConc 2015-02-13 17:47:04 +00:00
Michael Walker
8faee29b27 Implement throwTo and killThread 2015-02-13 17:13:00 +00:00
Michael Walker
2a79b78901 Pop exception handlers off the stack when leaving their scope 2015-02-13 14:06:52 +00:00
Michael Walker
ad216bd3a9 hlint fixes 2015-02-13 00:56:45 +00:00
Michael Walker
cf1c6ebece Available ThreadIds. Closes #3 2015-02-13 00:55:05 +00:00
Michael Walker
97611ff5b5 Implement catching exceptions 2015-02-13 00:50:58 +00:00
Michael Walker
9bd781c697 Primitive for throwing exceptions 2015-02-13 00:46:48 +00:00
Michael Walker
5ce63d0d50 Use MonadThrow/MonadCatch for MonadConc exceptions 2015-02-13 00:46:14 +00:00
Michael Walker
ef580d66e8 Use MonadThrow/MonadCatch for MonadSTM exceptions 2015-02-13 00:46:13 +00:00
Michael Walker
9b0cd6ffd3 doTransaction already calls undo on retry/exception 2015-02-13 00:46:12 +00:00
Michael Walker
a305354b65 Add STM exceptions 2015-02-13 00:46:11 +00:00
Michael Walker
8b31dc45c6 Make travis build non-master branches 2015-02-13 00:45:34 +00:00
Michael Walker
7b7c765494 Add a central manager for unique ID types 2015-02-10 18:26:22 +00:00
Michael Walker
d5e4f94a08 Include the CTVarIds of created CTVars in STM Success output 2015-02-10 11:16:36 +00:00
Michael Walker
f7b7539445 Remove logic duplication in Deterministic.Internal 2015-02-10 02:09:51 +00:00
Michael Walker
a54925df4b Move CVar IDs out of the Ref in Deterministic 2015-02-10 01:20:04 +00:00
Michael Walker
78ee2b2f75 Add MonadSTM constraint to MonadConc 2015-02-10 01:19:45 +00:00
Michael Walker
1cc5ade782 Reimplement CVar blocking in the same way as CTVar blocking 2015-02-09 23:43:18 +00:00