- or download this
use threads; # add line before loading MCE (to spin threads)
1 thread 12.473 seconds
...
fork
1 process 7.331 seconds
4 processes 1.848 seconds 3.97x
- or download this
-rw-r--r--. 1 mario mario 80348000 Oct 9 22:15 nightfall.txt
-rw-r--r--. 1 mario mario 20087000 Oct 9 22:12 nightfall1.txt
...
2.274 secs Child 11196 finished working on nightfall3.txt!
2.275 secs Child 11195 finished working on nightfall2.txt!
2.276 secs Parenting talking...all my children are finished! Hooray!
- or download this
mce-process-entire-chunk.pl 1.848 seconds
mce-process-line-by-line.pl 2.264 seconds 2.235 ~ 2.281
- or download this
user_func => sub {
# worker chunk routine
...
print $OUT_FH $$chunk_ref; $OUT_FH->flush;
MCE->relay_unlock;
}
- or download this
user_func => sub {
# worker chunk routine
...
print $OUT_FH $output; $OUT_FH->flush;
MCE->relay_unlock;
}