From owner-svn-src-all@FreeBSD.ORG Mon May 13 16:58:05 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 41212597 for ; Mon, 13 May 2013 16:58:05 +0000 (UTC) (envelope-from will@firepipe.net) Received: from mail-ie0-x22c.google.com (mail-ie0-x22c.google.com [IPv6:2607:f8b0:4001:c03::22c]) by mx1.freebsd.org (Postfix) with ESMTP id 135398FC for ; Mon, 13 May 2013 16:58:05 +0000 (UTC) Received: by mail-ie0-f172.google.com with SMTP id 16so13039941iea.3 for ; Mon, 13 May 2013 09:58:04 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type:x-gm-message-state; bh=j/euV2TD5CtvzDWR4664HMqKmfZ2ytMuVPpg9CN7+U8=; b=jyDVeyu8GmzaackMqLJB0g5CVOeInYhA/PnpDXQzsIjSQbQTp/s3KRiDtHinCPQIKz RYKpe5FceeWFN+Cr1MF+tEZAkVXgVz696x/ucXaGoSbwsXjpbGX2roXYHgjS9FV+Db+C izUWbHlKyXWSkgQfbKpr/tZ3qHVv1/ylmXjr6nFqhBxLAIu3Pzok4iKwmJC3iEoMMGEB q7/2AgOMkELAqIR9WudqIUxgQhVTIis5Sg3dR4viKdbLIUweptsTtcwvMD/F4xPEVEMK MCr/Zu3XQA/ZLjgz5DOlTVkkO5s/riMCS/SjA9RfzuDGaTbyiQkS6d/fgeSLREzQ87WZ CuDg== MIME-Version: 1.0 X-Received: by 10.50.103.102 with SMTP id fv6mr10528310igb.6.1368464284683; Mon, 13 May 2013 09:58:04 -0700 (PDT) Received: by 10.231.49.74 with HTTP; Mon, 13 May 2013 09:58:04 -0700 (PDT) In-Reply-To: <518F320D.3070304@mu.org> References: <201305091628.r49GSI33039873@svn.freebsd.org> <518F320D.3070304@mu.org> Date: Mon, 13 May 2013 10:58:04 -0600 Message-ID: Subject: Re: svn commit: r250411 - in head/sys: conf kern sys From: Will Andrews To: Alfred Perlstein X-Gm-Message-State: ALoCoQkp8pRlHxLiuWu9r4FjOUNdSXLFx0wMW0w861syjoVt72QQItTXzQQkV6DVkEBnjyEoj5/4 Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: Marcel Moolenaar , jhb@freebsd.org, svn-src-all@freebsd.org, alfred@freebsd.org, attilio@freebsd.org, src-committers@freebsd.org, Jeff Roberson , svn-src-head@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 May 2013 16:58:05 -0000 On Sun, May 12, 2013 at 12:09 AM, Alfred Perlstein wrote: > Can we just admit to ourselves that tweaks to debugging macros/printing > and WITNESS are our kernel developer's "bikeshed zone" and get over the > fact that people's needs may diverge and changing non-default behavior in > non-critical paths is not going to be the death of the kernel as we know it? > > I could certainly believe that this sort of thing needs long and thorough > discussion if it wasn't the equivalent of style tweaks to manpages. > > Let's leave the long and lengthy discussions to things that matter such as > standards compliance, ABI, API and really cool performance and stability > stuff. Except that this is *not* the equivalent of style tweaks. I'm not sure how you got that from Jeff's email. False positive LORs results in people ignoring all LORs, including real ones. And that impacts stability. Especially if you are trying to implement performance improvements or fix bugs; in that case, the LORs act as a safeguard against violating existing object relationship assumptions. Having worked on ZFS for a while, I can say that many (if not most) of the LORs reported there that are false positives are because the locks represent objects that are frequently and legitimately related to each other in reverse orders, due to reuse of object types at different points in the overall hierarchy. So, I agree that the biggest issue is that witness's model of comparing strings is insufficient for representing more complex lock relationships. In ZFS, in most cases, the locks are acquired after having already (in debug builds) checked these relationships. It seems appropriate, therefore, that witness should be improved by adding the ability to bless specific object relationships on a per-lock entry basis, so that we continue to be notified about *legitimate* LORs, at every call site and between every pair of object types. It also seems best to add a new API for this purpose, so that it can be used regardless of which lock type is being used, without having to modify all existing lock calls. This does mean that code in FreeBSD would need to independently verify the object relationships, but doing so is, IMHO, a lot easier to improve upon than folding this functionality into existing APIs by adding more arguments. --Will.