https://issues.dlang.org/show_bug.cgi?id=11981
Sean Kelly <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #22 from Sean Kelly <[email protected]> --- I'm unclear why you're calling thread_suspendAll/thread_resumeAll in those examples. These routines are for the GC to coordinate collections and have very strict requirements imposed on their use, fairly similar to those for code within signal handlers. When all threads are suspended, you can't do anything that might block (such as call malloc) or the app could deadlock. Was this simply for illustrative purposes? Upon further reading, it seems like the problem was that the folks working on dynamic library support weren't aware of this limitation. Yes, the thread-GC interface is very race-prone, and heavily commented as a result. If someone could come up with an alternative to using signals for coordinating collections on linux, that would be awesome. --
