lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 17 Jul 2020 13:44:52 -0300
From:   Arnaldo Carvalho de Melo <acme@...nel.org>
To:     Changbin Du <changbin.du@...il.com>
Cc:     Arnaldo Carvalho de Melo <arnaldo.melo@...il.com>,
        Jiri Olsa <jolsa@...hat.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Ingo Molnar <mingo@...hat.com>,
        Namhyung Kim <namhyung@...nel.org>,
        Steven Rostedt <rostedt@...dmis.org>,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH v5 03/17] perf ftrace: add option -t/--tid to filter by
 thread id

Em Fri, Jul 17, 2020 at 09:26:50PM +0800, Changbin Du escreveu:
> On Thu, Jul 16, 2020 at 12:36:30PM -0300, Arnaldo Carvalho de Melo wrote:
> > Em Sat, Jul 11, 2020 at 08:40:21PM +0800, Changbin Du escreveu:
> > > +++ b/tools/perf/Documentation/perf-ftrace.txt
> > > @@ -38,6 +38,10 @@ OPTIONS
> > >  --pid=::
> > >  	Trace on existing process id (comma separated list).

> > > +-t::
> > > +--tid=::
> > > +	Trace on existing thread id (comma separated list).

> > Humm, I just  tried:

> > [root@...e ~]# yes > /dev/null &
> > [1] 18265
> > [root@...e ~]# perf ftrace --tid 18265
> > ^C[root@...e ~]#

> > After waiting for a while, nothing, what am I doing wrong?

> I got it wrong. Currently ftrace only can filter by pid. If the pid is not
> the main thread it won't work.
 
> So this patch makes no sense. will drop this.

I think you could alternatively keep it but inform the user that this
target, available to other perf commands, isn't available for ftrace as
it doesn't support it, this way when the user goes from:

perf trace|top|record|script|report --tid 1234

to:

perf ftrace --tid 1234

He gets a message like:

ERROR: 'ftrace' doesn't support the --tid target, try with --pid

And that would be more useful, provides an explanation as why that
target can't be used and suggests an alternative.

- Arnaldo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ