directio icon indicating copy to clipboard operation
directio copied to clipboard

Alignment

Open gregoryyoung opened this issue 11 years ago • 2 comments

You hard code alignment in windows to 4096 you should either use http://msdn.microsoft.com/en-us/library/aa364935%28VS.85%29.aspx which gives the sector size or io control to get it instead http://msdn.microsoft.com/en-us/library/windows/desktop/aa363147(v=vs.85).aspx

Also some of the comments are wrong re disabling drive level caches directio does nothing with this the controller can still cache etc (and most do even if they are not safe!)

Cheers,

Greg

gregoryyoung avatar Nov 02 '14 11:11 gregoryyoung

Thank you very much for your comments.

I chose the value 4096 as it is big enough for all current disks as is discussed here.

If you could propose a patch to change the 4096 constant, or fix any wording that would be an improvement.

Thanks

Nick

PS I'm not really a windows expert so any help appreciated!

ncw avatar Nov 03 '14 13:11 ncw

No worries I'll pull later today. Are their instructions for test running etc? I only looked at the one file so forgive me if it's covered.

Cheers,

Greg

On Monday, November 3, 2014, Nick Craig-Wood [email protected] wrote:

Thank you very much for your comments.

I chose the value 4096 as it is big enough for all current disks as is discussed here http://msdn.microsoft.com/en-us/library/windows/desktop/cc644950(v=vs.85).aspx .

If you could propose a patch to change the 4096 constant, or fix any wording that would be an improvement.

Thanks

Nick

PS I'm not really a windows expert so any help appreciated!

— Reply to this email directly or view it on GitHub https://github.com/ncw/directio/issues/4#issuecomment-61476629.

Studying for the Turing test

gregoryyoung avatar Nov 03 '14 18:11 gregoryyoung