read() performance - Linux.too?

Bob W nospam at aol.com
Mon Jul 24 14:39:48 PDT 2006


"Unknown W. Brackets" <unknown at simplemachines.org> wrote in message 
news:ea1dd2$l4p$1 at digitaldaemon.com...
> Why do you need to read the entire file into memory at once?

Funny question - I have a minimum of 1GB of main memory in
my computers and I intend to use it in order to get the best
performance possible.

You are probably aware of the fact that "read()" will read
the entire file at once, it also takes care of opening and
closing the file.


>
> Anyway, this may be a Phobos problem, but most likely it's the garbage 
> collector.  What if you manually delete the buffer returned by read()?

That'll work. But I am pretty reluctant to accept my
obligation to assist the GC before it falls into coma.






More information about the Digitalmars-d mailing list