[PATCH v4 1/4] Option to print only failing syscalls
Kohl, Burkhard
burkhard.kohl at intel.com
Tue Jun 18 10:18:10 UTC 2019
> -----Original Message-----
> From: Dmitry V. Levin [mailto:ldv at altlinux.org]
> Sent: Tuesday, June 18, 2019 11:10
> To: Kohl, Burkhard <burkhard.kohl at intel.com>
> Cc: Paul Chaignon <paul.chaignon at gmail.com>; strace-devel at lists.strace.io
> Subject: Re: [PATCH v4 1/4] Option to print only failing syscalls
>
> On Tue, Jun 18, 2019 at 08:53:31AM +0000, Kohl, Burkhard wrote:
> [...]
> > > @@ -1585,7 +1587,7 @@ init(int argc, char *argv[])
> > > #ifdef ENABLE_STACKTRACE
> > > "k"
> > > #endif
> > > - "a:Ab:cCdDe:E:fFhiI:o:O:p:P:qrs:S:tTu:vVwxX:yz")) != EOF) {
> > > + "a:Ab:cCdDe:E:fFhiI:o:O:p:P:qrs:S:tTu:vVwxX:yzZ")) != EOF) {
> > > switch (c) {
> > > case 'a':
> > > acolumn = string_to_uint(optarg);
> > > @@ -1716,6 +1718,9 @@ init(int argc, char *argv[])
> > > case 'z':
> > > not_failing_only = 1;
> > > break;
> > > + case 'Z':
> > > + failing_only = 1;
> > > + break;
> > > default:
> > > error_msg_and_help(NULL);
> > > break;
> >
> > This allows specifying both option -zZ / -Zz, but then the results depend on the
> > sequence in which these options appear on the cmdline,
>
> I don't think this is the case when the whole patchset is applied.
My testing was done after all 4 patches were applied against 5.1.
>
> This patch alone is of course incomplete, as well as the second patch
> in the series. Only the third patch makes things work properly.
Patch 3 was included, see above.
> > e.g.:
> >
> > wc -l *.trc:
>
> Sorry, what is *.trc?
I created 5 different trace files ("*.trc") with the prefix reflecting the respective
combination of flags used, i.e.:
./strace -tfv -o nozorZ.trc /usr/bin/time -v sleep 1
./strace -tfvzZ -o zZ.trc /usr/bin/time -v sleep 1
./strace -tfvZz -o Zz.trc /usr/bin/time -v sleep 1
...
Line count clearly shows that the output of both -zZ/-Zz variants differ.
> > These two options should be made mutually exclusive
>
> Why should they?
Behaviour dependent on the order of the switches would be IMHO extremely confusing.
--
Burkhard
>
>
> --
> ldv
Intel Deutschland GmbH
Registered Address: Am Campeon 10-12, 85579 Neubiberg, Germany
Tel: +49 89 99 8853-0, www.intel.de
Managing Directors: Christin Eisenschmid, Gary Kershaw
Chairperson of the Supervisory Board: Nicole Lau
Registered Office: Munich
Commercial Register: Amtsgericht Muenchen HRB 186928
More information about the Strace-devel
mailing list