GHC 6.4.1 and Win32 DLLs: Bug in shutdownHaskell?

lennart at lennart at
Thu Mar 9 10:48:27 EST 2006

No, the timer thread starts even without -threaded.
If you use -threaded it gets worse because then you have
a bunch of other threads that don't exit properly.

  -- Lennart

Quoting Simon Marlow <simonmarhaskell at>:

> Lennart Augustsson wrote:
>> I've found more bugs.  There are several race conditions when a DLL
>> is unloaded.  The extra threads that the GHC runtime system starts
>> (at least one is always started to generate timer ticks) are not
>> shut down in a synchronized way.  This means that they might be
>> scheduled to run after the DLL has been unloaded.  Which gives you
>> an access violation.
>> I don't have a proper fix for this yet.
> Is this with -threaded?
> Simon

More information about the Glasgow-haskell-users mailing list