From owner-cvs-src@FreeBSD.ORG Fri Dec 10 10:03:39 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 289BE16A4CE; Fri, 10 Dec 2004 10:03:39 +0000 (GMT) Received: from stella.fs.ei.tum.de (stella.fs.ei.tum.de [129.187.54.7]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2389B43D49; Fri, 10 Dec 2004 10:03:36 +0000 (GMT) (envelope-from corecode@fs.ei.tum.de) Received: from localhost (localhost [127.0.0.1]) by localhost.fs.ei.tum.de (Postfix) with ESMTP id BB5C3F81; Fri, 10 Dec 2004 11:03:32 +0100 (CET) Received: from [10.150.180.180] (r180180.olydorf.swh.mhn.de [10.150.180.180]) (using SSLv3 with cipher RC4-MD5 (128/128 bits)) (Client did not present a certificate) by stella.fs.ei.tum.de (Postfix) with ESMTP id C4E2BF73; Fri, 10 Dec 2004 11:03:28 +0100 (CET) From: Simon 'corecode' Schubert To: cvs-src@freebsd.org Date: Fri, 10 Dec 2004 11:03:20 +0100 User-Agent: KMail/1.7.1 References: <200412091641.iB9GflnD067866@repoman.freebsd.org> <41B8BF81.2000701@errno.com> <41B8EA66.4875E2D9@freebsd.org> In-Reply-To: <41B8EA66.4875E2D9@freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart42463123.NGuNTHYJvd"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <200412101103.27119.corecode@fs.ei.tum.de> X-Virus-Scanned: by AMaViS 0.3.12 cc: src-committers@freebsd.org cc: Andre Oppermann cc: "Christian S.J. Peron" cc: cvs-all@freebsd.org cc: Gleb Smirnoff cc: Sam Leffler Subject: Re: cvs commit: src/sys/netinet ip_fw_pfil.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Dec 2004 10:03:39 -0000 --nextPart42463123.NGuNTHYJvd Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Friday, 10. December 2004 01:14, Andre Oppermann wrote: > > >>> Check that DUMMYNET_LOADED before seeking dummynet m_tag. > > >>This change may be a mistake unless you can prove some significant > > >>performance gain. > > > Checking for DUMMYNET_LOADED is a simple pointer compare to NULL and > > > doesn't add a memory write. Not a big difference for sure but not > > > hurting either. > > If tag lookup cost becomes an important consideration in writing code > > then we need to address that basic functionality. > Actually this is a good argument and reasoning and I buy into it. Not > that is matter this much in this case but having nice and clean code > wins big over time. I've spent and am still spending too much time > cleaning up old BSD PDP-11 "optimizations" and other shortcuts. =46orgive me if I'm way off here, I not experienced with the network stack = as=20 you are. =46irst of all I also think that this check here might be=20 over(micro)optimization. Nevertheless, if tags appear to be a (small)=20 performance hit, I conclude that there should be a fast way to check for th= e=20 (possible?) existance of a tag. So for example having a bit field signaling= =20 the presence of the most important tags which are checked in the hot code=20 path might help, so is this really stupid[tm]? cheers simon =2D-=20 /"\ \ / \ ASCII Ribbon Campaign / \ Against HTML Mail and News --nextPart42463123.NGuNTHYJvd Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.6 (FreeBSD) iD8DBQBBuXRvr5S+dk6z85oRAvNyAJ9OBGuVM2mEVj+2EJ0LV3SK1X8SRACgvHjn bmefsxPtJmX7CXfrcjbZFUY= =ohsr -----END PGP SIGNATURE----- --nextPart42463123.NGuNTHYJvd--