Assigning a thread to specific CPU core

后端 未结 3 2058
猫巷女王i
猫巷女王i 2021-01-14 01:42

AFAIK, it is possible to assign a thread to a CPU core in Linux. (see this). But, my question is can I achieve this functionality using boost and if it is p

相关标签:
3条回答
  • 2021-01-14 02:31

    The topic is called "thread affinity", you could find the response by searching for this plus your exact operating system version.

    0 讨论(0)
  • 2021-01-14 02:32

    Boost is meant to be a cross platform library while the question you linked to points toward a OS specific implementation which to my knowledge is the only way to do what you are asking.

    0 讨论(0)
  • 2021-01-14 02:38

    In Windows OS you can use SetThreadAffinityMask API call for this. I don't see how boost fits in what you need.

    0 讨论(0)
提交回复
热议问题