Pre-emptive or co-operative concurrency (was: Concurrency)

John Meacham john at
Tue Mar 28 09:25:49 EST 2006

On Tue, Mar 28, 2006 at 02:43:09PM +0100, Simon Marlow wrote:
> So I propose for the purposes of the standard/addendum, we adopt the
> above definitions of fairness, together with the requirement that "safe"
> (and maybe "blockable") foreign calls and I/O operations do not block
> other threads.

this is exactly the purpose of the blockable flag. exactly those FFI routines
that are guarenteed to not block are those that have the blockable flag.
it happens by accident that this means the same thing as 'safe' in ghc,
but that is quite specific to ghcs concurrency implementation.

it is quite important to separate the concept of blockable from safe. it
is unlikely a cooperative system will ever be able to support 'blockable
safe' calls, but with some finagling can support 'blockable unsafe'

I have a whole lot to say on these issues but have been sick lately so
have been MIA. I hope to catch up soon though.


John Meacham - ⑆⑆john⑈

More information about the Haskell-prime mailing list