lkml.org 
[lkml]   [2019]   [Aug]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
SubjectRe: [PATCH v3] perf diff: Report noisy for cycles diff
From
Date


On 8/12/2019 4:35 PM, Jiri Olsa wrote:
> On Sat, Aug 10, 2019 at 07:30:29AM +0800, Jin Yao wrote:
>
> SNIP
>
>> + if (vals[i] != 0)
>> + return 0;
>> + return 1;
>> +}
>> +
>> +static int print_cycles_spark(char *bf, int size, unsigned long *svals, u64 n)
>> +{
>> + int len = n, printed;
>> +
>> + if (len <= 1)
>> + return 0;
>> +
>> + if (len > NUM_SPARKS)
>> + len = NUM_SPARKS;
>> + if (all_zero(svals, len))
>> + return 0;
>> +
>> + printed = print_spark(bf, size, svals, len);
>> + printed += scnprintf(bf + printed, size - printed, " ");
>> +
>> + if (n > NUM_SPARKS)
>> + printed += scnprintf(bf + printed, size - printed, "..");
>
> will this '..' ever be printed? I can't see that even if I enlarge
> the column width..
>
> jirka
>

@@ -83,6 +85,8 @@ struct hist_entry_diff {
/* PERF_HPP_DIFF__CYCLES */
s64 cycles;
};
+ struct stats stats;
+ unsigned long svals[NUM_SPARKS];
};

Now we only save 8 items in svals[] (NUM_PARKS = 8). So '..' will not be
printed. The code of printing '..' is for future possible case.

If you think it's not necessary, I would remove this.
Thanks
Jin Yao


\
 
 \ /
  Last update: 2019-08-13 06:13    [W:0.136 / U:0.704 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site