Date: Fri, 20 Feb 2004 19:32:09 +1100 (EST) From: Bruce Evans <bde@zeta.org.au> To: John Baldwin <jhb@FreeBSD.org> Cc: Jun Kuriyama <kuriyama@imgsrc.co.jp> 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 Message-ID: <20040220191831.B4626@gamplex.bde.org> In-Reply-To: <200402181414.01381.jhb@FreeBSD.org> References: <200401192127.i0JLRBL3041817@repoman.freebsd.org> <200402180839.09285.jhb@FreeBSD.org> <20040218174059.GC7878@ns1.xcllnt.net> <200402181414.01381.jhb@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
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
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040220191831.B4626>