git: 754d2c69f358 - main - NOTES: Multiple schedulers can be compiled in at once
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 25 Sep 2026 15:39:58 UTC
The branch main has been updated by olce:
URL: https://cgit.FreeBSD.org/src/commit/?id=754d2c69f3589cdd0bc4649d9e85ecd59935d9d3
commit 754d2c69f3589cdd0bc4649d9e85ecd59935d9d3
Author: Olivier Certner <olce@FreeBSD.org>
AuthorDate: 2026-09-24 16:23:05 +0000
Commit: Olivier Certner <olce@FreeBSD.org>
CommitDate: 2026-09-25 15:35:40 +0000
NOTES: Multiple schedulers can be compiled in at once
Mention that ULE is the default scheduler when multiple ones are
compiled in and how the tunable 'kern.sched.name' can be used to select
another one.
While here, regroup SCHED_ULE and SCHED_4BSD, as they control if the
respective scheduler instances are compiled in, putting SCHED_STATS
aside.
Reviewed by: mchoo
Fixes: 75a66a92c92f ("- Add an option to compile in SCHED_STATS. ...")
Fixes: 1322760fd127 ("sys: enable both SCHED_ULE and SCHED_4BSD for some configs")
MFC after: 3 days
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D60014
---
sys/conf/NOTES | 17 ++++++++++-------
1 file changed, 10 insertions(+), 7 deletions(-)
diff --git a/sys/conf/NOTES b/sys/conf/NOTES
index 656dee2bb262..3bc553ce7b5b 100644
--- a/sys/conf/NOTES
+++ b/sys/conf/NOTES
@@ -192,8 +192,12 @@ options ROOTDEVNAME=\"ufs:da0s2e\"
#####################################################################
# Scheduler options:
#
-# Specifying one of SCHED_4BSD or SCHED_ULE is mandatory. These options
-# select which scheduler is compiled in.
+# The options below select the schedulers that are compiled in. Specifying at
+# least one is mandatory. Multiple ones can be compiled in. At boot, the
+# kernel will use ULE by default if present, with a fallback to one of the
+# compiled-in options. A specific scheduler can be requested by setting the
+# 'kern.sched.name' tunable to a scheduler name, i.e., one of the options below
+# with the SCHED_ prefix removed.
#
# SCHED_4BSD is the historical, proven, BSD scheduler. It has a global run
# queue and no CPU affinity which makes it suboptimal for SMP. It has very
@@ -202,15 +206,14 @@ options ROOTDEVNAME=\"ufs:da0s2e\"
# SCHED_ULE provides significant performance advantages over 4BSD on many
# workloads on SMP machines. It supports cpu-affinity, per-cpu runqueues
# and scheduler locks. It also has a stronger notion of interactivity
-# which leads to better responsiveness even on uniprocessor machines. This
-# is the default scheduler.
-#
+# which leads to better responsiveness even on uniprocessor machines.
+options SCHED_4BSD
+options SCHED_ULE
+
# SCHED_STATS is a debugging option which keeps some stats in the sysctl
# tree at 'kern.sched.stats' and is useful for debugging scheduling decisions.
#
-options SCHED_4BSD
options SCHED_STATS
-options SCHED_ULE
#####################################################################
# SMP OPTIONS: