cvs commit: src/sys/kern sched_ule.c

Jeff Roberson jeff at FreeBSD.org
Fri Jan 19 21:56:08 UTC 2007


jeff        2007-01-19 21:56:08 UTC

  FreeBSD src repository

  Modified files:
    sys/kern             sched_ule.c 
  Log:
  Major revamp of ULE's cpu load balancing:
   - Switch back to direct modification of remote CPU run queues.  This added
     a lot of complexity with questionable gain.  It's easy enough to
     reimplement if it's shown to help on huge machines.
   - Re-implement the old tdq_transfer() call as tdq_pickidle().  Change
     sched_add() so we have selectable cpu choosers and simplify the logic
     a bit here.
   - Implement tdq_pickpri() as the new default cpu chooser.  This algorithm
     is similar to Solaris in that it tries to always run the threads with
     the best priorities.  It is actually slightly more complex than
     solaris's algorithm because we also tend to favor the local cpu over
     other cpus which has a boost in latency but also potentially enables
     cache sharing between the waking thread and the woken thread.
   - Add a bunch of tunables that can be used to measure effects of different
     load balancing strategies.  Most of these will go away once the
     algorithm is more definite.
   - Add a new mechanism to steal threads from busy cpus when we idle.  This
     is enabled with kern.sched.steal_busy and kern.sched.busy_thresh.  The
     threshold is the required length of a tdq's run queue before another
     cpu will be able to steal runnable threads.  This prevents most queue
     imbalances that contribute the long latencies.
  
  Revision  Changes    Path
  1.179     +293 -240  src/sys/kern/sched_ule.c


More information about the cvs-src mailing list