Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753143AbYFUQPC (ORCPT ); Sat, 21 Jun 2008 12:15:02 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1750913AbYFUQOx (ORCPT ); Sat, 21 Jun 2008 12:14:53 -0400 Received: from bombadil.infradead.org ([18.85.46.34]:56838 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750892AbYFUQOw (ORCPT ); Sat, 21 Jun 2008 12:14:52 -0400 Subject: Re: [RFC][Patch 2/2] markers: example of irq regular kernel markers From: Peter Zijlstra To: Steven Rostedt Cc: "Frank Ch. Eigler" , KOSAKI Motohiro , Masami Hiramatsu , Mathieu Desnoyers , Ingo Molnar , LKML , systemtap-ml , Hideo AOKI , Andrew Morton In-Reply-To: References: <20080620174529.GB10943@Krystal> <485C064E.5020705@redhat.com> <20080621190132.E835.KOSAKI.MOTOHIRO@jp.fujitsu.com> Content-Type: text/plain Date: Sat, 21 Jun 2008 18:13:54 +0200 Message-Id: <1214064834.3223.231.camel@lappy.programming.kicks-ass.net> Mime-Version: 1.0 X-Mailer: Evolution 2.22.2 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1859 Lines: 49 On Sat, 2008-06-21 at 11:07 -0400, Steven Rostedt wrote: > On Sat, 21 Jun 2008, Frank Ch. Eigler wrote: > > Steven Rostedt writes: > > > It also just looks like a debug session instead of a trace marker. > > > > Why do you think the difference between those is profound? > > Not that profound but I do find: > > trace_sched_switch(prev, next); > > much nicer to look at than > > trace_mark("%p %p", prev, next); > > > The trace_sched_switch seems a bit more informative with a simple glance > than the trace_mark. I think what Frank refers to here is why not scatter the kernel code with trace_mark()s on every conceivable location like you do with printk-style debugging. Those trace marks might help out when $customer's kernel goes splat and you don't want to provide him with a custom kernel. I do think we must make a clear distinction between these cases because: 1) tracers provide a kernel<->user interface - and whilst we don't have a stable in-kernel API/ABI we are anal about the kernel/user boundary. Andrew also greatly worries about this aspect. 2) it highly uglyfies the code, Frank doesn't need to maintain it, so its easy for him to say. But IMHO its much harder to read code that is littered with debug statements that it is to read regular code. 3) it bloats the kernel,.. while it may not be fast path bloat, all that marker stuff does go somewhere. So, while I see the value of 'stable' mark sites for 'stable' events, I'm dead-set against littering the kernel with markers just because we can, and hoping they might some day be useful for someone. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/