Tag Archives: fork

Forking in Perl 2

Build up an index of files to process, e.g. sam files. Fork out 16 child processes, each time processing and eliminating one file from the index. As with all my code, use at your own risk. Comments and suggestions always … Continue reading

Posted in programming | Tagged , | Leave a comment

Forking in Perl

Foreach item in the array, start a fork. $pid returns 0 if it is the child process. This way you can spawn 4 child processes from one parent. This page explains it all and the code shown below is an … Continue reading

Posted in programming | Tagged , | Leave a comment