bw_tcp.8 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. .\" $Id$
  2. .TH BW_TCP 1 "$Date$" "(c)1994 Larry McVoy" "LMBENCH"
  3. .SH NAME
  4. bw_tcp \- time data movement through TCP/IP sockets
  5. .SH SYNOPSIS
  6. .B bw_tcp
  7. .I -s
  8. .sp .5
  9. .B bw_tcp
  10. .I hostname [transfersize]
  11. .sp .5
  12. .B bw_tcp
  13. .I -hostname
  14. .SH DESCRIPTION
  15. .B bw_tcp
  16. is a client/server program that moves data over a TCP/IP socket. Nothing is
  17. done with the data on either side; the data is moved in 64KB chunks.
  18. .PP
  19. .B bw_tcp
  20. has three forms of usage: as a server (-s), as a client (bw_tcp localhost), and
  21. as a shutdown (bw_tcp -localhost).
  22. .PP
  23. The default amount of data is 3MB. The client form may specify a different
  24. amount of data. Specifications may end with ``k'' or ``m'' to mean
  25. kilobytes (* 1024) or megabytes (* 1024 * 1024).
  26. .SH OUTPUT
  27. Output format is
  28. .ft CB
  29. Socket bandwidth using localhost: 2.32 MB/sec
  30. .ft
  31. .SH MEMORY UTILIZATION
  32. This benchmark can move up to six times the requested memory per process
  33. when run through the loopback device.
  34. There are two processes, the sender and the receiver.
  35. Most Unix
  36. systems implement the read/write system calls as a bcopy from/to kernel space
  37. to/from user space. Bcopy will use 2-3 times as much memory bandwidth:
  38. there is one read from the source and a write to the destionation. The
  39. write usually results in a cache line read and then a write back of
  40. the cache line at some later point. Memory utilization might be reduced
  41. by 1/3 if the processor architecture implemented "load cache line"
  42. and "store cache line" instructions (as well as getcachelinesize).
  43. .SH ACKNOWLEDGEMENT
  44. Funding for the development of
  45. this tool was provided by Sun Microsystems Computer Corporation
  46. and Silicon Graphics, Inc.
  47. .SH SEE ALSO
  48. lmbench(8), read(2), write(2), socket(2), bind(2), connect(2).