[Haskell-cafe] strange hangs with -threaded runtime
Joey Hess
joey at kitenet.net
Sat Jul 14 17:00:48 CEST 2012
Joey Adams wrote:
> Off the top of my head, I'm not aware of any (non-Windows-related)
> gotchas with using -threaded. However, some functions in MissingH
> (e.g. in System.Cmd.Utils) call forkProcess. To quote the
> documentation of forkProcess [1]:
>
> ---
> forkProcess comes with a giant warning: since any other running
> threads are not copied into the child process, it's easy to go wrong:
> e.g. by accessing some shared resource that was held by another thread
> in the parent.
> ---
>
> Perhaps the forked process is inheriting an interleaved computation
> that tries to use resources in the parent process.
This does seem at least a possibility, I'll try forcing inputs and see.
Are there any good general methods to debug threading mutex type problems
in ghc?
--
see shy jo
More information about the Haskell-Cafe
mailing list