[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160511130031.GA1032@krava>
Date: Wed, 11 May 2016 15:00:31 +0200
From: Jiri Olsa <jolsa@...hat.com>
To: Andi Kleen <andi@...stfloor.org>
Cc: acme@...nel.org, peterz@...radead.org, jolsa@...nel.org,
linux-kernel@...r.kernel.org, Andi Kleen <ak@...ux.intel.com>
Subject: Re: [PATCH 06/10] perf, tools, stat: Avoid fractional digits for
integer scales
On Sat, May 07, 2016 at 12:24:25PM -0700, Andi Kleen wrote:
> > > if (csv_output) {
> > > - fmt = sc != 1.0 ? "%.2f%s" : "%.0f%s";
> > > + fmt = floor(sc) != sc ? "%.2f%s" : "%.0f%s";
> > > } else {
> > > if (big_num)
> > > - fmt = sc != 1.0 ? "%'18.2f%s" : "%'18.0f%s";
> > > + fmt = floor(sc) != sc ? "%'18.2f%s" : "%'18.0f%s";
> > > else
> > > - fmt = sc != 1.0 ? "%18.2f%s" : "%18.0f%s";
> > > + fmt = floor(sc) != sc ? "%18.2f%s" : "%18.0f%s";
> >
> > how about the rest of the code? we display % also in print_running
> > and print_noise_pct functions and maybe some place else
>
> For those it doesn't matter. In fact it's probably better there
> to always show the fractions.
>
> It is just confusing for metrics.
ok, let's try and see, we can always follow up
with the rest if there's a need
Acked-by: Jiri Olsa <jolsa@...nel.org>
thanks,
jirka
Powered by blists - more mailing lists