Date: Thu, 15 Feb 2007 10:33:49 +0000 (UTC) From: Bruce Evans <bde@FreeBSD.org> To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/dev/bge if_bge.c if_bgereg.h Message-ID: <200702151033.l1FAXnJ1023078@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
bde 2007-02-15 10:33:49 UTC
FreeBSD src repository
Modified files: (Branch: RELENG_4)
sys/dev/bge if_bge.c if_bgereg.h
Log:
MFC (if_bge.c 1.108, etc., less some style bugs: eliminate one PCI
read per call to bge_start()).
In packet blasting tests using ttcp with tiny udp packets on an A64-3200
with a 64-bit 5701 on a 32-bit 33MHz PCI bus, this gives a speedup
from 347 kpps to 623 kpps. sendto() has a lot of software overheads,
but even with these the single PCI write per call to bge_start() almost
doubled the per-packet time. This is partly because the software
overheads are so large that the CPU can't keep up with a Gbps NIC that
can actually get anywhere near Gbps speed for tiny packets (347 kppps
for tiny packets is only about 21% of wire speed). When the CPU can't
keep up, it gets further behind because it ends up calling bge_start()
at least once for every packet, so any overheads in bge_start() are
not amortized across multiple packets. Thus the PCI read had an
especially high overhead.
For larger packets, the speedup is closer to the 1.8% claimed in rev.
1.108.
Rev.1.108 claims to eliminate a PCI write but actually eliminates a
PCI read. The write of the tx product index is not so costly as its
read, and cannot be eliminated completely. It could be coalesced in
some cases.
Revision Changes Path
1.3.2.42 +8 -4 src/sys/dev/bge/if_bge.c
1.1.2.22 +1 -0 src/sys/dev/bge/if_bgereg.h
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200702151033.l1FAXnJ1023078>
