Function rustix::process::sched_setaffinity
source · [−]Expand description
sched_setaffinity(pid, cpuset)
—Set a thread’s CPU affinity mask.
pid
is the thread ID to update. If pid is None
, then the current thread
is updated.
The CpuSet
argument specifies the set of CPUs on which the thread will
be eligible to run.