From owner-cvs-src@FreeBSD.ORG Fri Feb 20 00:32:15 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5927D16A4CE; Fri, 20 Feb 2004 00:32:15 -0800 (PST) Received: from mailout2.pacific.net.au (mailout2.pacific.net.au [61.8.0.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id BF56443D31; Fri, 20 Feb 2004 00:32:14 -0800 (PST) (envelope-from bde@zeta.org.au) Received: from mailproxy2.pacific.net.au (mailproxy2.pacific.net.au [61.8.0.87])i1K8WD5O023360; Fri, 20 Feb 2004 19:32:13 +1100 Received: from gamplex.bde.org (katana.zip.com.au [61.8.7.246]) i1K8W9ch002563; Fri, 20 Feb 2004 19:32:10 +1100 Date: Fri, 20 Feb 2004 19:32:09 +1100 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: John Baldwin In-Reply-To: <200402181414.01381.jhb@FreeBSD.org> Message-ID: <20040220191831.B4626@gamplex.bde.org> References: <200401192127.i0JLRBL3041817@repoman.freebsd.org> <200402180839.09285.jhb@FreeBSD.org> <20040218174059.GC7878@ns1.xcllnt.net> <200402181414.01381.jhb@FreeBSD.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: src-committers@FreeBSD.org cc: cvs-src@FreeBSD.org cc: cvs-all@FreeBSD.org cc: Marcel Moolenaar cc: Poul-Henning Kamp cc: Jun Kuriyama Subject: Re: cvs commit: src/sys/alpha/alpha support.s src/sys/i386/i386 swtch.s src/sys/kern kern_shutdown.c src/sys/sys systm.h X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 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: Fri, 20 Feb 2004 08:32:15 -0000 On Wed, 18 Feb 2004, John Baldwin wrote: > On Wednesday 18 February 2004 12:40 pm, Marcel Moolenaar wrote: > > I like the behaviour of MPASS(), just not its name and the fact it's > > defined in lock.h. If we can call it ASSERT and move its definition > > to systm.h, then I'm hooked. MPASS() has the same problems as line numbers in panic messages (except for the implementation bugs (misformatting of the output etc.)): verbose messages and breakage of simple regression tests. > Even nicer might be to make fixup_filename() from subr_witness.c a global > #ifdef INVARIANTS_SUPPORT and have KASSERTLV() use that (it trims any (../)* > from the front of a filename to improve readability of messages by just > returning a char * pointer farther along in the string). This problem is better avoided by printing the function name and not the file name. Kernel function names should be unique even for static functions There are a few interesting ones that aren't. I noticed when debugging of the fd driver using ddb was broken by de-uniquifying Fdopen to fdopen, and fixed this and a few others locally. > If ASSERT() is preferred to KASSERT() that would certain ease the transition > to the different macros. KASSERT() also shouldn't be changed because it is used in RELENG_4. Bruce