Beispiel #1
0
 def set_child_affinity_mask(self, pid, child_index):
     i = child_index+1 if self.CPU_AFFINITY_STRATEGY == CPU_AFFINITY_STRATEGY_PARENT_INCLUDED else child_index
     set_processor_affinity([i%self.cpu_count], pid=pid)
Beispiel #2
0
 def set_parent_affinity_mask(self):
     if self.CPU_AFFINITY_STRATEGY == CPU_AFFINITY_STRATEGY_PARENT_INCLUDED:
         set_processor_affinity([0])