From owner-cvs-src@FreeBSD.ORG Wed May 21 04:41:39 2008 Return-Path: Delivered-To: cvs-src@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 996DF106564A; Wed, 21 May 2008 04:41:39 +0000 (UTC) (envelope-from jb@what-creek.com) Received: from what-creek.com (what-creek.com [66.111.37.70]) by mx1.freebsd.org (Postfix) with ESMTP id 68F1F8FC14; Wed, 21 May 2008 04:41:39 +0000 (UTC) (envelope-from jb@what-creek.com) Received: by what-creek.com (Postfix, from userid 102) id D15AC7330A; Wed, 21 May 2008 04:41:38 +0000 (GMT) Date: Wed, 21 May 2008 04:41:38 +0000 From: John Birrell To: Roman Divacky Message-ID: <20080521044138.GB62522@what-creek.com> References: <200805181932.m4IJWagN055358@repoman.freebsd.org> <20080519202445.GA82705@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20080519202445.GA82705@freebsd.org> User-Agent: Mutt/1.4.2.3i Cc: cvs-src@FreeBSD.org, src-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/kern kern_sdt.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 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: Wed, 21 May 2008 04:41:39 -0000 On Mon, May 19, 2008 at 10:24:45PM +0200, Roman Divacky wrote: > On Sun, May 18, 2008 at 07:32:36PM +0000, John Birrell wrote: > > jb 2008-05-18 19:32:36 UTC > > > > FreeBSD src repository > > > > Added files: > > sys/kern kern_sdt.c > > Log: > > Add kernel support for the Statically Defined Trace provider. > > > > This is BSD licensed code written specifically for FreeBSD. > > > > It initialises using SYSINIT so that the SDT provider, probe and > > argument description linkage is done whenever a module is loaded, > > regardless of whether the DTrace modules are loaded or not. > > > > This file is optionally compiled into the kernel if the KDTRACE_HOOKS > > option is defined. > > great to see this coming! > > in the sdt_*_listall() functions you lock the sx lock exclusively while > traversing the list... why? I think shared locking is enough in those > cases.... There are other locks held which make shared locking of no value. The locking strategy in the dtrace module is set by the design of the Solaris code. This doesn't mean we can't change it, but we would need to gain something to make it worthwhile. It's not as though this stuff is being called all that often. -- John Birrell