Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: Fork multi processes

by JavaFan (Canon)
on May 04, 2012 at 11:51 UTC ( #968912=note: print w/ replies, xml ) Need Help??


in reply to Fork multi processes

How can I achieve it using Perl?
The same as in C. In a nutshell: fork, fork, fork, fork, fork, wait, fork. That is, you fork of 5 children, then wait for any of them to finish, after which you fork the 6th.

Of course, you shouldn't ignore SIGCHLD, and you may need to do some more bookkeeping if you do other forks as well.


Comment on Re: Fork multi processes

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://968912]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (12)
As of 2014-09-19 20:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (146 votes), past polls