mirror of
https://github.com/barrucadu/dejafu.git
synced 2024-11-23 06:02:52 +03:00
Be explicit about bound threads in test execution in docs
This commit is contained in:
parent
ade267c166
commit
4a4baec1d9
@ -187,6 +187,12 @@ forkOSWithUnmaskN n ma
|
||||
-- state, returning a failure reason on error. Also returned is the
|
||||
-- final state of the scheduler, and an execution trace.
|
||||
--
|
||||
-- If the RTS supports bound threads (ghc -threaded when linking) then
|
||||
-- the main thread of the concurrent computation will be bound, and
|
||||
-- @forkOS@ / @forkOSN@ will work during execution. If not, then the
|
||||
-- main thread will not be found, and attempting to fork a bound
|
||||
-- thread will raise an error.
|
||||
--
|
||||
-- __Warning:__ Blocking on the action of another thread in 'liftIO'
|
||||
-- cannot be detected! So if you perform some potentially blocking
|
||||
-- action in a 'liftIO' the entire collection of threads may deadlock!
|
||||
|
@ -17,7 +17,7 @@ with testcases which need ``MonadIO``, use ``dejafuIO`` for that.
|
||||
|
||||
|
||||
Actions
|
||||
----------
|
||||
-------
|
||||
|
||||
An action is just something with the type ``MonadConc m => m a``, or
|
||||
``(MonadConc m, MonadIO m) => m a`` for some ``a`` that your chosen
|
||||
@ -65,6 +65,13 @@ want to see the full code. [#]_
|
||||
predicates are checking that the bug is found, not that the
|
||||
code is correct.
|
||||
|
||||
If the RTS supports bound threads (the ``-threaded`` flag was passed
|
||||
to GHC when linking), then the main thread of an action given to Déjà
|
||||
Fu will be bound, and further bound threads can be forked with the
|
||||
``forkOS`` functions. If not, then attempting to fork a bound thread
|
||||
will raise an error.
|
||||
|
||||
|
||||
Predicates
|
||||
----------
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user