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

CI: Adjust GitHub Actions parallel job counts #12927

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Ayesh
Copy link
Contributor

@Ayesh Ayesh commented Feb 12, 2024

Adjusts the make -j flag to match the latest GitHub-hosted runner hardware specs1:

  • ubuntu-latest on 4 CPU cores
  • macos-latest on 3 CPU cores

The processor count is ideally obtained from nproc, but setting env vars from the current CI yaml files is not possible because they expect literal strings.

Footnotes

  1. https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners#standard-github-hosted-runners-for-public-repositories

Adjusts the `make -j` flag to match the latest GitHub-hosted runner hardware specs[^1]:

 - `ubuntu-latest` on 4 CPU cores
 - `macos-latest` on 3 CPU cores

The processor count is ideally obtained from `nproc`, but setting env vars from the current
CI yaml files is not possible because they expect literal strings.

[^1]: https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners#standard-github-hosted-runners-for-public-repositories
@github-actions github-actions bot added the CI Continuous Integration label Feb 12, 2024
@pheiduck
Copy link
Contributor

pheiduck commented Feb 12, 2024

Why not using $(nproc)+1?

@Ayesh
Copy link
Contributor Author

Ayesh commented Feb 12, 2024

The root level env keys cannot have variables expanded, so they have to be hardcoded or taken from the context. At least I couldn't figure it out.

We could setup the env var before calling make, but I wanted to keep the change set minimal.

@dfandrich
Copy link
Contributor

dfandrich commented Feb 12, 2024 via email

@Ayesh
Copy link
Contributor Author

Ayesh commented Feb 12, 2024

Thank you @dfandrich - I saw your commit that added parallel CI jobs and the discussions around it.

GitHub recently doubled the specs of their hosted runners, so this one tries to take advantage of it. I could run this locally with make -j16, and the PR seems to pass CI too, so perhaps the issues are now ironed out?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI Continuous Integration
Development

Successfully merging this pull request may close these issues.

None yet

3 participants