Sean Kelly Wrote: > > This one is weird, and doesn't appear related to 4307. One of the threads > (thread A) is in a GC collection and blocked trying to acquire the mutex > protecting the global thread list within thread_resumeAll. Another thread > (thread B) is also blocked trying to acquire this mutex for other reasons. > My best guess is that pthread_mutex in OSX is trying to give ownership of the > lock to thread B, and since thread B is suspended it effectively blocks > thread A from acquiring it to resume execution after the GC cycle.
After some testing, it looks like I was right. I have a fix for this, but it's far from ideal (though the diff is small): require everything but thread_resumeAll to acquire two locks in sequence, while thread_resumeAll only acquires the second. I'll try to come up with something better.