[plug] New Toys

Oliver White ojw at iinet.net.au
Mon Aug 30 23:41:27 WST 1999


Gavin Tweedie wrote:
> 
> Oh and forgot to ask....
> 2.3.x or 2.2.x kernel?
> 
> How much better is the SMP in 2.3 than 2.2?

LWN.net had this to say, exactly...

Available at http://lwn.net/1999/0826/kernel.phtml
--------------------------------------------------------------------------
Spinlock metering is the latest kernel code contribution from SGI. Spin
locks are used in SMP kernels to control access to critical data
structures -
things that should not be touched by more than one processor at once.
Spinlocks are a potential performance killer, since a CPU that is unable
to
obtain a lock is not only blocked out of a particular resource, but it
must "spin"
and do nothing else until the lock is freed. For this reason, the Linux
kernel
has been slowly moving away from a "one big lock" architecture (used to
get
SMP working) to a much more fine-grained locking scheme. 

It has been hard, however, to know how effective many of these changes
have been. And it is almost impossible to know where to put further
development effort without knowing which locks are the real performance
problems. Thus, improving the scalability of the Linux kernel to more
processors requires a better understanding of lock behavior. Thus, lock
metering. 

Some of the initial results posted by SGI on their lock metering page
are
interesting. They ran a heavy test load on a four-processor system
running
2.2.10; the result was about 8% of the system's CPU time was spent
waiting
for locks. With 2.3.11, instead, the number of lock operations almost
tripled
(because there are many more locks), but the amount of time spent
waiting
for locks dropped to 2%. In other words, the work done to distribute
locks
through the kernel has been effective. 

This is an important contribution which will help Linux reach a point
where it
can work with large numbers of processors. It is nice to see SGI working
toward the improvement of the system in such a clear way. At times, at
least,
corporate involvement in Linux brings about tangible benefits for all
Linux
users. 
--------------------------------------------------------------------------


More information about the plug mailing list