- FreeBSD (ULE) vs Linux scheduler(CFS) - stackoverflow
- FreeBSD ULE vs Linux scheduler CFS - usenix
- FreeBSD scheduler
- MacOS kern/sched.h - github
- MacOS XNU vs Linux sched
- Evolution of the x86 context switch in Linux - switch_to()
- Context_Switching - osdev.org
Linux - CFS is short for Completely Fair Scheduler. The most notable difference is that CFS is not based on run queues for process selection. Instead, it uses a red-black tree with O(log N) complexity that is indexed by CPU time spent. SCHED_NORMAL (traditionally called SCHED_OTHER): The scheduling policy that is used for regular tasks.
SCHED_BATCH: Does not preempt nearly as often as regular tasks would, thereby allowing tasks to run longer and make better use of caches but at the cost of interactivity. This is well suited for batch jobs.
SCHED_IDLE: This is even weaker than nice 19, but its not a true idle timer scheduler in order to avoid to get into priority inversion problems which would deadlock the machine.
SCHED_FIFO/_RR are implemented in sched/rt.c and are as specified by POSIX.
FreeBSD - ULE is the successor to the traditional BSD scheduler. It offers much improved performance on SMP systems as well as uniprocessor systems. It follows a more traditional design with run queues and time slices. It strives to be fair, but can be instructed to favor interactive processes.
Qnx - To meet the needs of various applications, QNX Neutrino provides these scheduling policies:
- FIFO scheduling — SCHED_FIFO (voluntarily relinquishes control (e.g., it blocks), or is preempted by a higher-priority thread)
- Round-robin scheduling — SCHED_RR (voluntarily relinquishes control, or is preempted by a higher-priority thread, or consumes its timeslice)
- Sporadic scheduling — SCHED_SPORADIC (to provide a capped limit on the execution time of a thread within a given period of time.)
macOS - The OS X scheduler is derived from the scheduler used in OSFMK 7.3. Thread priority bands: Normal, System high priority, Kernel mode only, Real-time threads.
- Overview - hardwaretimes
- CPU cache - wiki
- Cache_placement_policies - wiki
- Mapping the Intel Last-Level Cache - 2015, iacr pdf
- Modern Operating Systems, Tanenbaum - 2015
- Expert C Programming, Deep C Secrets, van der Linden - 1994