Inner workings of turnstiles and sleepqueues

John Baldwin jhb at freebsd.org
Wed Oct 17 06:16:47 PDT 2007


On Tuesday 16 October 2007 05:41:18 am Ed Schouten wrote:
> Hello,
> 
> I asked the following question on questions@, but as requested, I'll
> forward this question to this list, because of its technical nature.
> 
> ----- Forwarded message from Ed Schouten <ed at fxq.nl> -----
> > Date: Mon, 15 Oct 2007 23:13:01 +0200
> > From: Ed Schouten <ed at fxq.nl>
> > To: freebsd-questions at freebsd.org
> > Subject: Inner workings of turnstiles and sleepqueues
> > 
> > Hello,
> > 
> > For some reason, I want to understand how the queueing of blocked
> > threads in the kernel works when waiting for a lock, which is if I
> > understand correctly done by the turnstiles and sleepqueues. I'm the
> > proud owner of The Design and Implementation of the FreeBSD Operating
> > System book, but for some reason, I can't find anything about it in the
> > book.
> > 
> > Is there a way to obtain information about how they work? I already read
> > the source somewhat, but that shouldn't be an ideal solution, in my
> > opinion.

The best option right now is to read the code.  There are some comments in
both the headers and implementation.

-- 
John Baldwin


More information about the freebsd-hackers mailing list