From owner-cvs-all Tue Apr 2 15:48:23 2002 Delivered-To: cvs-all@freebsd.org Received: from wantadilla.lemis.com (wantadilla.lemis.com [192.109.197.80]) by hub.freebsd.org (Postfix) with ESMTP id C4B2637B419; Tue, 2 Apr 2002 15:48:08 -0800 (PST) Received: by wantadilla.lemis.com (Postfix, from userid 1004) id E616D78311; Wed, 3 Apr 2002 09:18:06 +0930 (CST) Date: Wed, 3 Apr 2002 09:18:06 +0930 From: Greg 'groggy' Lehey To: John Baldwin Cc: cvs-all@FreeBSD.org, cvs-committers@FreeBSD.org, Jake Burkholder Subject: Re: cvs commit: src/sys/conf options src/sys/kern kern_ktr.c src Message-ID: <20020403091806.N26122@wantadilla.lemis.com> References: <20020402122111.A20507@wantadilla.lemis.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.3.23i Organization: The FreeBSD Project Phone: +61-8-8388-8286 Fax: +61-8-8388-8725 Mobile: +61-418-838-708 WWW-Home-Page: http://www.FreeBSD.org/ X-PGP-Fingerprint: 6B 7B C3 8C 61 CD 54 AF 13 24 52 F8 6D A4 95 EF Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tuesday, 2 April 2002 at 11:09:17 -0500, John Baldwin wrote: > > On 02-Apr-2002 Greg 'groggy' Lehey wrote: >> On Sunday, 31 March 2002 at 21:35:26 -0800, Jake Burkholder wrote: >>> jake 2002/03/31 21:35:26 PST >>> >>> Modified files: >>> sys/conf options >>> sys/kern kern_ktr.c >>> sys/sys ktr.h >>> sys/sparc64/sparc64 genassym.c >>> Log: >>> ktr changes to improve performance and make writing a userland utility to >>> dump the trace buffer feasible. >>> - Remove KTR_EXTEND. This changes the format of the trace entries when >>> activated, making writing a userland tool which is not tied to a >>> specific >>> kernel configuration difficult. >>> >>> These changes will break gdb macros to decode the extended version >>> of the trace buffer which are floating around. Users of these >>> macros should either use the show ktr command in ddb, or use the >>> userland utility which can be run on a core dump. >> >> I really think this is wrong. It removes a very useful debugging >> tool. IIRC it was possible to disable KTR_EXTEND when necessary. >> Even if not, it was still an option, and I think it should remain one. >> There are plenty of places where you won't be able to use the userland >> tool. > > In which case you can use 'show ktr' in DDB or a simple macro in > gdb. This doesn't preclude using a macro in gdb, it just makes the > macro a bit more complicated. If you can come up with a macro, I'll retire my objections. The problem I recall is that it has to do a sprintf with one of the arguments as format. I wasn't able to find a way. I still think this is a Bad Idea. It would be trivial for the system call for tdump to return EINVAL if KTR_EXTEND is set. There's little enough debug assistance as it is; there's certainly no reason to remove any of it which is useful. Greg -- See complete headers for address and phone numbers To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message