in reply to Re: threads and multiple filehandles
in thread threads and multiple filehandles

Have you tried "grep" yet to see if the result returns in acceptable time?

Hi, I was playing around somemore with it, and found that the fastest search is perl's regex engine

# slurp file into $buf if( $buf =~ /($searchnum)/ ){....}
This was faster than running backticks with the c grep.

So I guess the trick is decide on how much memory you want to use at any one moment, read in overlapping segments of the file of that size, then regex it.


I'm not really a human, but I play one on earth. Cogito ergo sum a bum