-
Notifications
You must be signed in to change notification settings - Fork 166
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 sched_getscheduler
& sched_setscheduler
#1195
base: main
Are you sure you want to change the base?
Conversation
fe41569
to
abf9ee5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you say more about the use case that motivates this PR? In #1183, the reporter actually needed pthread_setschedparam
etc., which has more consistent behavior across platforms, which isn't entirely unimplmented on musl, and which cooperates with the platform libpthread rather than working behind its back, so it's better for most users.
Rustix may still want to add sched_setscheduler
, but I'd like to understand how it would be used so that we can write a documentation comment pointing people to pthread_setschedparam
in situations where that would be better.
I don't think so. And using In Linux, scheduling is not managed by libpthread; |
It appears that all of linux/glibc, linux/musl, FreeBSD, and POSIX all support
Could you say more about your use case?
glibc's wrapper does do some additional things, including update some metadata that would become stale if the user used |
We can implement it using raw syscall if musl does not provide it.
I consider not "requires the libc" an advantage.
Right. I can implement both and point that in doc. |
The problem is that |
Solve #1183