Anybody? Thanks!
Anybody? Thanks!
http://stackoverflow.com/questions/38568940/can-i-lock-a-4gb-or-larger-memory-block-by-calling-setfileiooverlappedrange-mult
http://stackoverflow.com/questions/38568940/can-i-lock-a-4gb-or-larger-memory-block-by-calling-setfileiooverlappedrange-mult
Did you try 'the old new thing'?
ReplyDeleteI'd be very surprised if you could do that on 32bit, at least without PAE. With 64bit I would expect to be able to.
ReplyDeleteJeroen Wiert Pluimers Thanks for the tip, I have now, no results so far.
ReplyDeleteAsbjørn Heid 64-bit only, of course. Would be nice if it worked. As it is now, there's no error, but the question is: is the whole combined range locked and used by the kernel to boost performance. I'm not sure.
ReplyDeleteOndrej Kelle Weird, can't remember seeing any such limitations in the WinAPI in 64bit mode. Then again I'm on a buss in the middle of nowhere (only got Edge!!!), so can't contribute much for now. Looking forward to the conclusion.
ReplyDeleteIs mapped I/O faster? (forward-only, sequential-only)
ReplyDeleteDavid Berneda Thanks, I'll check it. But I think with file mapping you are forced to use the file system cache. I'm using FILE_FLAG_NO_BUFFERING to bypass the cache for one-off reading of several large (tens of GB) files, processing multiple async reads in parallel, with large buffers. When experimenting with various buffer sizes and disk read queue depth values, the memory range to be locked by SetFileIoOverlappedRange may exceed 4 GB, hence my question.
ReplyDeleteOndrej Kelle Being back at my computer and having read the MSDN page, I'd expect it to honor multiple calls. There's also a tiny bit more info here http://int64.org
ReplyDeleteThe way I read the above is that you're supposed to call it multiple times with different (per-thread) buffers.
Of course, that's just my interpretation.