On Thu, 21 Jan 2010, Bernard van Gastel wrote:

But the descheduling of threads if the mutex is not available is done by the library. And especially the order of rescheduling of the threads (thats what I'm interested in). Or am I missing something in the sys/kern/sched files (btw I don't have the umtx file).

No, it's done by the kernel.  Threads block on a umtx in
the kernel, and they are also woken up by the kernel.  The
threads library does not wake up a specific thread - it
just calls into the kernel to unlock the umtx and the
kernel decides which thread to wake up.  You should probably
see src/sys/kern/kern_umtx.c.

--
DE
_______________________________________________
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"

Reply via email to