Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Dec 2012 00:33:37 +0200
From:      Andriy Gapon <avg@FreeBSD.org>
To:        Alfred Perlstein <bright@mu.org>
Cc:        Adrian Chadd <adrian@FreeBSD.org>, src-committers@FreeBSD.org, John Baldwin <jhb@FreeBSD.org>, svn-src-all@FreeBSD.org, Alfred Perlstein <alfred@FreeBSD.org>, svn-src-head@FreeBSD.org
Subject:   Re: svn commit: r244112 - head/sys/kern
Message-ID:  <50C90641.4030000@FreeBSD.org>
In-Reply-To: <50C904B8.6000502@mu.org>
References:  <201212110708.qBB78EWx025288@svn.freebsd.org> <201212121046.43706.jhb@freebsd.org> <CAJ-Vmo=U04GX%2BZyKuzXLwV%2BPpzU6_dm5BCmL=DWfsmhTVAR%2BsA@mail.gmail.com> <201212121658.49048.jhb@freebsd.org> <CAJ-Vmom8aivK7Z95%2BSwigReOTdn-OwXspK3pXO=0CVr1y1Unzg@mail.gmail.com> <50C904B8.6000502@mu.org>

next in thread | previous in thread | raw e-mail | index | archive | help
on 13/12/2012 00:27 Alfred Perlstein said the following:
> On 12/12/12 2:15 PM, Adrian Chadd wrote:
>> On 12 December 2012 13:58, John Baldwin <jhb@freebsd.org> wrote:
>>
>>
>>> (Note that the primary reason I know for people not running with INVARIANTS
>>> enabled is not that they don't want panics, but that they don't want the
>>> performance hit.)
>> Well, it would be nice to be able to enable invariants on some
>> shipping "debug" versions of images in order to gather more data
>> without crashing the kernel.
> Yes, two of my employers were more of "we want to get more debug metrics, we
> have the spare cycles, but we can't deal with superfluous panics".
> 
> It also allows us "non-architects" to slip in a debug image when we have spare
> cpu without getting yelled at for "crashing the $foo".

There is clearly something wrong with this sort of mentality.

If you find instances where a developer put panic(9) (or KASSERT or etc) to mean
"maybe here is a bug, let's just panic", then let's get those things fixed.

But most of assertions in our code that are know to me really mean that a real
bug has already occurred, that portions of kernel state are corrupted and there
is no going back to a sane state, only going forward to corrupting more and more.


-- 
Andriy Gapon



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?50C90641.4030000>