From owner-freebsd-current@FreeBSD.ORG Wed Jun 14 15:38:09 2006 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 51FCF16A41A for ; Wed, 14 Jun 2006 15:38:09 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (66-23-211-162.clients.speedfactory.net [66.23.211.162]) by mx1.FreeBSD.org (Postfix) with ESMTP id 46B2143D46 for ; Wed, 14 Jun 2006 15:38:08 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from [10.0.1.112] (nat-outside.atlanta.corp.yahoo.com [63.172.193.57]) (authenticated bits=0) by server.baldwin.cx (8.13.4/8.13.4) with ESMTP id k5EFbrt1034171; Wed, 14 Jun 2006 11:38:03 -0400 (EDT) (envelope-from jhb@freebsd.org) From: John Baldwin To: freebsd-current@freebsd.org Date: Wed, 14 Jun 2006 11:36:24 -0400 User-Agent: KMail/1.9.1 References: <20060613021543.GA71283@what-creek.com> <20060613213617.GA78337@what-creek.com> <200606141020.22182.jhb@freebsd.org> In-Reply-To: <200606141020.22182.jhb@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200606141136.25214.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (server.baldwin.cx [66.23.211.162]); Wed, 14 Jun 2006 11:38:04 -0400 (EDT) X-Virus-Scanned: ClamAV 0.87.1/1539/Wed Jun 14 10:21:49 2006 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=4.2 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.1.0 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on server.baldwin.cx Cc: John Birrell Subject: Re: DTrace for FreeBSD - fbt output X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Jun 2006 15:38:09 -0000 On Wednesday 14 June 2006 10:20, John Baldwin wrote: > On Tuesday 13 June 2006 17:36, John Birrell wrote: > > On Tue, Jun 13, 2006 at 02:15:43AM +0000, John Birrell wrote: > > > With the development as it stands at the moment, take care using the FBT > > > provider because you can easily cause the system to go kaboom. I'm still > > > trying to track down the problems there. It's not in FBT itself -- just > > > the fact that the DTrace probe context isn't allowed to call anything that > > > FBT can instrument. If that happens you will either get a reboot or a > > > double fault will leave you in kdb. I recommend only enabling a few FBT > > > probes at a time just so you know which ones could cause a fault. There is > > > no point telling me that you enabled fbt::: and the system went kaboom! > > > > With the FBT provider as it now stands and using this script: > > > > fbt:::entry > > { > > @[probefunc] = count(); > > } > > > > the output after a buildworld is listed below. Check out the number of > > calls to critical_enter and critical_exit (which are listed at the bottom)! > > And for comparison, check the hardclock() count which relects 1000 Hz. > > Those functions are called a lot as every spinlock ends up calling them > (including sched_lock, turnstile chain locks, sleepqueue locks, etc.) Also, WITNESS has its own internal spinlock that is acquired and released on every mutex, rwlock, or sx lock operation, and each of those acquire/release pairs would constitute a critical_enter/exit pair, so you really should run with WITNESS off to get a sense of how often critical_* is really called. -- John Baldwin