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

Add support for adjusting the thread scheduling policy #1044

Merged
merged 1 commit into from
Jan 29, 2018

Conversation

gittyupagain
Copy link
Contributor

In order to properly get thread priorities working on Unix-like operating systems, a realtime scheduler needs to be used. This PR provides the ability to adjust the scheduler to be used when creating a new thread.

Copy link
Contributor

@jdonald jdonald left a comment

Choose a reason for hiding this comment

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

All looks good here. That CAS loop can never really busy-wait even if two threads attempt to set priority at the same time, all tests still pass, Windows behavior is unaffected, and we now have a straightforward path to test with SCHED_FIFO.

@jdonald jdonald merged commit 6ebc149 into master Jan 29, 2018
@jdonald jdonald deleted the feat-thread-sched-policy branch January 29, 2018 21:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants