scheduler (sched_4bsd) questions

Stephan Uphoff ups at tree.com
Wed Sep 29 13:26:19 PDT 2004


Forgot to attach the patch ...

	Stephan

On Wed, 2004-09-29 at 13:12, Stephan Uphoff wrote:
> On Wed, 2004-09-29 at 10:24, Stephan Uphoff wrote:
> > On Wed, 2004-09-29 at 04:57, Peter Holm wrote:
> > > It's hard for me to tell if your patch has made any difference.
> > > The freeze is still there.  I'll try to make the same test once more
> > > without your patches to see if I get the same pattern in freezes.
> > 
> > I found some problems yesterday with mutex priority inheritance that
> > could potentially cause your freeze patterns.
> > 
> > I will try to roll a preliminary patch as soon as the caffeine does its
> > magic.
> 
> OK - here is a crude patch to fix some problems with mutex priority
> inheritance. My theory is that the clock thread gets stuck waiting on
> GIANT.
> 
> During release/acquisition of a contested sleep mutex there are a few
> windows where a task can be preempted when actions (waking up blocked
> threads, ownership of the mutex, ..) need to be atomic as far as
> scheduling is concerned. Otherwise priority inheritance may fail. The
> patch uses critical_enter/critical_exit to protect these regions against
> preemption.
> 
> It would be great if could run this in addition to the other patches.
> 
> 	Stephan

-------------- next part --------------
A non-text attachment was scrubbed...
Name: mutex_patch
Type: text/x-patch
Size: 738 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-arch/attachments/20040929/cf942de1/mutex_patch.bin


More information about the freebsd-arch mailing list