git: kernel - Fix MP system call performance regression

看板DFBSD_commit作者時間15年前 (2010/12/10 16:32), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/1
commit 911d4144e391f5518957ca6012034414c8226203 Author: Matthew Dillon <dillon@apollo.backplane.com> Date: Thu Dec 9 23:53:44 2010 -0800 kernel - Fix MP system call performance regression * The userland scheduler was unconditionally calling lwkt_switch() via userexit() (i.e. on every system call), creating unnecessary overhead and possibly also triggering a bsd4 scheduler event requiring a common spinlock. * Rearrange the code slightly to reduce instances where lwkt_switch() is called. We want to try to keep instances where a higher priority LWKT thread is potentially runnable or when the LWKT fairq accumulator for the current thread has been exhausted. * This removes system call overhead multiplication on MP systems. For example, on a 48-core box system call overhead when all 48 cpus are busy doing getuid() loops went from 10uS back down to 270nS (which is near the single-cpu test results). Summary of changes: sys/kern/usched_bsd4.c | 8 ++++++-- 1 files changed, 6 insertions(+), 2 deletions(-) http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/911d4144e391f5518957ca6012034414c8226203 -- DragonFly BSD source repository
文章代碼(AID): #1D0UM6k6 (DFBSD_commit)