DragonFly BSD
DragonFly commits List (threaded) for 2005-11
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

cvs commit: src/bin/ps print.c ps.1 ps.c src/sys/dev/raid/vinum vinumdaemon.c src/sys/emulation/linux/i386 linux_ptrace.c src/sys/emulation/posix4 ksched.c src/sys/emulation/svr4 svr4_misc.c src/sys/i386/i386 db_trace.c pmap.c procfs_machdep.c ...


From: Matthew Dillon <dillon@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Mon, 14 Nov 2005 10:50:18 -0800 (PST)

dillon      2005/11/14 10:50:18 PST

DragonFly src repository

  Modified files:
    bin/ps               print.c ps.1 ps.c 
    sys/dev/raid/vinum   vinumdaemon.c 
    sys/emulation/linux/i386 linux_ptrace.c 
    sys/emulation/posix4 ksched.c 
    sys/emulation/svr4   svr4_misc.c 
    sys/i386/i386        db_trace.c pmap.c procfs_machdep.c trap.c 
    sys/kern             init_main.c kern_exit.c kern_fork.c 
                         kern_proc.c kern_resource.c kern_sig.c 
                         kern_synch.c lwkt_thread.c sys_generic.c 
                         sys_process.c tty.c usched_bsd4.c 
                         vfs_sync.c 
    sys/netproto/smb     smb_subr.c 
    sys/sys              kernel.h proc.h systm.h thread.h 
    sys/vfs/procfs       procfs_ctl.c procfs_dbregs.c 
                         procfs_fpregs.c procfs_regs.c 
                         procfs_status.c 
    sys/vm               pmap.h vm_fault.c vm_glue.c vm_meter.c 
                         vm_pageout.c 
    usr.bin/systat       pigs.c 
    usr.bin/top          machine.c 
  Log:
  Make tsleep/wakeup() MP SAFE for kernel threads and get us closer to
  making it MP SAFE for user processes.  Currently the code is operating
  under the rule that access to a thread structure requires cpu locality of
  reference, and access to a proc structure requires the Big Giant Lock.  The
  two are not mutually exclusive so, for example, tsleep/wakeup on a proc
  needs both cpu locality of reference *AND* the BGL.  This was true with the
  old tsleep/wakeup and has now been documented.
  
  The new tsleep/wakeup algorithm is quite simple in concept.  Each cpu has its
  own ident based hash table and each hash slot has a cpu mask which tells
  wakeup() which cpu's might have the ident.  A wakeup iterates through all
  candidate cpus simply by chaining the IPI message through them until either
  all candidate cpus have been serviced, or (with wakeup_one()) the requested
  number of threads have been woken up.
  
  Other changes made in this patch set:
  
  * The sense of P_INMEM has been reversed.  It is now P_SWAPPEDOUT.  Also,
    P_SWAPPING, P_SWAPINREQ are not longer relevant and have been removed.
  
  * The swapping code has been cleaned up and seriously revamped.  The new
    swapin code staggers swapins to give the VM system a chance to respond
    to new conditions.  Also some lwp-related fixes were made (more
    p_rtprio vs lwp_rtprio confusion).
  
  * As mentioned above, tsleep/wakeup have been rewritten.  The process
    p_stat no longer does crazy transitions from SSLEEP to SSTOP.  There is
    now only SSLEEP and SSTOP is synthesized from P_SWAPPEDOUT for userland
    consumpion.  Additionally, tsleep() with PCATCH will NO LONGER STOP THE
    PROCESS IN THE TSLEEP CALL.  Instead, the actual stop is deferred until
    the process tries to return to userland.  This removes all remaining cases
    where a stopped process can hold a locked kernel resource.
  
  * A P_BREAKTSLEEP flag has been added.  This flag indicates when an event
    occurs that is allowed to break a tsleep with PCATCH.  All the weird
    undocumented setrunnable() rules have been removed and replaced with a
    very simple algorithm based on this flag.
  
  * Since the UAREA is no longer swapped, we no longer faultin() on PHOLD().
    This also incidently fixes the 'ps' command's tendancy to try to swap
    all processes back into memory.
  
  * speedup_syncer() no longer does hackish checks on proc0's tsleep channel
    (td_wchan).
  
  * Userland scheduler acquisition and release has now been tightened up and
    KKASSERT's have been added (one of the bugs Stefan found was related
    to an improper lwkt_schedule() that was found by one of the new assertions).
    We also have added other assertions related to expected conditions.
  
  * A serious race in pmap_release_free_page() has been corrected.  We
    no longer couple the object generation check with a failed
    pmap_release_free_page() call.  Instead the two conditions are checked
    independantly.  We no longer loop when pmap_release_free_page() succeeds
    (it is unclear how that could ever have worked properly).
  
  Major testing by: Stefan Krueger <skrueger@xxxxxxxxxxxxxxxx>
  
  Revision  Changes    Path
  1.24      +3 -3      src/bin/ps/print.c
  1.7       +1 -1      src/bin/ps/ps.1
  1.18      +3 -2      src/bin/ps/ps.c
  1.6       +1 -1      src/sys/dev/raid/vinum/vinumdaemon.c
  1.9       +2 -2      src/sys/emulation/linux/i386/linux_ptrace.c
  1.6       +4 -4      src/sys/emulation/posix4/ksched.c
  1.30      +1 -1      src/sys/emulation/svr4/svr4_misc.c
  1.11      +1 -1      src/sys/i386/i386/db_trace.c
  1.53      +15 -73    src/sys/i386/i386/pmap.c
  1.5       +7 -7      src/sys/i386/i386/procfs_machdep.c
  1.66      +32 -11    src/sys/i386/i386/trap.c
  1.51      +2 -2      src/sys/kern/init_main.c
  1.48      +1 -1      src/sys/kern/kern_exit.c
  1.44      +1 -1      src/sys/kern/kern_fork.c
  1.21      +10 -8     src/sys/kern/kern_proc.c
  1.24      +2 -2      src/sys/kern/kern_resource.c
  1.39      +137 -116  src/sys/kern/kern_sig.c
  1.53      +218 -212  src/sys/kern/kern_synch.c
  1.86      +13 -26    src/sys/kern/lwkt_thread.c
  1.23      +9 -4      src/sys/kern/sys_generic.c
  1.18      +9 -3      src/sys/kern/sys_process.c
  1.19      +1 -1      src/sys/kern/tty.c
  1.4       +28 -17    src/sys/kern/usched_bsd4.c
  1.8       +6 -7      src/sys/kern/vfs_sync.c
  1.16      +1 -1      src/sys/netproto/smb/smb_subr.c
  1.18      +1 -0      src/sys/sys/kernel.h
  1.72      +15 -14    src/sys/sys/proc.h
  1.33      +1 -0      src/sys/sys/systm.h
  1.73      +7 -0      src/sys/sys/thread.h
  1.8       +13 -4     src/sys/vfs/procfs/procfs_ctl.c
  1.7       +1 -1      src/sys/vfs/procfs/procfs_dbregs.c
  1.7       +1 -1      src/sys/vfs/procfs/procfs_fpregs.c
  1.8       +1 -1      src/sys/vfs/procfs/procfs_regs.c
  1.11      +5 -4      src/sys/vfs/procfs/procfs_status.c
  1.16      +0 -2      src/sys/vm/pmap.h
  1.20      +2 -1      src/sys/vm/vm_fault.c
  1.36      +96 -81    src/sys/vm/vm_glue.c
  1.8       +6 -6      src/sys/vm/vm_meter.c
  1.16      +4 -4      src/sys/vm/vm_pageout.c
  1.11      +1 -1      src/usr.bin/systat/pigs.c
  1.18      +1 -1      src/usr.bin/top/machine.c


http://www.dragonflybsd.org/cvsweb/src/bin/ps/print.c.diff?r1=1.23&r2=1.24&f=u
http://www.dragonflybsd.org/cvsweb/src/bin/ps/ps.1.diff?r1=1.6&r2=1.7&f=u
http://www.dragonflybsd.org/cvsweb/src/bin/ps/ps.c.diff?r1=1.17&r2=1.18&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/dev/raid/vinum/vinumdaemon.c.diff?r1=1.5&r2=1.6&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/emulation/linux/i386/linux_ptrace.c.diff?r1=1.8&r2=1.9&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/emulation/posix4/ksched.c.diff?r1=1.5&r2=1.6&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/emulation/svr4/svr4_misc.c.diff?r1=1.29&r2=1.30&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/i386/i386/db_trace.c.diff?r1=1.10&r2=1.11&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/i386/i386/pmap.c.diff?r1=1.52&r2=1.53&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/i386/i386/procfs_machdep.c.diff?r1=1.4&r2=1.5&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/i386/i386/trap.c.diff?r1=1.65&r2=1.66&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/init_main.c.diff?r1=1.50&r2=1.51&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/kern_exit.c.diff?r1=1.47&r2=1.48&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/kern_fork.c.diff?r1=1.43&r2=1.44&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/kern_proc.c.diff?r1=1.20&r2=1.21&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/kern_resource.c.diff?r1=1.23&r2=1.24&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/kern_sig.c.diff?r1=1.38&r2=1.39&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/kern_synch.c.diff?r1=1.52&r2=1.53&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/lwkt_thread.c.diff?r1=1.85&r2=1.86&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/sys_generic.c.diff?r1=1.22&r2=1.23&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/sys_process.c.diff?r1=1.17&r2=1.18&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/tty.c.diff?r1=1.18&r2=1.19&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/usched_bsd4.c.diff?r1=1.3&r2=1.4&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/kern/vfs_sync.c.diff?r1=1.7&r2=1.8&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/netproto/smb/smb_subr.c.diff?r1=1.15&r2=1.16&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/sys/kernel.h.diff?r1=1.17&r2=1.18&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/sys/proc.h.diff?r1=1.71&r2=1.72&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/sys/systm.h.diff?r1=1.32&r2=1.33&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/sys/thread.h.diff?r1=1.72&r2=1.73&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/procfs/procfs_ctl.c.diff?r1=1.7&r2=1.8&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/procfs/procfs_dbregs.c.diff?r1=1.6&r2=1.7&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/procfs/procfs_fpregs.c.diff?r1=1.6&r2=1.7&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/procfs/procfs_regs.c.diff?r1=1.7&r2=1.8&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vfs/procfs/procfs_status.c.diff?r1=1.10&r2=1.11&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vm/pmap.h.diff?r1=1.15&r2=1.16&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vm/vm_fault.c.diff?r1=1.19&r2=1.20&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vm/vm_glue.c.diff?r1=1.35&r2=1.36&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vm/vm_meter.c.diff?r1=1.7&r2=1.8&f=u
http://www.dragonflybsd.org/cvsweb/src/sys/vm/vm_pageout.c.diff?r1=1.15&r2=1.16&f=u
http://www.dragonflybsd.org/cvsweb/src/usr.bin/systat/pigs.c.diff?r1=1.10&r2=1.11&f=u
http://www.dragonflybsd.org/cvsweb/src/usr.bin/top/machine.c.diff?r1=1.17&r2=1.18&f=u



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