bw_file_rd.8 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. .\" $Id$
  2. .TH BW_FILE_RD 8 "$Date$" "(c)1994 Larry McVoy" "LMBENCH"
  3. .SH NAME
  4. bw_file_rd \- time the reading and summing of a file
  5. .SH SYNOPSIS
  6. .B bw_file_rd
  7. .I size
  8. .I file
  9. .SH DESCRIPTION
  10. .B bw_file_rd
  11. times the read of the specified file in 64KB blocks. Each block is summed
  12. up as a seried of 4 byte integers in an unrolled loop.
  13. Results are reported in megabytes read per second.
  14. .PP
  15. The data is not accessed in the user program; the benchmark relies on
  16. the operating systems read interface to have actually moved the data.
  17. Systems that implement page flipping may fool this benchmark.
  18. .PP
  19. The benchmark is intended to be used on a file
  20. that is in memory, i.e., the benchmark is a reread benchmark. Other
  21. file benchmarking can be done with
  22. .BR lmdd (8).
  23. .PP
  24. The size
  25. specification may end with ``k'' or ``m'' to mean
  26. kilobytes (* 1024) or megabytes (* 1024 * 1024).
  27. .SH OUTPUT
  28. Output format is \f(CB"%0.2f %.2f\\n", megabytes, megabytes_per_second\fP, i.e.,
  29. .sp
  30. .ft CB
  31. 8.00 25.33
  32. .ft
  33. .SH MEMORY UTILIZATION
  34. This benchmark can move up to three times the requested memory. Most Unix
  35. systems implement the read system call as a bcopy from kernel space
  36. to user space. Bcopy will use 2-3 times as much memory bandwidth:
  37. there is one read from the source and a write to the destionation. The
  38. write usually results in a cache line read and then a write back of
  39. the cache line at some later point. Memory utilization might be reduced
  40. by 1/3 if the processor architecture implemented ``load cache line''
  41. and ``store cache line'' instructions (as well as ``getcachelinesize'').
  42. .SH ACKNOWLEDGEMENT
  43. Funding for the development of
  44. this tool was provided by Sun Microsystems Computer Corporation.
  45. .SH "SEE ALSO"
  46. lmbench(8).