Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: spawning multiple child processes

by Abigail-II (Bishop)
on Jun 21, 2002 at 09:11 UTC ( #176258=note: print w/replies, xml ) Need Help??


in reply to spawning multiple child processes

Well, exec replaces a single process with another, but fork copies the running process. So, fork combined with exec is the way (at least under Unix) to spawn off new tasks. If you are doing a system, behind the screens, Perl will do a fork and an exec. It will just wait for the child to finish before continuing. Using a system with an ampersand tacked to the end of the command is an option, but that means Perl will first invoke a shell (using fork and exec) which will spawn off your command (using another fork and exec).

Abigail

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://176258]
help
Chatterbox?
[1nickt]: In my case I can simply pass sprintf '%.1f', 1.0 (to Types::Standard:: Int), but what if you didn;t know the precision of the number you were working with? Seems I must be missing something. Oh well, my test list is complete, mooving on ...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (13)
As of 2017-05-24 18:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?