Beefy Boxes and Bandwidth Generously Provided by pair Networks Frank
The stupid question is the question not asked
 
PerlMonks  

Re: selecting columns from a tab-separated-values file

by sundialsvc4 (Monsignor)
on Jan 22, 2013 at 22:05 UTC ( #1014802=note: print w/ replies, xml ) Need Help??


in reply to selecting columns from a tab-separated-values file

I would footnote the previous discussion with BrowserUK by making one other important point ...

While it’s easy to assume that a file-I/O request by a userland program corresponds 1-to-1 with a disk I/O operation, in fact it does not.   The request might be satisfied directly through a pre-read buffer.   If I/O does occur, it might involve the reading of multiple directory or file-allocation structures in order to locate the point where the data may be found.   Further, many operating systems provide various means by which it is possible to “cue” the operating system that this particular program will be making sequential reads ... or, the OS might discover such things for itself.

All of these things are centered around the notion that a computer program ought to be able to just be the simplest expression of what it has been built to do.   If it is “reading from one stream and writing to another,” then ... so be it.   Why, indeed, should a program have to “put more thought into” such a simple requirement?

In short ... maybe my entire previously-argued point is specious, if not wrong.   Maybe the operating system does know best.   Maybe it’s best that it does.


Comment on Re: selecting columns from a tab-separated-values file
Re^2: selecting columns from a tab-separated-values file
by ibm1620 (Beadle) on Jan 22, 2013 at 22:32 UTC
    I probably should have mentioned this before: my Perl program was consuming 100% of one CPU core, leading me to think it was unlikely to be I/O-bound.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1014802]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (7)
As of 2014-04-17 23:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (458 votes), past polls