Return to BSD News archive
Path: euryale.cc.adfa.oz.au!newshost.anu.edu.au!harbinger.cc.monash.edu.au!nntp.coast.net!news.kei.com!newsfeed.internetmci.com!in2.uu.net!nntp.inet.fi!news.funet.fi!news.helsinki.fi!news From: torvalds@linux.cs.Helsinki.FI (Linus Torvalds) Newsgroups: comp.os.linux.networking,comp.unix.bsd.netbsd.misc,comp.unix.bsd.freebsd.misc Subject: Re: TCP latency Date: 12 Jul 1996 14:07:14 +0300 Organization: A Red Hat Commercial Linux Site Lines: 55 Message-ID: <4s5bl2$qpg@linux.cs.Helsinki.FI> References: <4paedl$4bm@engnews2.Eng.Sun.COM> <31E106AF.41C67EA6@dyson.iquest.net> <4rvmtf$ven@linux.cs.Helsinki.FI> <31E3D9E2.41C67EA6@dyson.iquest.net> NNTP-Posting-Host: linux.cs.helsinki.fi Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Xref: euryale.cc.adfa.oz.au comp.os.linux.networking:44929 comp.unix.bsd.netbsd.misc:4003 comp.unix.bsd.freebsd.misc:23368 In article <31E3D9E2.41C67EA6@dyson.iquest.net>, John S. Dyson <toor@dyson.iquest.net> wrote: > >One other thing, the numbers show that the DRIVER used on BSD is slower -- the >networking code is NOT SHOWN to be slower... Refer to the numbers... No, read the numbers again. Linux was faster on loopback too. >Do you know that my localhost results on my P5-166 are 200usecs? >That is faster than the Linux measurements that are being espoused as a >"record" isn't it??? Ooohh.. "FreeBSD is faster over loopback, when compared to Linux over the wire". Film at 11. linux$ ./lat_tcp linux $Id: lat_tcp.c,v 1.2 1995/03/11 02:25:31 lm Exp $ TCP latency using linux: 181 microseconds That's on a P166 too. With a stable kernel. What were you saying again? (And if you think you will get 10% better numbers by just changing compiler options, I'd suggest you _try_ it first, without spouting it on the newsgroups as facts with no backing). And if you don't like latency numbers, what are your throughput numbers? (Btw, check your bcopy() speed first to see if the hardware really _is_ comparable, see below) linux$ ./bw_tcp linux 50m $Id: bw_tcp.c,v 1.3 1995/06/21 21:02:49 lm Exp $ Socket bandwidth using linux: 17.14 MB/sec Yes, the machine was idle while doing this. I guess you can just do them in parallell, though, to get _some_ idea about the degradation under load (admittedly not a lot of sockets, but at least some activity for context switches etc): linux$ ./bw_tcp linux 50m &./bw_tcp linux 50m &./bw_tcp linux 50m & [1] 27157 [2] 27158 [3] 27159 linux$ $Id: bw_tcp.c,v 1.3 1995/06/21 21:02:49 lm Exp $ $Id: bw_tcp.c,v 1.3 1995/06/21 21:02:49 lm Exp $ $Id: bw_tcp.c,v 1.3 1995/06/21 21:02:49 lm Exp $ Socket bandwidth using linux: 6.61 MB/sec Socket bandwidth using linux: 6.34 MB/sec Socket bandwidth using linux: 6.30 MB/sec (This machine does memory copies at 43MB/s - don't bother comparing to wildly different hardware: it's memcpy() bound. I get 55MB/s on my alpha with the same kernel) Linus