Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 5 Jul 2000 16:29:26 -0700
From:      Alfred Perlstein <bright@wintelcom.net>
To:        Terry Lambert <tlambert@primenet.com>
Cc:        Greg Lehey <grog@lemis.com>, "Jeroen C. van Gelderen" <jeroen@vangelderen.org>, Daniel Eischen <eischen@vigrid.com>, Jason Evans <jasone@canonware.com>, Luoqi Chen <luoqi@watermarkgroup.com>, smp@FreeBSD.ORG
Subject:   Re: SMP meeting summary
Message-ID:  <20000705162925.V25571@fw.wintelcom.net>
In-Reply-To: <200007052310.QAA27112@usr05.primenet.com>; from tlambert@primenet.com on Wed, Jul 05, 2000 at 11:10:39PM %2B0000
References:  <20000703220823.Z25571@fw.wintelcom.net> <200007052310.QAA27112@usr05.primenet.com>

index | next in thread | previous in thread | raw e-mail

* Terry Lambert <tlambert@primenet.com> [000705 16:11] wrote:
> > The idea is that for spin or spin-then-sleep mutexes (very short
> > hold time) is that since you won't have as many processes as cpus
> > contending (and when you do it's ok) that the mutual exclusion is
> > so short lived that by the time the next 'thundering' process is
> > actually given the CPU, the likelyhood is that other processes have
> > already aquired _and_ released the spinlock making it more than
> > likely that the reasource is free.
> > 
> > The idea is that the a quantum is actually so great that there's
> > little chance of one of the wake_all processes colliding on the
> > lock.
> 
> This is a bogus idea, both in the case of a large number of
> processors, and in quantum ownership case.

You are correct in that it's bogus for _large_ number of processors,
but for small numbers it makes a lot of sense.  It would work nicely
if one could attempt to schedule the processes in order that they
were unblocked.

Even on system with a signifigant amount of CPUs, sssuming the
system is busy, then between actually scheduling these thundering
processes on other CPUs and having them run there will be enough
time to avoid another pileup on the mutex.

If the CPUs are not busy and collisions occur, well then the
collisions are free because we have cycles to burn. :)

> The quantum ownership case is "so long as I have work to do, if
> the scheduler gave me a quantum, it's my damn quantum!".  In other
> words, the idea of voluntary preemption or semivoluntary preenption,
> such as one might get when the system makes a process blocke merely
> because it has made a system call that can't be immediately
> satisfied.  A multithreaded of FSA process doesn't care about a
> single blocking context: it wants to use the remainder of its
> quantum.

I'm not sure I understand this nor how it applies.

-- 
-Alfred Perlstein - [bright@wintelcom.net|alfred@freebsd.org]
"I have the heart of a child; I keep it in a jar on my desk."


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-smp" in the body of the message



help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000705162925.V25571>