ReadFile 1.60 - http://www.winimage.com/readfile.htm
Usage: READFILE                     test memcopy speed
       READFILE filespec            test file reading (bypass cache)
       READFILE filespec /d         test file reading + copy mem
       READFILE filespec /c         test file reading + compute CRC32
       READFILE filespec /s         test file reading + rec. dir parse
       READFILE filespec /l         test file reading + listing output
       READFILE filespec /b         enable the file system buffering
       READFILE filespec /m         use file mapped IO (incompat. with /t & /o)
       READFILE filespec /a         calculate Adler code
       READFILE filespec /g         calculate MD5 code
       READFILE filespec /sh        calculate SHA1 code
       READFILE filespec /t         using small buffer (64 KB instead 1 MB)
       READFILE filespec /r         slow CRC-32 computation
       READFILE filespec /o         using overlapped I/O
       READFILE filespec /h         using multi-thread
READFILE without parameters test the speed of copy big block of memory (1 MB)

READFILE with filespec parameter test speed of readfile file. Example :
C:\> READFILE.EXE *.ima
ReadFile 1.60 - http://www.winimage.com/readfile.htm
File=  3860 Kb/Sec with   1474560 bytes : Distwi25.ima
File=  4084 Kb/Sec with   1474560 bytes : DISTWI22.IMA
Average =   3850 Kb/Sec with   2949120 bytes (total : 765 msec)

Without the /b parameter, the file are opened with FILE_FLAG_NO_BUFFERING
parameters, so it will not copy the file in the cache.

I suggest you test it on big (more than 1 MB), unfraggmented file for testing
the real transfer speed of your hard disk (or network unit) in sequential read.

Under Windows NT, it's VERY useful start performance monitor before use READFILE:
- Start PERFMON.EXE
- Add CPU in the chart

Another usage of ReadFile is produce a listing of file with CRC (can be useful for
checking integrity). You can go to a directory and enter :
READFILE *.* /c /s /l > LISTCRC.TXT to produce a file with CRC32
READFILE *.* /c /a /sh /g /s /l > LISTCRC.TXT to produce a file with CRC32, Adler32,
  Sha1 and MD5

Multi-thread (under Win95 and WinNT) and Overlapped I/O (under WinNT) use advanced
Win32 API for compute CRC (and/or Adler) calcul and read the disk at the same times.
This is useful with a good SCSI adapter or BusMaster IDE.

The slow CRC computation, from /r2 (slow) to /r9 (very very slow) is useful for test
multithreading. /r mean /r3.

readfile160src.zip contain latest source. Fastest CRC32 code is copied from zLib 1.2.3
( http://www.zlib.net ), MD5 and SHA1 from OpenSSL ( http://www.openssl.org/ ), with
assembly code optimised.

The SHA1 code was modified to be compatible with 386 (and not only pentium), to avoid
compatibility problem.
And SHA1 and MD5 code were ported from x86 32 bits to AMD64 assembly code.

Gilles Vollant
info@winimage.com

32\readfile.exe : 32 bits version for Intel/AMD, running Windows NT-x86, Windows 2000,
         Windows XP, Windows 2003 server, Windows 95/98/Me
x64\readfile.exe : 64 bits version for Windows XP, Windows 2003 server 64 bits extended
         edition for AMD 64 and Intel EM64T (64 bits version of Xeon and Pentium 4)
ia64\readfile.exe : 64 bits version for Windows XP, Windows 2003 server 64 bits for 
         Intel Itanium

http://www.winimage.com/
http://www.smartversion.com/
http://www.winimage.com/readfile.htm
http://www.winimage.com/misc/readfile_test.htm
http://www.winimage.com/md5-amd64-ms.htm
