produces:#!/usr/bin/perl while (read(STDIN,$buf,$ENV{BLOCKSIZE})) { ; }
$ BLOCKSIZE=1 strace -e read -c perl /tmp/t6 <zelda4rom.zip Called read 26968 times. % time seconds usecs/call calls errors syscall ------ ----------- ----------- --------- --------- ---------------- 100.00 0.002888 160 18 read ------ ----------- ----------- --------- --------- ---------------- 100.00 0.002888 18 total $ BLOCKSIZE=1024 strace -e read -c perl /tmp/t6 <zelda4rom.zip Called read 27 times. % time seconds usecs/call calls errors syscall ------ ----------- ----------- --------- --------- ---------------- 100.00 0.000370 19 19 read ------ ----------- ----------- --------- --------- ---------------- 100.00 0.000370 19 total $ BLOCKSIZE=4096 strace -e read -c perl /tmp/t6 <zelda4rom.zip Called read 7 times. % time seconds usecs/call calls errors syscall ------ ----------- ----------- --------- --------- ---------------- 100.00 0.000315 17 19 read ------ ----------- ----------- --------- --------- ---------------- 100.00 0.000315 19 total
In reply to Re: Re: Re: BitStream revisited
by sgifford
in thread BitStream revisited
by spurperl
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |