Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1636688

Re: [PATCH] perf, tools, script: Allow adding and removing fields

From Andi Kleen <andi@firstfloor.org>
Newsgroups linux.kernel
Subject Re: [PATCH] perf, tools, script: Allow adding and removing fields
Date 2017-05-05 21:50 +0200
Message-ID <tDRoK-69K-13@gated-at.bofh.it> (permalink)
References <tCpux-4NU-3@gated-at.bofh.it> <tCzNf-2NG-5@gated-at.bofh.it> <tDxq1-1bL-1@gated-at.bofh.it> <tDGjD-7cy-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, May 05, 2017 at 09:57:54AM +0200, Jiri Olsa wrote:
> On Thu, May 04, 2017 at 03:26:20PM -0700, Andi Kleen wrote:
> > On Tue, May 02, 2017 at 08:41:47AM +0200, Jiri Olsa wrote:
> > > On Mon, May 01, 2017 at 12:47:46PM -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 pid,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])
> > > 
> > > 
> > > I haven't checked deeply yet, but I'm getting different pids
> > > with the new syntax, perhaps some mixing with tids column?
> > 
> > Cannot reproduce. Do you have an exact command line?
> > 
> > The patch shouldn't really change any columns.
> >
> 
> [jolsa@krava perf]$ ./perf record -a

I looked at this, and I don't think it's different with my patch. 

Any time you set fields you get different output versus default:


% perf script -F pid,cpu,time,event,sym,ip,dso,period,comm 

vs 

% perf script

First gives PID second TID.

It would be good to fix, but I don't think it should block my patch.

-Andi

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] perf, tools, script: Allow adding and removing fields Andi Kleen <andi@firstfloor.org> - 2017-05-01 21:50 +0200
  Re: [PATCH] perf, tools, script: Allow adding and removing fields Jiri Olsa <jolsa@redhat.com> - 2017-05-02 08:50 +0200
    Re: [PATCH] perf, tools, script: Allow adding and removing fields Andi Kleen <andi@firstfloor.org> - 2017-05-05 00:30 +0200
      Re: [PATCH] perf, tools, script: Allow adding and removing fields Jiri Olsa <jolsa@redhat.com> - 2017-05-05 10:00 +0200
        Re: [PATCH] perf, tools, script: Allow adding and removing fields Andi Kleen <andi@firstfloor.org> - 2017-05-05 21:50 +0200
          Re: [PATCH] perf, tools, script: Allow adding and removing fields Jiri Olsa <jolsa@redhat.com> - 2017-05-08 00:30 +0200

csiph-web