|
|
|
|
|
by 1amzave
4063 days ago
|
|
So what happens when you find yourself running on a CPU that wasn't in your initial affinity mask? Also, the "sleep for 1 ms" approach used in `init()` looks wrong -- if `sched_setaffinity()` doesn't guarantee that the calling task has been migrated to one of the target CPUs on return (which I suspect it does), I don't think sleeping for a millisecond is going to change anything. |
|
Yeah, the sleep is a leftover from an earlier version of the code that didn't use sched_setaffinity. I've remove it now.