in reply to Re: Re: Re: Extreme Example of TMTOWTDI
in thread Extreme Example of TMTOWTDI
The reason seems to be twofold. First the reading loop has a higher overhead because it needs to do an extra operation per line read. Second it seems that there is an overhead associated with swapping between cached filehandles. Before my solution was competetive (and it started life looking much the same as your solution) I had to replace the open on demand, with a preopen for each file (which obviously is only feasible in some situations).
Anyway, nice explanation of the technique.
Yves / DeMerphq
---
Writing a good benchmark isnt as easy as it might look.
|
|---|