title: Windows unbuffered I/O & NCQ
body: <p>When using unbuffered I/O (CreateFile with FILE_FLAG_NO_BUFFER / FILE_FLAG_WRITE_THROUGH) and writing multiple sectors each call to WriteFile, is it possible that the sectors are written in a different orderer then first to last ?  </p>
  
  <pre><code>int iSizeToAlloc = sector_size * 32;
  char *pAlignedMemory = alloc(iSizeToAlloc)
  
  // Here, write 32 sectors, is it possible that sector 2 is written before sector 1 ? 
  ::WriteFile(pAlignedMemory,iSizeToAlloc); 
  </code></pre>
  
  <p>I think I have read something somewhere that when specifying FILE_FLAG_NO_BUFFER Windows instructs the disk subsystem to disable NCQ, but I cant find the article again.</p>