fread optimization for Windows