Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 30 Mar 2012 16:31:36 +0400
From:      Slawa Olhovchenkov <slw@zxy.spb.ru>
To:        Alexander Motin <mav@FreeBSD.org>
Cc:        svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org
Subject:   Re: svn commit: r233599 - stable/9/sys/kern
Message-ID:  <20120330123136.GF61230@zxy.spb.ru>
In-Reply-To: <201203281137.q2SBb65O033656@svn.freebsd.org>
References:  <201203281137.q2SBb65O033656@svn.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Mar 28, 2012 at 11:37:06AM +0000, Alexander Motin wrote:

> Author: mav
> Date: Wed Mar 28 11:37:06 2012
> New Revision: 233599
> URL: http://svn.freebsd.org/changeset/base/233599
> 
> Log:
>   MFC r232207, r232454:
>   Rework CPU load balancing in SCHED_ULE:
>    - In sched_pickcpu() be more careful taking previous CPU on SMT systems.
>   Do it only if all other logical CPUs of that physical one are idle to avoid
>   extra resource sharing.
>    - In sched_pickcpu() change general logic of CPU selection. First
>   look for idle CPU, sharing last level cache with previously used one,
>   skipping SMT CPU groups. If none found, search all CPUs for the least loaded
>   one, where the thread with its priority can run now. If none found, search
>   just for the least loaded CPU.
>    - Make cpu_search() compare lowest/highest CPU load when comparing CPU
>   groups with equal load. That allows to differentiate 1+1 and 2+0 loads.
>    - Make cpu_search() to prefer specified (previous) CPU or group if load
>   is equal. This improves cache affinity for more complicated topologies.
>    - Randomize CPU selection if above factors are equal. Previous code tend
>   to prefer CPUs with lower IDs, causing unneeded collisions.
>    - Rework periodic balancer in sched_balance_group(). With cpu_search()
>   more intelligent now, make balansing process flat, removing recursion
>   over the topology tree. That fixes double swap problem and makes load
>   distribution more even and predictable.
>   
>   All together this gives 10-15% performance improvement in many tests on
>   CPUs with SMT, such as Core i7, for number of threads is less then number
>   of logical CPUs. In some tests it also gives positive effect to systems
>   without SMT.
>   
>   Sponsored by:	iXsystems, Inc.

Nice! Now X3430 completely silent in idle system.



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