diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2016-03-28 20:49:59 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2016-03-28 20:49:59 +0000 |
commit | f8a39e8f2370556ece725f86a978f083729f883f (patch) | |
tree | 15ad8598c8247512ff422c316f080c54fee2b642 /sys/kern/vfs_default.c | |
parent | a1f43f3fd80d2ba4f6c7087f8a04a4c9245ae420 (diff) |
Make sure that a thread that calls sched_yield(2) ends up on the run queue
behind all other threads in the process by temporarily lowering its priority.
This isn't optimal but it is the easiest way to guarantee that we make
progress when we're waiting on an other thread to release a lock. This
results in significant improvements for processes that suffer from lock
contention, most notably firefox. Unfortunately this means that sched_yield(2)
needs to grab the kernel lock again.
All the hard work was done by mpi@, based on observations of the behaviour
of the BFS scheduler diff by Michal Mazurek.
ok deraadt@
Diffstat (limited to 'sys/kern/vfs_default.c')
0 files changed, 0 insertions, 0 deletions