public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@kernel.org>
To: David Ahern <dsahern@gmail.com>
Cc: acme@ghostprotocols.net, linux-kernel@vger.kernel.org,
	Stephane Eranian <eranian@google.com>
Subject: Re: [PATCH] perf stat: Do not show stats if workload fails
Date: Fri, 20 Dec 2013 08:57:59 +0100	[thread overview]
Message-ID: <20131220075759.GA12937@gmail.com> (raw)
In-Reply-To: <1387518748-25340-1-git-send-email-dsahern@gmail.com>


* David Ahern <dsahern@gmail.com> wrote:

> Currently perf-stat attempts to show counter stats even if the workload
> is bogus:
> 
> $ perf stat -- foo
> foo: No such file or directory
> 
>  Performance counter stats for 'foo':
> 
>      <not counted>      task-clock
>      <not counted>      context-switches
>      <not counted>      cpu-migrations
>      <not counted>      page-faults
>      <not counted>      cycles
>      <not counted>      stalled-cycles-frontend
>      <not counted>      stalled-cycles-backend
>      <not counted>      instructions
>      <not counted>      branches
>      <not counted>      branch-misses
> 
>        0.009769943 seconds time elapsed
> 
> It is impossible to differentiate all the failure modes, but it seems
> reasonable that if the workload handling fails, perf-stat should not try
> to print stats.
> 
> With this change:
> 
> $ perf stat  -v -- foo
> Failed to start workload
> 
> Signed-off-by: David Ahern <dsahern@gmail.com>
> Cc: Ingo Molnar <mingo@kernel.org>
> Cc: Stephane Eranian <eranian@google.com>

Nice!

Acked-by: Ingo Molnar <mingo@kernel.org>

Thanks,

	Ingo

  reply	other threads:[~2013-12-20  7:58 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-20  5:52 [PATCH] perf stat: Do not show stats if workload fails David Ahern
2013-12-20  7:57 ` Ingo Molnar [this message]
2013-12-23 19:37   ` Arnaldo Carvalho de Melo
2013-12-24  0:29     ` David Ahern
2013-12-24 12:53       ` Arnaldo Carvalho de Melo
2013-12-24 13:30         ` Arnaldo Carvalho de Melo
2013-12-26 14:11           ` David Ahern
2013-12-26 14:15             ` Arnaldo Carvalho de Melo
2013-12-26 14:18               ` David Ahern
2013-12-26 14:26                 ` Arnaldo Carvalho de Melo
2013-12-26 14:55                 ` Arnaldo Carvalho de Melo
2014-01-02 14:44             ` Arnaldo Carvalho de Melo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20131220075759.GA12937@gmail.com \
    --to=mingo@kernel.org \
    --cc=acme@ghostprotocols.net \
    --cc=dsahern@gmail.com \
    --cc=eranian@google.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox