Reputation: 141
When setting the Windows CPU affinity mask for Core 2, is the mask supposed to be 0x0010 or 0x0001? I have seen an example where the mask was set to 0x0010 for Core 0 but this didn't make much sense?
Upvotes: 0
Views: 1230
Reputation: 19
You can taskset it as well
("taskset -cp 2 %d"% os.getpid())
Upvotes: 0
Reputation: 283684
0x0000
allows no CPUs to be scheduled for this process/thread at all. (it will be suspended, assuming setting the affinity doesn't fail during parameter validation, which might be different on different Windows versions)
0x0001
allows Core 0, only
0x0002
allows Core 1, only
0x0003
allows both Core 0 and Core 1.
Upvotes: 1