Anybody? Thanks!

Anybody? Thanks!
http://stackoverflow.com/questions/38568940/can-i-lock-a-4gb-or-larger-memory-block-by-calling-setfileiooverlappedrange-mult

Comments

  1. I'd be very surprised if you could do that on 32bit, at least without PAE. With 64bit I would expect to be able to.

    ReplyDelete
  2. Jeroen Wiert Pluimers Thanks for the tip, I have now, no results so far.

    ReplyDelete
  3. Asbjø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.

    ReplyDelete
  4. Ondrej 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.

    ReplyDelete
  5. Is mapped I/O faster? (forward-only, sequential-only)

    ReplyDelete
  6. David 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.

    ReplyDelete
  7. Ondrej 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

    The 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.

    ReplyDelete

Post a Comment