Main Thread Evacuated
Simon Marlow
simonmar at microsoft.com
Wed Sep 25 07:30:46 EDT 2002
> I've found a bug in the scheduler:
>
> When a main thread finishes (e.g. returning from a ffi callback), the
> GC might be run before it is removed from the main_threads list. If a
> major collection happens, the thread will be garbage
> collected and the
> GC barfs when it updates the pointers in the main_threads list.
> This scenario is quite unlikely during normal operation, but when
> heap-profiling a HOpenGL program it leads to certain death
> after a few
> seconds.
> I don't know how to fix it in a clean way (I have no idea how my
> changes would affect the threaded rts or the other "ways") --- so can
> someone else please fix this?
Hmm, yes that looks like a bug. I've put together a patch (enclosed),
could you tell me if it helps?
Cheers,
Simon
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch
Type: application/octet-stream
Size: 2170 bytes
Desc: not available
Url : http://www.haskell.org/pipermail/glasgow-haskell-bugs/attachments/20020925/ef6cfffc/patch.obj
More information about the Glasgow-haskell-bugs
mailing list