title: Reading binary files without buffering the whole file into memory in C++
body: <p>In order to make a binary comparer I'm trying to read in the binary contents of two files using the CreateFileW function.  However, that causes the whole file to be bufferred into memory, and that becomes a problem for large (500MB) files.  </p>
  
  <p>I've looked around for other functions that'll let me just buffer part of the file instead, but I haven't found any documentation specifically stating how the buffer works for those functions (I'm a bit new at this so maybe I'm missing the obvious).</p>
  
  <p>So far the best match I seem to have found is ReadFile.  It seems to have a definable buffer but I'm not completely sure that there won't be another buffer implemented behind the scenes, like there is with CreateFileW.  </p>
  
  <p>Do you guys have any input on what would be a good function to use?</p>