diff options
author | davidxu <davidxu@FreeBSD.org> | 2003-04-30 01:15:21 +0000 |
---|---|---|
committer | davidxu <davidxu@FreeBSD.org> | 2003-04-30 01:15:21 +0000 |
commit | 148de0f38fbdf8d86054ae8cc55c837e4d55c97b (patch) | |
tree | d580a930d2e600eb6c4e99c70adc1f2634a169e0 /lib/libkse | |
parent | d0537b4f6589beab0c56ad560e33a9cb428ddc17 (diff) | |
download | FreeBSD-src-148de0f38fbdf8d86054ae8cc55c837e4d55c97b.zip FreeBSD-src-148de0f38fbdf8d86054ae8cc55c837e4d55c97b.tar.gz |
Call kse_wakeup_mutli() after remove current thread from RUNQ to avoid
doing unnecessary idle kse wakeup.
Diffstat (limited to 'lib/libkse')
-rw-r--r-- | lib/libkse/thread/thr_kern.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libkse/thread/thr_kern.c b/lib/libkse/thread/thr_kern.c index c26279e..a153a4d 100644 --- a/lib/libkse/thread/thr_kern.c +++ b/lib/libkse/thread/thr_kern.c @@ -785,7 +785,6 @@ kse_sched_multi(struct kse *curkse) ; /* Nothing to do here. */ else if ((curthread->need_switchout == 0) && (curthread->blocked == 0) && (THR_IN_CRITICAL(curthread))) { - kse_wakeup_multi(curkse); /* * Resume the thread and tell it to yield when * it leaves the critical region. @@ -798,6 +797,7 @@ kse_sched_multi(struct kse *curkse) curthread->kse = curkse; DBG_MSG("Continuing thread %p in critical region\n", curthread); + kse_wakeup_multi(curkse); if (curthread->lock_switch) { KSE_SCHED_LOCK(curkse, curkse->k_kseg); ret = _thread_switch(&curthread->tmbx, 0); |