DragonFly BSD
DragonFly kernel List (threaded) for 2003-10
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Scheduler updates for SMP and UP (mainly SMP)

From: Matthew Dillon <dillon@xxxxxxxxxxxxxxxxxxxx>
Date: Fri, 17 Oct 2003 00:47:33 -0700 (PDT)

    Ok, I've made some major changes to the scheduler.  There might be a 
    little instability but I hope not.

    libkvm and kvm utilities (ps, top, systat, etc) must be rebuilt after
    updating your includes.  If you already have a build world you can use
    the 'wmake' utility to build the above utilities
    (e.g. cd /usr/lib/libkvm; wmake obj; wmake), and then 'make install'
    (not wmake install).  wmake is a cute script which is part of the
    DragonFly /usr/bin dist which runs make using a buildworld environment
    in a subdirectory.

    process priorities as shown in 'ps' and 'top' have change radically.
    They now run on a linear scale from 0 to 384 or so.  e.g. realtime
    processes have priorities from 0-127, normal user processes from
    128-255, and so forth.

    There are a lot of scheduler changes, but the jist is that cpu bound
    processes and 'nice' factors should work properly now.  Note that the
    default nice spread is set such that a nice -20 cpu bound process will
    get about 90% of the cpu in the face of nice +0 processes.  Note that
    a nice -20 process will completely lockout a nice +2 process (or something
    like that).

    The affinity code is really nice... it accomplishes most of my goals
    including, most importantly, on my MP box when I run two nice +20
    cpu-bound loops I can still do a nice +0 buildkernel without any
    appreciable loss in performance:

      372.20 real       227.34 user        93.08 sys	with 2x nice +20 loops
      354.52 real       229.24 user        84.68 sys	without

					Matthew Dillon 

[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]