Files
Piotr Gorski aeace822fe scheds: Drop dependencies that no scheduler source refers to
Cargo reports unused dependencies a few at a time, depending on which
packages a build includes, so removing the ones it named left others
to surface on the next build: regex in scx_pandemonium is the latest.
Rather than wait for each, go through every scheduler's [dependencies]
and drop the entries its Rust sources never mention, then let the
compiler have the last word, since code generated at build time can
use a crate the sources do not name.

- scx_pandemonium: regex.
- scx_lavd, scx_mavd: bitvec, hex, static_assertions, nix.
- scx_mitosis: bitvec, lazy_static, crossbeam.
- scx_nitosis: bitvec, lazy_static, libc, crossbeam.
- scx_p2dq: chrono, libc, static_assertions.
- scx_layered: bitvec.
- scx_cosmos: nvml-wrapper-sys.

`cargo check --all-targets` passes for scx_pandemonium, scx_lavd,
scx_mitosis, scx_p2dq, scx_layered and scx_cosmos without them. scx_mavd
and scx_nitosis carry the same entries as scx_lavd and scx_mitosis and
are changed the same way, except that scx_mitosis keeps libc: its
config.rs checks for libc::ENODEV when a cgroup is removed while its
cpuset is read.

scx_rustland and scx_rlfifo are left alone: plain, ctrlc, libc and
procfs do not appear in their own sources either, but the code
scx_rustland_core generates into them may well use them.

Signed-off-by: Piotr Gorski <lucjan.lucjanov@gmail.com>
2026-12-02 22:24:33 +01:00
..

scx_lavd

This is a single user-defined scheduler used within sched_ext, which is a Linux kernel feature which enables implementing kernel thread schedulers in BPF and dynamically loading them. Read more about sched_ext.

Overview

scx_lavd is a BPF scheduler that implements an LAVD (Latency-criticality Aware Virtual Deadline) scheduling algorithm. While LAVD is new and still evolving, its core ideas are 1) measuring how much a task is latency critical and 2) leveraging the task's latency-criticality information in making various scheduling decisions (e.g., task's deadline, time slice, etc.). As the name implies, LAVD is based on the foundation of deadline scheduling. This scheduler consists of the BPF part and the Rust part. The BPF part makes all the scheduling decisions; the Rust part provides high-level information (e.g., CPU topology) to the BPF code, loads the BPF code and conducts other chores (e.g., printing sampled scheduling decisions).

Typical Use Case

scx_lavd is initially motivated by gaming workloads. It aims to improve interactivity and reduce stuttering while playing games on Linux. Hence, this scheduler's typical use case involves highly interactive applications, such as gaming, which requires high throughput and low tail latencies.

Production Ready?

Yes, scx_lavd should be performant across various CPU architectures. It creates a separate scheduling domain per-LLC, per-core type (e.g., P or E core on Intel, big or LITTLE on ARM), and per-NUMA domain, so the default balanced profile or autopilot mode should be performant. It mainly targets single CCX / single-socket systems.