2 x quad-core system is slower that 2 x dual core on FreeBSD

Robert Watson rwatson at FreeBSD.org
Tue Dec 4 05:29:00 PST 2007

On Tue, 4 Dec 2007, Ivan Voras wrote:

> Krassimir Slavchev wrote:
>> There is another report for such problems:
>> http://blog.insidesystems.net/articles/2007/04/09/what-did-i-do-wrong
> Of course - FreeBSD 6.x is really bad at SMP where number of CPUs is larger 
> then about 2 and the loads include much kernel work (e.g. IO, context 
> switches). Numeric tasks (SSL) don't depend on the kernel and so they scale 
> ok. See http://people.freebsd.org/~kris/scaling/Scalability%20Update.pdf for 
> details.
> Another issue is interesting in this thread: that apparently 7.0 also has a 
> well defined workload where it fails.

There are several known contention points that are high on the list of targets 
for the 8-CURRENT branch, some hopefully with MFCs in time for 7.1.  These 
include contention on the tcbinfo lock, which protects global TCP data 
structures, and route table locking, which can affect high packets-per-second 
transmission on multiple CPUs at a time.  lockmgr is high on the list for 
optimization also, especially since it's an older-style sleep lock constructed 
out of a mutex and msleep.  When we optimized file descriptor locking in 7 
(which mostly impacted threaded applications, and was one of the primary 
sources of improvement for MySQL), it had a very similar construction as 
lockmgr currently has, and optimization made a very big difference.

Robert N M Watson
Computer Laboratory
University of Cambridge

More information about the freebsd-stable mailing list