lkml.org 
[lkml]   [2017]   [May]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] perf, tools, script: Allow adding and removing fields
On Mon, May 08, 2017 at 09:21:34AM -0700, Andi Kleen wrote:
> From: Andi Kleen <ak@linux.intel.com>
>
> With perf script it is common that we just want to add or remove a field.
> Currently this requires figuring out the long list of default fields and
> specifying them first, and then adding/removing the new field.
>
> This patch adds a new + - syntax to merely add or remove fields,
> that allows more succint and clearer command lines
>
> For example to remove the comm field from PMU samples:
>
> Previously
>
> perf script -F tid,cpu,time,event,sym,ip,dso,period
> 0 [000] 504345.383126: 1 cycles: ffffffff90060c66 native_write_msr ([kernel.kallsyms])
>
> with the new syntax
>
> perf script -F -comm
> 0 [000] 504345.383126: 1 cycles: ffffffff90060c66 native_write_msr ([kernel.kallsyms])
>
> The new syntax cannot be mixed with normal overriding.

so the -F option for 'type:' does not have default set,
and it looks like the +- don't make sense there:

[jolsa@krava perf]$ ./perf script -F hw:+comm | head -3
ex
ex
ex


jirka

\
 
 \ /
  Last update: 2017-05-10 21:18    [W:0.043 / U:4.240 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site