From owner-freebsd-dtrace@FreeBSD.ORG Thu Aug 29 22:20:38 2013 Return-Path: Delivered-To: freebsd-dtrace@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 8A304B16; Thu, 29 Aug 2013 22:20:38 +0000 (UTC) (envelope-from markjdb@gmail.com) Received: from mail-ie0-x22d.google.com (mail-ie0-x22d.google.com [IPv6:2607:f8b0:4001:c03::22d]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 51FF12EA5; Thu, 29 Aug 2013 22:20:38 +0000 (UTC) Received: by mail-ie0-f173.google.com with SMTP id qa5so1612197ieb.4 for ; Thu, 29 Aug 2013 15:20:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=pk4YOhHV5s/05honH5KCi4ho6USIrPOQoAjn6W1bqN8=; b=B2B0CoR50/iSzjm+Q2EA7FVIA26pdX+NhHYuavwKW2+pd0ueNbfXpfqsghjXWfuBhW MEcJk4Up8J9hxxyZGU2imtr7MkrXq8SiS621C0GexrKT/ygrqE4jNKPqDgtbl3RVvcWa L2oHQqiuXHCxDRsDycb2ulapIv3En6WHE0qbDkLci33liB/jOt/5IxcHHp0nO3Csq9Ay NofQyKjD52jEp6tV7hTwwVD9qiSRP0XJoMBPrRGJK3WHK7wv08OuWlBPYwcYD1GuJQtG RqbG3tg1yeb6Rta/PVxEq4d/Hr7uiDENADVH4OY/ZAz82YGMS9nVSs78kiRCnvLrHBhY LWcw== X-Received: by 10.43.53.144 with SMTP id vq16mr2559655icb.41.1377814837766; Thu, 29 Aug 2013 15:20:37 -0700 (PDT) Received: from raichu (24-212-218-13.cable.teksavvy.com. [24.212.218.13]) by mx.google.com with ESMTPSA id m1sm752919igj.10.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 29 Aug 2013 15:20:37 -0700 (PDT) Sender: Mark Johnston Date: Thu, 29 Aug 2013 18:20:29 -0400 From: Mark Johnston To: Andriy Gapon Subject: Re: sdt deadlock Message-ID: <20130829221950.GA47468@raichu> References: <521F29F2.2020208@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <521F29F2.2020208@FreeBSD.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-dtrace@FreeBSD.org X-BeenThere: freebsd-dtrace@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "A discussion list for developers working on DTrace in FreeBSD." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 29 Aug 2013 22:20:38 -0000 On Thu, Aug 29, 2013 at 02:01:06PM +0300, Andriy Gapon wrote: > > We've just experienced a deadlock between dtrace_lock and sdt_sx. > > Mark, could you please take a look at the following debugging data if you have > some time? Does it look like something that could be fixed by your recent big > change to the related code? Hi Andriy, It will definitely be fixed by my recent changes - the sdt rewrite removed sdt_sx. :) Now the sdt code relies only on the kld lock and the DTrace locks, and I was careful to avoid LORs. In particular, the kld lock is always taken before any DTrace locks. I also just did a little test where I was loading and unloading a file containing SDT probe definitions in a loop, and running DTrace scripts in another terminal. I didn't have any problems, so I'm fairly confident that this particular interaction works properly now.