Commit Graph

1682 Commits

Author SHA1 Message Date
Daniel Hodges
aee19dd9a1 scx_layered: Add topology aware core growth selection
Add topology aware core growth selection.

Signed-off-by: Daniel Hodges <hodges.daniel.scott@gmail.com>
2024-09-12 06:48:51 -07:00
Daniel Hodges
be1020f517
Merge pull request #650 from frelon/update-tumbleweed-docs
update Tumbleweed installation notes
2024-09-12 09:05:13 -04:00
Daniel Hodges
e9a7d5ce16
Merge pull request #651 from hodgesds/layered-random
scx_layered: Add random layer growth algo
2024-09-12 08:56:45 -04:00
Daniel Hodges
14a19dc3ca scx_layered: Add random layer growth algo
Add a random layer growth algo.

Signed-off-by: Daniel Hodges <hodges.daniel.scott@gmail.com>
2024-09-12 05:35:54 -07:00
Fredrik Lönnegren
7d7bf94bb0 update Tumbleweed installation notes
Kernel package name was change to kernel-default.

Also add link to documentation to README.md

Signed-off-by: Fredrik Lönnegren <fredrik@frelon.se>
2024-09-12 10:28:03 +02:00
Jake Hillion
8ca45cfa37
lint: enable cargo fmt (#643)
Use `cargo fmt` with a specific nightly branch in the CI to enforce formatting. Globally format these files while the diff is still small so we can stay on top of it.

Test plan:
- CI lint check passes.
2024-09-11 10:03:20 +01:00
Tejun Heo
8f0cc89ee8
Merge pull request #645 from frelon/rusty-init-dom
scx_rusty: init domains when calculating averages
2024-09-10 12:25:51 -10:00
Andrea Righi
e6e3579a92
Merge pull request #634 from anh0516/main
scx_bpfland: Documentation consistency fix
2024-09-10 23:25:55 +02:00
Fredrik Lönnegren
f155966b77 scx_rusty: init domains when calculating averages
The domains are added to the aggregator when load is added (and
duty_cycle is not 0.0f64).

This commit makes sure that all domains are added to the aggregator even
when the calculated duty_cycle is 0.

Signed-off-by: Fredrik Lönnegren <fredrik@frelon.se>
2024-09-10 21:51:41 +02:00
likewhatevs
85863d0e1c
Merge pull request #644 from hodgesds/layered-topo-order
scx_layered: Pass layer spec for core growth algo
2024-09-10 14:49:37 -04:00
Daniel Hodges
5fdd257862 scx_layered: Pass layer spec for core growth algo
Pass in the layer spec when determining the layer core growth algo. This
should make it easier to implement layer growth algos that are spec
specific.

Signed-off-by: Daniel Hodges <hodges.daniel.scott@gmail.com>
2024-09-10 10:27:08 -07:00
Daniel Hodges
8f8fe1b2c1
Merge pull request #642 from samuelnair/main
scx_layered: Fix typo in stats
2024-09-10 13:20:01 -04:00
likewhatevs
ffe8ca31e5
Merge pull request #641 from likewhatevs/migrate-ci-24.04
migrate ci vm to 24.04
2024-09-10 11:46:43 -04:00
Samuel Nair
c6af1aa1c8 scx_layered: Fix typo in stats 2024-09-10 08:44:57 -07:00
patso
28319f3205
migrate ci vm to ubuntu 24.04
migrate ci vm to ubuntu 24.04
2024-09-10 09:53:40 -04:00
likewhatevs
c4c3659b6d
Merge pull request #638 from likewhatevs/remove-rlimit-dep
remove dependency on rlimit.rs
2024-09-10 03:14:12 -04:00
Andrea Righi
8efe786799
Merge pull request #640 from sched-ext/bpfland-used-time-slice
scx_bpfland: use sum_exec_runtime to evaluate task's used time slice
2024-09-10 09:10:52 +02:00
Andrea Righi
655ed5b4c6 scx_bpfland: use sum_exec_runtime to evaluate task's used time slice
Using p->scx.slice to evaluate the consumed time slice can be a bit
imprecise, because the sched_ext core implements yielding by setting
p->scx.slice to 0.

When the task's vruntime is evaluated this is considered as the task has
exhausted its entire allocated time slice, even though it voluntarily
released the CPU before the slice fully expired.

To avoid this inaccuracy and prevent penalizing tasks that voluntarily
release the CPU, always evaluate the used time slice based on the
difference in the task's total execution time (p->se.sum_exec_runtime).

This method provides a more precise calculation of vruntime and results
in a fairer task's deadline evaluation.

Signed-off-by: Andrea Righi <andrea.righi@linux.dev>
2024-09-10 08:03:35 +02:00
patso
c1df85914b
remove dependency on rlimit.rs
the rlimit crate is the only dependency crate
with a build.rs. build.rs files complicate portability.
this removes the need for rlimit.rs
2024-09-10 01:16:53 -04:00
Daniel Hodges
f3b7016a46
Merge pull request #633 from likewhatevs/add-pages
enable docs generation and upload
2024-09-09 19:12:23 -04:00
patso
2e46f71780
generate docs for scx and kernel
generate docs for scx and kernel and push to gh page

this "adds" kernel scheduler and bpf docs to
the generated scx rust docs.
2024-09-09 15:37:59 -04:00
Tejun Heo
249121f15f
Merge pull request #635 from sched-ext/htejun/build
build: Use a single top-level rust workspace
2024-09-08 21:57:27 -10:00
Tejun Heo
b2a71b166e build: Remove unused rust/meson.build
The previous commit makes this file unused but forgot to remove it. Remove
it.
2024-09-08 20:00:35 -10:00
Tejun Heo
56bb963136 build: Use a single top-level rust workspace
Rust build was using two separate workspaces - rust/ and scheds/rust.
There's no reason to separate them and it makes doc generation tricky. Use
single top level workspace so that we can drive all rust building from
cargo.
2024-09-08 14:23:48 -10:00
Andrea Righi
134846c366
Merge pull request #632 from likewhatevs/split-integration-test
split integration test execution
2024-09-08 16:25:10 +02:00
patso
120211d731
split build and test jobs
split build and test jobs to reduce ci turnaround time
and make it clear what is failing when something fails.

also add virtiofsd to deps to make test compilation faster
(most test time is compliation) and remove all force 9ps.
2024-09-08 02:54:24 -04:00
Andrea Righi
92b887c8e4
Merge pull request #629 from sched-ext/scx-rustland-core-fix-crate
scx_rustland_core: move includes back to the lib section
2024-09-07 20:15:10 +02:00
Tejun Heo
10c16cc443
Merge pull request #628 from sched-ext/htejun/release
release: Add cargo-publish.py
2024-09-07 07:50:34 -10:00
Tejun Heo
bc67796658 release: Add cargo-publish.py
A helper script to publish all rust crates in the repo.
2024-09-07 07:34:17 -10:00
Andrea Righi
1e26cb91f1 scx_rustland_core: move includes back to the lib section
Move included artifacts in the lib section (without this change we can't
publish the crate on crates.io).

Fixes: 082bccb ("fix/enable rust tests, make build faster")
Signed-off-by: Andrea Righi <andrea.righi@linux.dev>
2024-09-07 19:32:08 +02:00
Tejun Heo
fcea4d3729 scx_loader: Fix broken LICENSE symlink 2024-09-07 07:16:22 -10:00
Andrea Righi
155a10d373
Merge pull request #627 from sched-ext/ci-fix-vng-cpu-command
ci: fix vng command to set the right amount of CPUs
2024-09-07 10:11:32 +02:00
Andrea Righi
8ff57ac915 ci: fix vng command to set the right amount of CPUs
The right options to set the amount of CPUs in vng is `-p`, not `-c`.
Change the command to use the long format `--cpu` and `--memory` for
better clarity.

This fixes issue #625.

Signed-off-by: Andrea Righi <andrea.righi@linux.dev>
2024-09-07 09:47:13 +02:00
Changwoo Min
17e0e08e6e
Merge pull request #621 from multics69/lavd-greedy-fix
scx_lavd: improve greedy ratio calculation and more
2024-09-07 10:52:00 +09:00
Tejun Heo
6f8917ceca
Merge pull request #624 from JakeHillion/cleanup-layer_growth_algo
scx_layered: clean up Layer::new layer_growth_algo
2024-09-06 15:10:41 -10:00
Avraham Hollander
f71cc646a3 scx_bpfland: Fix in README.md for the same text as a comment in the
source
2024-09-06 19:12:33 -04:00
Andrea Righi
9301d7d78a
Merge pull request #622 from sched-ext/rustland-core-topology-awareness
scx_rustland_core: introduce topology awareness
2024-09-06 23:11:49 +02:00
Andrea Righi
0a8dc0135b
Merge pull request #623 from likewhatevs/main
fix/enable rust tests, make build faster
2024-09-06 23:11:18 +02:00
Jake Hillion
2c008b2afa scx_layered: clean up Layer::new layer_growth_algo 2024-09-06 18:25:50 +01:00
patso
eaa636dfcc
set vng cpus to 8 for rust tests
set vng cpus to 8 for rust tests (for stability in testing),
update relevant doc test.
2024-09-06 10:07:37 -04:00
Changwoo Min
36df970a8f scx_lavd: add debug print for turbo cores
Signed-off-by: Changwoo Min <changwoo@igalia.com>
2024-09-06 19:23:17 +09:00
Changwoo Min
351a1c6656 scx_lavd: enable autopilot mode by default
Signed-off-by: Changwoo Min <changwoo@igalia.com>
2024-09-06 19:23:12 +09:00
patso
082bccb557
fix/enable rust tests, make build faster
This commit fixes rust tests and configures ci to
run them on commit. It also sets up CI to run those
in a timely manner by caching dependencies and splitting jobs.
2024-09-06 06:18:11 -04:00
Andrea Righi
8231f8586a scx_rlfifo: better documentation and code readability
Simplify scx_rlfifo code, add detailed documentation of the
scx_rustland_core API and get rid of the additional task queue, since it
just makes the code bigger, slower and it doesn't really provide any
benefit (considering that we are dispatching the tasks in FIFO order
anyway).

Signed-off-by: Andrea Righi <andrea.righi@linux.dev>
2024-09-06 11:25:24 +02:00
Andrea Righi
168fb78387 scx_rustland_core: introduce cache awareness
Introduce some concepts of cache awareness (taken from scx_bpfland).

This change is transparently affecting the BpfScheduler::select_cpu()
API, even if the particular cache topology is not (yet) exposed to the
user-space.

When calling select_cpu() the backend will prioritize idle CPUs that
share the same L2 cache, then the same L3 cache, considering the target
CPU specified in select_cpu() (usually the task's previously used CPU).

Signed-off-by: Andrea Righi <andrea.righi@linux.dev>
2024-09-06 11:25:24 +02:00
Andrea Righi
ed879bae28 scx_rustland_core: expose enq_flags to user-space
Pass the enqueue flags to the user-space scheduler through the
QueuedTask struct.

These flags allow the user-space scheduler to make more informed
scheduling decisions.

Also bump up scx_rustland_core minor version to reflect the new API (we
are not breaking the old API, so we don't need to bump the major version
in this case).

Signed-off-by: Andrea Righi <andrea.righi@linux.dev>
2024-09-06 11:25:24 +02:00
Changwoo Min
ebe9375b6a scx_lavd: pretty printing of status
Signed-off-by: Changwoo Min <changwoo@igalia.com>
2024-09-06 16:27:20 +09:00
Changwoo Min
461cb9a3a0 scx_lavd: fix calculation of greedy_ratio
The service time (taskc->svc_time) should be the sum of total CPU time
consumed not jut a delta.

Signed-off-by: Changwoo Min <changwoo@igalia.com>
2024-09-06 16:22:40 +09:00
Tejun Heo
fb35fdb6f2
Merge pull request #620 from sched-ext/htejun/release
version: v1.0.4
2024-09-05 18:13:13 -10:00
Tejun Heo
46fc2e1a49 version: v1.0.4 2024-09-05 18:12:45 -10:00