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  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Tue, 27 Oct 2020 14:00:33 +0900
From:   Namhyung Kim <namhyung@...nel.org>
To:     Arnaldo Carvalho de Melo <acme@...nel.org>
Cc:     Jiri Olsa <jolsa@...hat.com>, Ingo Molnar <mingo@...nel.org>,
        Peter Zijlstra <a.p.zijlstra@...llo.nl>,
        Mark Rutland <mark.rutland@....com>,
        Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        LKML <linux-kernel@...r.kernel.org>,
        Stephane Eranian <eranian@...gle.com>,
        Andi Kleen <ak@...ux.intel.com>,
        Ian Rogers <irogers@...gle.com>
Subject: Re: [PATCH v2 2/2] perf stat: Support regex pattern in --for-each-cgroup

Hi Arnaldo,

On Tue, Oct 27, 2020 at 2:53 AM Arnaldo Carvalho de Melo
<acme@...nel.org> wrote:
>
> Em Mon, Oct 26, 2020 at 09:32:34PM +0900, Namhyung Kim escreveu:
> > Hi Jiri,
> >
> > On Mon, Oct 26, 2020 at 8:40 PM Jiri Olsa <jolsa@...hat.com> wrote:
> > > also perhaps we want to warn if there's no match found:
> > >
> > >         $ sudo ./perf stat -a -e cpu-clock,cycles --for-each-cgroup ^foo sleep 1
> > >
> > >          Performance counter stats for 'system wide':
> > >
> > >
> > >                1.002375575 seconds time elapsed
> > >
> >
> > Right, will check this case.
>
> Hum, I thought that could be done on top of this one, but then, the
> ambiguity of:
>
> 1. No samples for a cgroups matching that expression
>
> 2. No cgroups match that expression
>
> Is real and warrants a warning for the 'no cgroups match the
> --for-each-group regexp' case.

The 1 will be handled by perf stat showing <not counted> and
I'll add a warning for the item 2 like below:

  # perf stat -a -e cycles --for-each-cgroup ^foo sleep 1
  no cgroup matched: ^foo

   Usage: perf stat [<options>] [<command>]

        --for-each-cgroup <name>
                          expand events for each cgroup

Thanks
Namhyung

Powered by blists - more mailing lists