Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 10 Dec 1999 20:15:22 -0800
From:      Arun Sharma <adsharma@sharmas.dhs.org>
To:        Chuck Robey <chuckr@picnic.mat.net>
Cc:        Nate Williams <nate@mt.sri.com>, freebsd-arch@freebsd.org
Subject:   Re: Thread scheduling
Message-ID:  <19991210201522.A4535@sharmas.dhs.org>
In-Reply-To: <Pine.BSF.4.10.9912102103490.16082-100000@picnic.mat.net>; from Chuck Robey on Fri, Dec 10, 1999 at 09:14:11PM -0500
References:  <199912110135.SAA23495@mt.sri.com> <Pine.BSF.4.10.9912102103490.16082-100000@picnic.mat.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Dec 10, 1999 at 09:14:11PM -0500, Chuck Robey wrote:
> 
> I wasn't suggesting a *single* thread across multiple processors (as I
> think Arun asked).  Yes, that would be silly.  Is what I asked also silly,
> as a scheduling bias, not a guarantee or a requirement?  Or would it make
> no real difference?

This is also called gang scheduling in OS literature. From what I remember,
there are two advantages to this - both of them mainly applicable  to
timesharing systems

	- Minimize the average wait time

		This assumes that the related threads compete for some
		resources and when thread A releases a resource, it makes
		sense to schedule thread B, which was waiting on the
		resource to resume immediately, without further delay

	- When your memory cache is warm with the data from the swap

		If your system is swapping under load, it makes sense
		to run the threads together to completion, rather than
		swapping data in and out repeatedly.


However, such systems are not very common these days. Any performance
engineer will tell you that a system that swaps will not perform. And
no one cares about statistics like average wait time. You can buy a
fast CPU for < $100.

So I don't see any particular advantage to doing this on a system which
will most probably be used as a database server or a web server.

	-Arun





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




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