From owner-freebsd-current@FreeBSD.ORG Wed Jun 14 11:52:48 2006 Return-Path: X-Original-To: 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 A974916A47A for ; Wed, 14 Jun 2006 11:52:48 +0000 (UTC) (envelope-from boris@brooknet.com.au) Received: from jay.exetel.com.au (jay.exetel.com.au [220.233.0.8]) by mx1.FreeBSD.org (Postfix) with ESMTP id 90EBC43D49 for ; Wed, 14 Jun 2006 11:52:46 +0000 (GMT) (envelope-from boris@brooknet.com.au) Received: (qmail 31167 invoked by uid 507); 14 Jun 2006 21:52:45 +1000 Received: from 180.205.233.220.exetel.com.au (HELO ?192.168.0.157?) (220.233.205.180) by jay.exetel.com.au with SMTP; 14 Jun 2006 21:52:45 +1000 In-Reply-To: <20060614095449.GA82424@what-creek.com> References: <20060613021543.GA71283@what-creek.com> <20060613213617.GA78337@what-creek.com> <20060614103614.Y34121@fledge.watson.org> <20060614095449.GA82424@what-creek.com> Mime-Version: 1.0 (Apple Message framework v750) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: Content-Transfer-Encoding: 7bit From: Sam Lawrance Date: Wed, 14 Jun 2006 21:52:38 +1000 To: John Birrell X-Mailer: Apple Mail (2.750) Cc: Robert Watson , current@freebsd.org 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 11:52:48 -0000 On 14/06/2006, at 7:54 PM, John Birrell wrote: > On Wed, Jun 14, 2006 at 10:39:14AM +0100, Robert Watson wrote: >> I don't suppose it's possible to get stack traces or fractional stack >> traces (last 2-3 frames)? There are a number of comon consumers of >> critical sections, but the number does seem inordinately high, >> especially >> with respect to the number of calls of the common consumers. >> Critical >> sections are acquired during access to per-cpu caches in UMA, and for >> per-cpu stats in malloc(9), as well as in context switches and in >> interrupts. > > DTrace has stack access actions. I still need to work on porting them, > but walking up the stack is very much something that DTrace needs to > do. > >> BTW, it looks like the below is running with invariants turned >> on? It may >> be more interesting to run the below without invariants, since >> invariants >> significantly changes the behavior of the memory allocation paths >> due to >> memory trashing and additional bookkeeping. > > Yes, I have both invariants and witness turned on because they > present the > difficult case with respect to function recursion. If I innocently > call > functions from the DTrace probe context which turn out to call other > non-dtrace-legal functions which can be, themselves, instrumented > by FBT, > a probe can crash the system. Witness often ends in tears at the > moment. 8-( I suppose that's the reason why actions like raise() and stop() are invoked by setting t_dtrace_sig and t_dtrace_stop - because it allows the resulting probes to be correctly instrumented.