in reply to Re: Parallel Processing
in thread Parallel Processing


Thanks every one.

I found a simple solution that meets my requirement. What I did was added "START" inside the system command
for 1..5{ system("START DoThis.exe"); }

Replies are listed 'Best First'.
Re^3: Parallel Processing
by eyepopslikeamosquito (Archbishop) on Jun 07, 2010 at 12:43 UTC

    No need for START. This will do the trick on Windows:

    for (1..5) { system(1, "DoThis.exe"); }
    See perlport.

      meh.

      for (1..5) { system('start DoThis.exe'); }

      vs

      my @pids; for (1..5) { push @pids, system(1, "DoThis.exe"); } waitpid($_, 0) for @pids;

      Maybe zombies don't matter and you can reduce the latter to something akin to the former, but we haven't been told that.

      Then again, I would want to know if the children died, and using start hides that data.