-
Notifications
You must be signed in to change notification settings - Fork 602
Implement basic pthread affinity support #2343
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
base: master
Are you sure you want to change the base?
Conversation
|
meson configure on circleci Ubuntu fails to detect Good way to check thread affinities is to run Another terminal: |
|
There is now windows code. I tested win 10 version but I couldn't test win 11 code paths. They are untested. |
| project('hwloc', 'c') | ||
|
|
||
| if not (host_machine.system() == 'windows' and host_machine.cpu_family() == 'x86_64') | ||
| error('This wrap of hwloc is a binary wrap for x64_64 Windows, and will not work on your system') |
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.
Returning a disabler object here will simplify the logic in the top level meson.build.
|
Windows 11 returned an unknown error when setting thread affinity. I will have to figure out what caused the problem. |
This reserves an unique cores for
SearchWorker. Assumption is that a second thread on the same core would increase latency whenSearchWorkerhas a deadline to supply more data to GPU. It useslscpubecause it looks like the easiest way to get information about NUMA and threads sharing a core. There is a basic fallback implementation becauselscpuis an optional utility.Windows support is missing. I had a quick look into Windows API. I couldn't immediately figure out correct way to do the same thread binding.