[Gc] thread suspend on darwin

Paolo Molaro lupus at debian.org
Tue May 18 11:06:20 PDT 2004


Running mono on MacOSX, sometimes we get a
thread_info failed
message and libgc calls abort ().
It's mostly random, but in some setups it can be triggered pretty
easily. Looking at the code, this happens in GC_suspend_thread_list()
in darwin_stop_world.c. The function is called after task_threads()
retrieves the list of threads in the process and thread_info() is called
for each thread. The syscall returns an error (MACH_SEND_INVALID_DEST):
it may happen that the thread quit between task_threads() and
thread_info(), I suppose. The same could happen before thread_suspend()
is called later in the loop, so this kind of errors should likely be
ignored. Comments?

lupus

-- 
-----------------------------------------------------------------
lupus at debian.org                                     debian/rules
lupus at ximian.com                             Monkeys do it better


More information about the Gc mailing list