Reputation: 18219
Consider the file Processes.txt
./MyProcess 1 -nbThreads 2
./MyProcess 2 -nbThreads 2
./MyProcess 3 -nbThreads 2
, where each MyProcess
will attempt to use two cores. Now consider running
parallel -j 3 :::: Processes.txt
The call to parallel
specifically indicate to use no more than 3 cores. Will parallel
allow MyProcess
to further fork and the whole thing will use 6 cores or will it somehow enforce the three processes MyProcess
to using one core each only?
Upvotes: 1
Views: 43
Reputation: 33685
It will run three processes at once and if they choose to create further processes it will neither know nor care.
(Hattip to: Mark Setchell)
Upvotes: 2