From owner-freebsd-arch@FreeBSD.ORG Fri Nov 23 16:45:52 2007 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D0A2C16A417; Fri, 23 Nov 2007 16:45:52 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.freebsd.org (Postfix) with ESMTP id A09DC13C43E; Fri, 23 Nov 2007 16:45:52 +0000 (UTC) (envelope-from bright@elvis.mu.org) Received: by elvis.mu.org (Postfix, from userid 1192) id 3B72D1A4D7C; Fri, 23 Nov 2007 08:45:49 -0800 (PST) Date: Fri, 23 Nov 2007 08:45:49 -0800 From: Alfred Perlstein To: Stephan Uphoff Message-ID: <20071123164549.GR44563@elvis.mu.org> References: <20071121222319.GX44563@elvis.mu.org> <200711221641.02484.max@love2party.net> <3bbf2fe10711220753u435ff4cbxa94d5b682292b970@mail.gmail.com> <200711221726.27108.max@love2party.net> <20071123082339.GN44563@elvis.mu.org> <47469328.8020404@freebsd.org> <20071123092415.GP44563@elvis.mu.org> <4746F858.4070301@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4746F858.4070301@freebsd.org> User-Agent: Mutt/1.4.2.3i Cc: Attilio Rao , Max Laier , freebsd-arch@freebsd.org Subject: Re: rwlocks, correctness over speed. X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Nov 2007 16:45:52 -0000 * Stephan Uphoff [071123 07:57] wrote: > Alfred Perlstein wrote: > > > >That's an interesting hack, I guess it could be done. > > > >I would still like to disallow recursion. > > > Oh - I am all for disallowing recursion. > In my opinion the only valid place for a thread to acquire the same lock > multiple times is inside a transaction system with full deadlock detection. > The question is if we can do that this late in the game? > Maybe we could make non recursive the default and add a call > rw_allow_recurse or rw_init_recurse to allow recursion on a lock if we > can't get away with > the straight out removal of the option? (Or less desirable - keep the > current default and add functions to disallow recursion) > >Can we come to a concensus on that? > > > > > > +1 for disallowing recursion > > Stephan The plan is to simply mention in the documentation that it's not allowed, we'll also remove any options associated with read recursion (if there are any). INVARIANTS to catch such things, and subsystems that still use it will be allowed to live for a while until they are fixed. -- - Alfred Perlstein