-
Notifications
You must be signed in to change notification settings - Fork 62
feat(runtime): implement thread affinity for runtime and dispatcher #445
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
feat(runtime): implement thread affinity for runtime and dispatcher #445
Conversation
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.
I suggest using core_affinity
(or other equivalents) rather than nix
, to support more platforms.
@George-Miao Do you think we need a feature gate for this PR?
I think given that Will take a look into |
One more question tho, what behavior should we expose given an input that exceeds number of available CPUs ? |
c90cb74
to
ae48b26
Compare
I have pushed changes that replace |
I think an error won't hurt. |
06f1389
to
593fae3
Compare
I have changed the implementation from using |
b201309
to
85f2aaf
Compare
c3ea248
to
a390c77
Compare
I don't understand why this test fails on MacOS and sadly I don't own one to test it locally :( but running those on my Linux setup works fine. |
It's not successful to get the error with I think |
a390c77
to
c6584c4
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.
LGTM
@AsakuraMizu help wanted: |
Maybe it's just a flaky test. Let me re-run those. |
The test failure has been fixed in #449 and merged just now. Could you rebase this PR? |
24c21ad
to
2efe07b
Compare
I rebased it for you :) |
Oh no seems I didn't update the branch before rebase |
Thanks, I am away from my PC right now |
Thank you very much! |
This PR adds an extra field to both
Runtime
andDispatcher
builder that allows user to set thread affinity.