std.file or stream
Christopher Wright
dhasenan at gmail.com
Fri Nov 23 19:08:47 PST 2007
Daniel Keep wrote:
>
> Christopher Wright wrote:
>> Kar wrote:
>>> Im trying to index a very large document collections. I need to know
>>> which file access method is faster, either std.file read all data into
>>> buffer or use stream.
>>>
>>> i didnt understand stream very well, does it store file strings in
>>> memory or just a pointer to exact disc location.
>>>
>>> The index file could be more than 10GBs, so which method is better.
>> std.mmfile for the win.
>>
>> Try the higher-level interface in std.stream.MmFileStream.
>
> I haven't used memory-mapping before, so excuse my ignorance, but how
> would you map a 10GB file into the address space on a 32-bit machine?!
>
> -- Daniel
Um...good point. Allow me to blush.
More information about the Digitalmars-d
mailing list