-
Notifications
You must be signed in to change notification settings - Fork 52
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
Make CPU affinity used for CPU pinning configurable via json file #1136
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.
Please respond to questions about server
affinity and the high level question about clarifying the purpose/priorities for this change. Also consider that this PR is the first-pass documentation for HOW to use the feature, so include details about best practices for config.
We are planning to create a release branch on the 18th, and your PR will need to be completed before then for the changes to be in effect. Do you want these changes included in this release? |
Yes, I was on leave, will be resolving comments and this PR should be completed today (17th Dec). |
Addressed all the questions and updated PR description. |
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 have commented only in few places, but anywhere you are using "stream processor" replace with "cpu affinity", "cpu affinity configuration" or equivalent. "stream processor" sounds like something that is responsible for processing streams.
I'll be creating the release branch at 11:30 CST. |
Comments addressed and OOO rest of year.
Sumit has reviewed and comments address
### What does this Pull Request accomplish? For core server thread, there were hardcoded values for setting cpu affinity. This change removes that code. ### Why should this Pull Request be merged? Earlier change which made some of the [cpu affinity settings configurable](#1136) through `server_config.json` left out making server thread pinning configurable because this code just sets affinity for main thread that launches server. This doesn't really change anything performance-wise apart from server launch time. CPU pinning for main server thread was added when we added support for moniker based streaming and was taken as is from prototype branch for moniker streaming. This code is not needed. ### What testing has been done? Build passes and able to launch grpc-device server
What does this Pull Request accomplish?
We want to configure cpu affinity used for cpu pinning for different process configurable via json file.
Why should this Pull Request be merged?
User-Configurable CPU affinity:
Users can explicitly assign processor for:
Why?
Default Behavior: "No Affinity" (-1):
dynamically.
Separate CPU Cores for Critical Threads:
Users can assign separate CPU cores for non- sideband threads, sideband-read/write, and server threads.
Why?
Best Practices for configuration:
What testing has been done?
I am able to build grpc-server and run it successfully with and without cpu pinning configuration in json file.