Skip to content

Commit

Permalink
Merge pull request #23 from sched-ext/scx-6.9-rc7
Browse files Browse the repository at this point in the history
v6.9-scx1-rc7
  • Loading branch information
Byte-Lab authored May 8, 2024
2 parents 8a696a2 + a76b58e commit 3bca343
Show file tree
Hide file tree
Showing 12,843 changed files with 713,934 additions and 225,811 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
1 change: 1 addition & 0 deletions .get_maintainer.ignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Alan Cox <[email protected]>
Alan Cox <[email protected]>
Christoph Hellwig <[email protected]>
Jeff Kirsher <[email protected]>
Marc Gonzalez <[email protected]>
73 changes: 73 additions & 0 deletions .github/workflows/run-schedulers
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
#!/bin/bash
#
# Run sched-ext scheduler for TIMEOUT seconds inside virtme-ng and catch
# potential errors, then unload the scheduler and return the exit status.

# Maximum time for each scheduler run.
TEST_TIMEOUT=30

# Maximum timeout for the guest used for each scheduler run (this is used to
# hard-shutdown the guest in case of system hangs).
GUEST_TIMEOUT=60

# Check if virtme-ng is available.
if [ ! -x `which vng` ]; then
echo "vng not found, please install virtme-ng to enable testing"
exit 1
fi

function runtest() {
local bin="${1}"

if [ -z "${bin}" ]; then
echo "No binary passed to runtest"
exit 1
fi

if ! [ -f "${bin}" ]; then
echo "Binary ${bin} was not a regular file"
exit 1
fi

rm -f /tmp/output
(timeout --foreground --preserve-status ${GUEST_TIMEOUT} \
vng --force-9p --verbose -- \
"timeout --foreground --preserve-status ${TEST_TIMEOUT} ${bin}" \
2>&1 </dev/null || true) | tee /tmp/output
}

# Test all the available schedulers.
#
# NOTE: virtme-ng automatically runs the kernel from the current working
# directory by default.
#
# Each scheduler will be tested in a separate instance booted from scratch, to
# ensure that each run does not impact the others.
#
for sched in $(find tools/sched_ext/build/bin -type f -executable); do
runtest "${sched}"
grep -v " Speculative Return Stack Overflow" /tmp/output | \
sed -n -e '/\bBUG:/q1' \
-e '/\bWARNING:/q1' \
-e '/\berror\b/Iq1' \
-e '/\bstall/Iq1' \
-e '/\btimeout\b/Iq1'
res=$?
if [ ${res} -ne 0 ]; then
echo "FAIL: ${sched}"
exit 1
else
echo "OK: ${sched}"
fi
done

# Run the selftests suite
runtest "tools/testing/selftests/sched_ext/runner"
sed -n -e '/not ok/q1' /tmp/output
res=$?
if [ ${res} -ne 0 ]; then
echo "FAIL: selftests"
echo "output: $(cat /tmp/output)"
else
echo "OK: selftests"
fi
34 changes: 34 additions & 0 deletions .github/workflows/sched-ext.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# sched-ext mandatory options
#
CONFIG_BPF=y
CONFIG_BPF_SYSCALL=y
CONFIG_BPF_JIT=y
CONFIG_DEBUG_INFO_BTF=y
CONFIG_BPF_JIT_ALWAYS_ON=y
CONFIG_BPF_JIT_DEFAULT_ON=y
CONFIG_SCHED_CLASS_EXT=y

# Enable scheduling debugging
#
CONFIG_SCHED_DEBUG=y

# Enable extra scheduling features (for a better code coverage while testing
# the schedulers)
#
CONFIG_SCHED_AUTOGROUP=y
CONFIG_SCHED_CORE=y

# Enable fully preemptible kernel for a better test coverage of the schedulers
#
# CONFIG_PREEMPT_NONE is not set
# CONFIG_PREEMPT_VOLUNTARY is not set
CONFIG_PREEMPT=y
CONFIG_PREEMPT_COUNT=y
CONFIG_PREEMPTION=y
CONFIG_PREEMPT_DYNAMIC=y
CONFIG_PREEMPT_RCU=y

# Additional debugging information (useful to catch potential locking issues)
#
CONFIG_DEBUG_LOCKDEP=y
CONFIG_DEBUG_ATOMIC_SLEEP=y
56 changes: 56 additions & 0 deletions .github/workflows/test-kernel.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: test-kernel
run-name: ${{ github.actor }} PR run
on: [pull_request]
jobs:
test-schedulers:
runs-on: ubuntu-22.04
steps:
### OTHER REPOS ####

# Hard turn-off interactive mode
- run: echo 'debconf debconf/frontend select Noninteractive' | sudo debconf-set-selections

# Refresh packages list
- run: sudo apt update

### DOWNLOAD AND INSTALL DEPENDENCIES ###

# Download dependencies packaged by Ubuntu
- run: sudo apt -y install bc gcc make git coreutils cmake elfutils libelf-dev libunwind-dev libzstd-dev linux-headers-generic linux-tools-common linux-tools-generic ninja-build python3-pip python3-requests qemu-kvm udev iproute2 busybox-static libvirt-clients kbd kmod file rsync zstd pahole flex bison cpio libcap-dev libelf-dev python3-dev cargo rustc gcc-multilib

# clang 17
# Use a custom llvm.sh script which includes the -y flag for
# add-apt-repository. Otherwise, the CI job will hang. If and when
# https://github.com/opencollab/llvm-jenkins.debian.net/pull/26 is
# merged, we can go back to using https://apt.llvm.org/llvm.sh.
- run: wget https://raw.githubusercontent.com/Byte-Lab/llvm-jenkins.debian.net/fix_llvmsh/llvm.sh
- run: chmod +x llvm.sh
- run: sudo ./llvm.sh all
- run: sudo ln -sf /usr/bin/clang-17 /usr/bin/clang
- run: sudo ln -sf /usr/bin/llvm-strip-17 /usr/bin/llvm-strip

# Checkout repository
- uses: actions/checkout@v4

# Install virtme-ng
- run: pip install virtme-ng

### END DEPENDENCIES ###

# Build a minimal kernel (with sched-ext enabled) using virtme-ng
- run: vng -v --build --config .github/workflows/sched-ext.config

# Build the selftests suite
- run: make -j $(nproc) -C tools/testing/selftests/sched_ext

# Build the in-kernel schedulers
- run: make -j $(nproc) -C tools/sched_ext

# Setup KVM support
- run: |
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
sudo udevadm control --reload-rules
sudo udevadm trigger --name-match=kvm
# Test the schedulers inside the recompile kernel
- run: .github/workflows/run-schedulers
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
*.xz
*.zst
Module.symvers
dtbs-list
modules.order

#
Expand Down Expand Up @@ -170,3 +171,6 @@ sphinx_*/

# Rust analyzer configuration
/rust-project.json

# Include ".github" directory
!.github/
49 changes: 42 additions & 7 deletions .mailmap
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Adam Oldham <[email protected]>
Adam Radford <[email protected]>
Adriana Reus <[email protected]> <[email protected]>
Adrian Bunk <[email protected]>
Ajay Kaher <[email protected]> <[email protected]>
Akhil P Oommen <[email protected]> <[email protected]>
Alan Cox <[email protected]>
Alan Cox <[email protected]>
Expand All @@ -36,6 +37,17 @@ Alexei Avshalom Lazar <[email protected]> <[email protected]>
Alexei Starovoitov <[email protected]> <[email protected]>
Alexei Starovoitov <[email protected]> <[email protected]>
Alexei Starovoitov <[email protected]> <[email protected]>
Alexey Makhalov <[email protected]> <[email protected]>
Alex Elder <[email protected]>
Alex Elder <[email protected]> <[email protected]>
Alex Elder <[email protected]> <[email protected]>
Alex Elder <[email protected]> <[email protected]>
Alex Elder <[email protected]> <[email protected]>
Alex Elder <[email protected]> <[email protected]>
Alex Elder <[email protected]> <[email protected]>
Alex Elder <[email protected]> <[email protected]>
Alex Elder <[email protected]> <[email protected]>
Alex Elder <[email protected]> <[email protected]>
Alex Hung <[email protected]> <[email protected]>
Alex Shi <[email protected]> <[email protected]>
Alex Shi <[email protected]> <[email protected]>
Expand Down Expand Up @@ -96,6 +108,8 @@ Ben Widawsky <[email protected]> <[email protected]>
Ben Widawsky <[email protected]> <[email protected]>
Ben Widawsky <[email protected]> <[email protected]>
Benjamin Poirier <[email protected]> <[email protected]>
Benjamin Tissoires <[email protected]> <[email protected]>
Benjamin Tissoires <[email protected]> <[email protected]>
Bjorn Andersson <[email protected]> <[email protected]>
Bjorn Andersson <[email protected]> <[email protected]>
Bjorn Andersson <[email protected]> <[email protected]>
Expand All @@ -110,6 +124,7 @@ Brendan Higgins <[email protected]> <[email protected]>
Brian Avery <[email protected]>
Brian King <[email protected]>
Brian Silverman <[email protected]> <[email protected]>
Bryan Tan <[email protected]> <[email protected]>
Cai Huoqing <[email protected]> <[email protected]>
Can Guo <[email protected]> <[email protected]>
Carl Huang <[email protected]> <[email protected]>
Expand Down Expand Up @@ -191,10 +206,11 @@ Gao Xiang <[email protected]> <[email protected]>
Gao Xiang <[email protected]> <[email protected]>
Gao Xiang <[email protected]> <[email protected]>
Gao Xiang <[email protected]> <[email protected]>
Geliang Tang <[email protected]> <[email protected]>
Geliang Tang <[email protected]> <[email protected]>
Geliang Tang <[email protected]> <[email protected]>
Geliang Tang <[email protected]> <[email protected]>
Geliang Tang <[email protected]> <[email protected]>
Geliang Tang <[email protected]> <[email protected]>
Geliang Tang <[email protected]> <[email protected]>
Geliang Tang <[email protected]> <[email protected]>
Geliang Tang <[email protected]> <[email protected]>
Georgi Djakov <[email protected]> <[email protected]>
Gerald Schaefer <[email protected]> <[email protected]>
Gerald Schaefer <[email protected]> <[email protected]>
Expand Down Expand Up @@ -289,6 +305,7 @@ Johan Hovold <[email protected]> <[email protected]>
John Crispin <[email protected]> <[email protected]>
John Fastabend <[email protected]> <[email protected]>
John Keeping <[email protected]> <[email protected]>
John Moon <[email protected]> <[email protected]>
John Paul Adrian Glaubitz <[email protected]>
John Stultz <[email protected]>
<[email protected]> <[email protected]>
Expand Down Expand Up @@ -323,6 +340,7 @@ Kenneth W Chen <[email protected]>
Kenneth Westfield <[email protected]> <[email protected]>
Kiran Gunda <[email protected]> <[email protected]>
Kirill Tkhai <[email protected]> <[email protected]>
Kishon Vijay Abraham I <[email protected]> <[email protected]>
Konstantin Khlebnikov <[email protected]> <[email protected]>
Konstantin Khlebnikov <[email protected]> <[email protected]>
Koushik <[email protected]>
Expand All @@ -337,13 +355,15 @@ Lee Jones <[email protected]> <[email protected]>
Lee Jones <[email protected]> <[email protected]>
Lee Jones <[email protected]> <[email protected]>
Lee Jones <[email protected]> <[email protected]>
Leonard Crestez <[email protected]> Leonard Crestez <[email protected]>
Leonard Crestez <[email protected]> <[email protected]>
Leonard Crestez <[email protected]> <[email protected]>
Leonardo Bras <[email protected]> <[email protected]>
Leonard Göhrs <[email protected]>
Leonid I Ananiev <[email protected]>
Leon Romanovsky <[email protected]> <[email protected]>
Leon Romanovsky <[email protected]> <[email protected]>
Leon Romanovsky <[email protected]> <[email protected]>
Leo Yan <[email protected]> <[email protected]>
Liam Mark <[email protected]> <[email protected]>
Linas Vepstas <[email protected]>
Linus Lüssing <[email protected]> <[email protected]>
Expand Down Expand Up @@ -435,8 +455,11 @@ Mukesh Ojha <[email protected]> <[email protected]>
Muna Sinada <[email protected]> <[email protected]>
Murali Nalajala <[email protected]> <[email protected]>
Mythri P K <[email protected]>
Nadav Amit <[email protected]> <[email protected]>
Nadav Amit <[email protected]> <[email protected]>
Nadia Yvette Chambers <[email protected]> William Lee Irwin III <[email protected]>
Naoya Horiguchi <[email protected]> <[email protected]>
Naoya Horiguchi <[email protected]> <[email protected]>
Naoya Horiguchi <[email protected]> <[email protected]>
Nathan Chancellor <[email protected]> <[email protected]>
Neeraj Upadhyay <[email protected]> <[email protected]>
Neil Armstrong <[email protected]> <[email protected]>
Expand Down Expand Up @@ -489,9 +512,11 @@ Praveen BP <[email protected]>
Pradeep Kumar Chitrapu <[email protected]> <[email protected]>
Prasad Sodagudi <[email protected]> <[email protected]>
Punit Agrawal <[email protected]> <[email protected]>
Puranjay Mohan <[email protected]> <[email protected]>
Qais Yousef <[email protected]> <[email protected]>
Qais Yousef <[email protected]> <[email protected]>
Quentin Monnet <[email protected]> <[email protected]>
Quentin Monnet <[email protected]> <[email protected]>
Quentin Monnet <[email protected]> <[email protected]>
Quentin Perret <[email protected]> <[email protected]>
Rafael J. Wysocki <[email protected]> <[email protected]>
Rajeev Nandan <[email protected]> <[email protected]>
Expand All @@ -513,6 +538,7 @@ Rémi Denis-Courmont <[email protected]>
Ricardo Ribalda <[email protected]> <[email protected]>
Ricardo Ribalda <[email protected]> Ricardo Ribalda Delgado <[email protected]>
Ricardo Ribalda <[email protected]> <[email protected]>
Richard Genoud <[email protected]> <[email protected]>
Richard Leitner <[email protected]> <[email protected]>
Richard Leitner <[email protected]> <[email protected]>
Richard Leitner <[email protected]> <[email protected]>
Expand All @@ -521,6 +547,7 @@ Rocky Liao <[email protected]> <[email protected]>
Roman Gushchin <[email protected]> <[email protected]>
Roman Gushchin <[email protected]> <[email protected]>
Roman Gushchin <[email protected]> <[email protected]>
Ronak Doshi <[email protected]> <[email protected]>
Muchun Song <[email protected]> <[email protected]>
Muchun Song <[email protected]> <[email protected]>
Ross Zwisler <[email protected]> <[email protected]>
Expand Down Expand Up @@ -550,6 +577,7 @@ Senthilkumar N L <[email protected]> <[email protected]>
Serge Hallyn <[email protected]> <[email protected]>
Serge Hallyn <[email protected]> <[email protected]>
Seth Forshee <[email protected]> <[email protected]>
Shakeel Butt <[email protected]> <[email protected]>
Shannon Nelson <[email protected]> <[email protected]>
Shannon Nelson <[email protected]> <[email protected]>
Shannon Nelson <[email protected]> <[email protected]>
Expand All @@ -568,6 +596,7 @@ Simon Kelley <[email protected]>
Sricharan Ramabadhran <[email protected]> <[email protected]>
Srinivas Ramana <[email protected]> <[email protected]>
Sriram R <[email protected]> <[email protected]>
Stefan Wahren <[email protected]> <[email protected]>
Stéphane Witzmann <[email protected]>
Stephen Hemminger <[email protected]> <[email protected]>
Stephen Hemminger <[email protected]> <[email protected]>
Expand Down Expand Up @@ -605,6 +634,11 @@ TripleX Chung <[email protected]> <[email protected]>
TripleX Chung <[email protected]> <[email protected]>
Tsuneo Yoshioka <[email protected]>
Tudor Ambarus <[email protected]> <[email protected]>
Tvrtko Ursulin <[email protected]> <[email protected]>
Tvrtko Ursulin <[email protected]> <[email protected]>
Tvrtko Ursulin <[email protected]> <[email protected]>
Tvrtko Ursulin <[email protected]> <[email protected]>
Tvrtko Ursulin <[email protected]> <[email protected]>
Tycho Andersen <[email protected]> <[email protected]>
Tzung-Bi Shih <[email protected]> <[email protected]>
Uwe Kleine-König <[email protected]>
Expand Down Expand Up @@ -636,6 +670,7 @@ Viresh Kumar <[email protected]> <[email protected]>
Viresh Kumar <[email protected]> <[email protected]>
Viresh Kumar <[email protected]> <[email protected]>
Viresh Kumar <[email protected]> <[email protected]>
Vishnu Dasa <[email protected]> <[email protected]>
Vivek Aknurwar <[email protected]> <[email protected]>
Vivien Didelot <[email protected]> <[email protected]>
Vlad Dogaru <[email protected]> <[email protected]>
Expand Down
Loading

0 comments on commit 3bca343

Please sign in to comment.