From owner-cvs-all@FreeBSD.ORG Sun Dec 24 05:51:33 2006 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 286B216A403; Sun, 24 Dec 2006 05:51:33 +0000 (UTC) (envelope-from scottl@samsco.org) Received: from pooker.samsco.org (pooker.samsco.org [168.103.85.57]) by mx1.freebsd.org (Postfix) with ESMTP id A0DF913C490; Sun, 24 Dec 2006 05:51:31 +0000 (UTC) (envelope-from scottl@samsco.org) Received: from [127.0.0.1] (pooker.samsco.org [168.103.85.57]) (authenticated bits=0) by pooker.samsco.org (8.13.4/8.13.4) with ESMTP id kBO5VTnH035583; Sat, 23 Dec 2006 22:31:36 -0700 (MST) (envelope-from scottl@samsco.org) Message-ID: <458E10B0.5030506@samsco.org> Date: Sun, 24 Dec 2006 00:31:28 -0500 From: Scott Long User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.0.7) Gecko/20060910 SeaMonkey/1.0.5 MIME-Version: 1.0 To: Bruce Evans References: <20061223213014.U35809@fledge.watson.org> <20061224120307.P24444@delplex.bde.org> In-Reply-To: <20061224120307.P24444@delplex.bde.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.4 required=3.8 tests=ALL_TRUSTED autolearn=failed version=3.1.1 X-Spam-Checker-Version: SpamAssassin 3.1.1 (2006-03-10) on pooker.samsco.org Cc: cvs-src@FreeBSD.org, src-committers@FreeBSD.org, Robert Watson , cvs-all@FreeBSD.org, John Polstra Subject: Re: cvs commit: src/sys/dev/bge if_bge.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Dec 2006 05:51:33 -0000 Bruce Evans wrote: > On Sat, 23 Dec 2006, Robert Watson wrote: > >> On Sat, 23 Dec 2006, John Polstra wrote: >> >>>> That said, dropping and regrabbing the driver lock in the rxeof >>>> routine of any driver is bad. It may be safe to do, but it incurs >>>> horrible performance penalties. It essentially allows the >>>> time-critical, high priority RX path to be constantly preempted by >>>> the lower priority if_start or if_ioctl paths. Even without this >>>> preemption and priority inversion, you're doing an excessive number >>>> of expensive lock ops in the fast path. > > It's not very time-critical or high priority for bge or any other device > that has a reasonably large rx ring. With a ring size of 512 and an rx > interrupt occuring not too near the end (say at half way), you have 256 > packet times to finish processing the interrupt. For normal 1518 byte > packets at 1Gbps, 256 packet times is about 3 mS. bge's rx ring size > is actually larger than 512 for most hardware. > Speed testing full size packets doesn't tax the hardware or the OS, nor does it represent real world scenarios. Testing minimum sized packets isn't terribly real-world either, but it represents the worst-case for the hardware and the OS and thus is a good standard for extrapolating performance potential. And, 1Gb isn't terribly interesting these days either, 10Gb is. Scott