Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site watcgl.UUCP Path: utzoo!watmath!watnot!watcgl!mwherman From: mwherman@watcgl.UUCP (Michael W. Herman) Newsgroups: net.unix-wizards Subject: Re: Do inter-process pipes use secondary (disc) memory for buffering? Message-ID: <1805@watcgl.UUCP> Date: Mon, 13-May-85 11:04:10 EDT Article-I.D.: watcgl.1805 Posted: Mon May 13 11:04:10 1985 Date-Received: Mon, 13-May-85 23:48:57 EDT References: <605@homxb.UUCP> <5566@umcp-cs.UUCP> Distribution: net.unix Organization: Computer Graphics Laboratory, U of Waterloo, Ontario Lines: 48 > (Performance analysis? What performance analysis?) I have done some experimenting in an attempt to determine what the effective/sustained data transfer rates are for pipes in 4.2BSD on a 780. The experiment consisted of a simple producer process writing blocks of data to a consumer process. A total of 1M bytes of data was transferred in each case. The statistics I gathered consisted of the block size (i.e. arg 3 to *write(2)*) and elapsed time for each of the producer and consumer processes. I varied the block size from 128 bytes to 4096 bytes in steps of 128 bytes (In another version of the experiment, I used an upper bound of 16K bytes.) The pipe was created by calling the *pipe(2)* function. The experiments were run on an almost empty machine (i.e. load average < 1.0). With only one pair of producer/consumer processes running on the 780, a maximum sustained transfer rate of about 330,000 bytes/second was realized using a block size of 3K bytes. There were other local maximums at 1K bytes (200,000 bytes/second), 2K bytes (280,000 bytes/second) and 4K bytes (326,000 bytes/second). For comparison, the transfer rate for a block size of 128 bytes was about 34,000 bytes/second. With 4 pairs of producer/consumer processes running simultaneously, the corresponding figures were: block size (bytes) approx. transfer rate (bytes/second) 4K 47,000 3K 70,000 2K 40,000 1K 35,000 128 6,300 If anyone would like to run these programs on their machines, I'll be happy to send them to you. Warning: they're pretty "bare bones" and you will probably want to change them to suit your own purposes. Michael Herman Computer Graphics Laboratory Department of Computer Science University of Waterloo Waterloo, Ontario, Canada N2L 3G1 UUCP: {allegra,ihnp4,watmath}!watcgl!mwherman -or- {cbosgd,clyde,decvax,linus,tektronix,utcsrgv}!watmath!watcgl!mwherman CSNET: mwherman%watcgl@waterloo.CSNET ARPA: mwherman%watcgl%waterloo.CSNET@csnet-relay.ARPA p.s. I didn't do any statistical tests of significance with my results.