From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752422AbbGMSnX (ORCPT ); Mon, 13 Jul 2015 14:43:23 -0400 Received: from smtprelay0108.hostedemail.com ([216.40.44.108]:35075 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751855AbbGMSnW (ORCPT ); Mon, 13 Jul 2015 14:43:22 -0400 X-Session-Marker: 726F737465647440676F6F646D69732E6F7267 X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,rostedt@goodmis.org,:::,RULES_HIT:41:273:355:379:541:599:800:960:973:988:989:1260:1277:1311:1313:1314:1345:1359:1437:1515:1516:1518:1534:1541:1593:1594:1711:1730:1747:1777:1792:2198:2199:2393:2553:2559:2562:2895:3138:3139:3140:3141:3142:3353:3622:3865:3867:3868:3872:4321:4362:5007:6119:6261:7875:9040:10004:10400:10848:10967:11026:11232:11658:11914:12050:12296:12438:12517:12519:12555:12740:13069:13311:13357:21067:21080,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0 X-HE-Tag: sleet75_2ccaf624935 X-Filterd-Recvd-Size: 2353 Date: Mon, 13 Jul 2015 14:43:19 -0400 From: Steven Rostedt To: Omar Sandoval Cc: Subject: Re: [PATCH] trace-cmd: annotate function durations like the kernel Message-ID: <20150713144319.393b5015@gandalf.local.home> In-Reply-To: <05162f43fb6322f4c46722403449ffdab134e3d2.1435170824.git.osandov@fb.com> References: <05162f43fb6322f4c46722403449ffdab134e3d2.1435170824.git.osandov@fb.com> X-Mailer: Claws Mail 3.11.1 (GTK+ 2.24.28; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 24 Jun 2015 11:36:54 -0700 Omar Sandoval wrote: > Since kernel commit, 8e1e1df29d83 ("tracing: Add additional marks to > signal very large time deltas") the kernel annotates durations longer > than 1000 usecs with # and longer than 1 sec with $. Update trace-cmd > report to be consistent with it. Thanks, applied. (sorry for the late notice). I'll be pushing this up later today. -- Steve > > Signed-off-by: Omar Sandoval > --- > Just a minor cosmetic issue I noticed. Thanks! > > trace-ftrace.c | 12 ++++++++++-- > 1 file changed, 10 insertions(+), 2 deletions(-) > > diff --git a/trace-ftrace.c b/trace-ftrace.c > index bdf11ce4c2dd..636b08b5cdef 100644 > --- a/trace-ftrace.c > +++ b/trace-ftrace.c > @@ -147,11 +147,19 @@ static void print_graph_overhead(struct trace_seq *s, > if (duration == ~0ULL) > return (void)trace_seq_printf(s, " "); > > - /* Duration exceeded 100 msecs */ > + /* Duration exceeded 1 sec */ > + if (duration > 1000000000ULL) > + return (void)trace_seq_printf(s, "$ "); > + > + /* Duration exceeded 1000 usecs */ > + if (duration > 1000000ULL) > + return (void)trace_seq_printf(s, "# "); > + > + /* Duration exceeded 100 usecs */ > if (duration > 100000ULL) > return (void)trace_seq_printf(s, "! "); > > - /* Duration exceeded 10 msecs */ > + /* Duration exceeded 10 usecs */ > if (duration > 10000ULL) > return (void)trace_seq_printf(s, "+ "); >