http://qs1969.pair.com?node_id=1147899


in reply to How can I limit the number of Cores in multi-process programming

oi mate
look into
taskset -cp 3,4 1234
where processors are 3 and 4
and 1234 is the process id
that's a power to control smp affinity mate

also I believe this will launch your script with the correct affinity
taskset -c 1,2 script.pl