Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

scx: Add CI action that builds schedulers for PRs #40

Merged
merged 1 commit into from
Dec 19, 2023
Merged

scx: Add CI action that builds schedulers for PRs #40

merged 1 commit into from
Dec 19, 2023

Conversation

Byte-Lab
Copy link
Contributor

When Ubuntu ships with sched_ext, we can also maybe test loading the schedulers (not sure if the runners can run as root though). For now, we should at least have a CI job that lets us verify that the schedulers can build. To that end, this patch adds a basic CI action that builds the schedulers.

As is, this is a bit brittle in that we're having to manually download and install a few dependencies. I don't see a better way for now without hosting our own runners with our own containers, but that's a bigger investment. For now, hopefully this will get us some coverage.

@Byte-Lab
Copy link
Contributor Author

The CI check failed here even though it passed locally. Will convert to a draft and debug.

@Byte-Lab Byte-Lab marked this pull request as draft December 18, 2023 23:25
Copy link
Contributor

@htejun htejun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please merge whenever it's ready. Out of curiosity, why do we need thread dep in meson?

@Byte-Lab
Copy link
Contributor Author

Please merge whenever it's ready. Out of curiosity, why do we need thread dep in meson?

scx_userland was failing to resolve pthread_create(). Not sure why that's not happening locally, but must be some different dependency.

When Ubuntu ships with sched_ext, we can also maybe test loading the
schedulers (not sure if the runners can run as root though). For now, we
should at least have a CI job that lets us verify that the schedulers
can _build_. To that end, this patch adds a basic CI action that builds
the schedulers.

As is, this is a bit brittle in that we're having to manually download
and install a few dependencies. I don't see a better way for now without
hosting our own runners with our own containers, but that's a bigger
investment. For now, hopefully this will get us _some_ coverage.

Signed-off-by: David Vernet <[email protected]>
@Byte-Lab Byte-Lab marked this pull request as ready for review December 19, 2023 03:17
@Byte-Lab Byte-Lab merged commit eb7b3c9 into main Dec 19, 2023
1 check passed
@Byte-Lab Byte-Lab deleted the ci branch December 19, 2023 03:17
on: [pull_request]
jobs:
build-schedulers:
runs-on: ubuntu-20.04
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm wondering if we should target ubuntu-22.04 (or potentially even ubuntu-latest) instead, in this way we don't have to download llvm 17 or any other external package, all we need is in the distro.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another cool thing that we could do is to use virtme-ng (https://github.com/arighi/virtme-ng) to actually run the scx schedulers with any kernel that we want. In this case for example, we could apt download the latest kernel from my ppa (with the sched-ext support), unpack the kernel, then use vng -r /path/to/vmlinuz --user root -- scx_simple and test the scheduler without having to install a custom kernel.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm wondering if we should target ubuntu-22.04 (or potentially even ubuntu-latest) instead, in this way we don't have to download llvm 17 or any other external package, all we need is in the distro.

Heh, I'd originally tried to use ubuntu-22.04, but apt-add-repository was hanging for some of the external dependencies. If we can just use everything in the distro itself then that would be great. I'll spin up another PR to try and get it working.

Another cool thing that we could do is to use virtme-ng (https://github.com/arighi/virtme-ng) to actually run the scx schedulers with any kernel that we want. In this case for example, we could apt download the latest kernel from my ppa (with the sched-ext support), unpack the kernel, then use vng -r /path/to/vmlinuz --user root -- scx_simple and test the scheduler without having to install a custom kernel.

It would be great if we could use virtme-ng. I'd actually like to use that with the sched-ext repo as well, so if we can get it figured out here then I'll also get it setup there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants