aboutsummaryrefslogtreecommitdiff
path: root/sys/include
diff options
context:
space:
mode:
authorIan Moffett <ian@osmora.org>2025-05-19 00:50:54 -0400
committerIan Moffett <ian@osmora.org>2025-05-19 00:54:32 -0400
commitd2275fbf73f55e202d8e64726d8b5c23b70b15b0 (patch)
tree9582d2e09534ed6abf0a6e559b274622332ca6d4 /sys/include
parent0fa5f5f2c65d53bdc8d1a9337bc76e278dc304f2 (diff)
kernel: sched: Rewrite context switch logic
Simplify and improve context switch logic, also stops the LAPIC from being spammed with register accesses. This also updates the default quantum to 9000 us to avoid cache thrashing and all kinds of other nasty things. Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'sys/include')
-rw-r--r--sys/include/sys/schedvar.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/include/sys/schedvar.h b/sys/include/sys/schedvar.h
index 509e2c9..5ed9f5f 100644
--- a/sys/include/sys/schedvar.h
+++ b/sys/include/sys/schedvar.h
@@ -36,7 +36,7 @@
#include <machine/cdefs.h>
#if defined(_KERNEL)
-#define DEFAULT_TIMESLICE_USEC 500
+#define DEFAULT_TIMESLICE_USEC 9000
#define SHORT_TIMESLICE_USEC 10
#define SCHED_POLICY_MLFQ 0x00U /* Multilevel feedback queue */