Do some minor critical path performance improvements in the scheduler
authorMatthew Dillon <dillon@dragonflybsd.org>
Sat, 10 Apr 2004 20:55:24 +0000 (20:55 +0000)
committerMatthew Dillon <dillon@dragonflybsd.org>
Sat, 10 Apr 2004 20:55:24 +0000 (20:55 +0000)
commit37af14fe41b9d0e8b4ef272d31aeed4dcc888c37
treea67e594fe9d408dbe5ee249793ac671b36d63ad6
parent8ebcad3f3a1a9b369bc8f4dbb3e74b92f43d01c7
Do some minor critical path performance improvements in the scheduler
and at the user/system boundary.  Avoid some unnecessary segment prefix ops,
remove some unnecessary memory ops by using more optimal critical
section inlines, and use 32 bit arithmatic instead of 64 bit arithmatic
when calculating system tick overheads in userret().

This saves a whopping 5ns worth of syscall overhead, which just proves
how silly I am sometimes.
16 files changed:
sys/i386/i386/trap.c
sys/i386/i386/vm_machdep.c
sys/i386/isa/intr_machdep.c
sys/kern/kern_resource.c
sys/kern/kern_sig.c
sys/kern/kern_switch.c
sys/kern/kern_synch.c
sys/kern/kern_time.c
sys/kern/lwkt_msgport.c
sys/kern/lwkt_thread.c
sys/platform/pc32/i386/trap.c
sys/platform/pc32/i386/vm_machdep.c
sys/platform/pc32/isa/intr_machdep.c
sys/sys/proc.h
sys/sys/thread.h
sys/sys/thread2.h