lkml.org 
[lkml]   [2015]   [Jul]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/4] perf, tools, stat: Abstract stat metrics printing
On Wed, Jul 29, 2015 at 05:21:38PM -0700, Andi Kleen wrote:

SNIP

> +static void nsec_printout(int id, int nr, struct perf_evsel *evsel, double avg,
> + void *ctx, print_metric_t print_metric)
> {
> double msecs = avg / 1e6;
> const char *fmt_v, *fmt_n;
> @@ -647,13 +689,16 @@ static void nsec_printout(int id, int nr, struct perf_evsel *evsel, double avg)
> return;
>
> if (perf_evsel__match(evsel, SOFTWARE, SW_TASK_CLOCK))
> - fprintf(output, " # %8.3f CPUs utilized ",
> - avg / avg_stats(&walltime_nsecs_stats));
> + print_metric(ctx, NULL, "%8.3f", "CPUs utilized",
> + avg / avg_stats(&walltime_nsecs_stats));
> else
> - fprintf(output, " ");
> + print_metric(ctx, NULL, NULL, NULL, 0);
> }

hum, this should go to perf_stat__print_shadow_stats,
could you please move it there before this patch?

thanks,
jirka


\
 
 \ /
  Last update: 2015-07-30 18:21    [W:0.087 / U:0.036 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site