From: "Pádraig Brady" <P@draigBrady.com>
To: abhishek agarwal <abhigem.126@gmail.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [Perf] Adding timeout option
Date: Fri, 19 Oct 2012 13:28:40 -0700 [thread overview]
Message-ID: <5081B7F8.7040302@draigBrady.com> (raw)
In-Reply-To: <CAMjzKwXZLGX7EM7dVOHWcN-8Ay40bbhiR4v5M352Xd2g2uHY1g@mail.gmail.com>
On 10/13/2012 08:54 AM, abhishek agarwal wrote:
> Hi folks..
>
> I was thinking that why cant we have a timeout option in perf stat
> command. The timeout feature will help us to profile a process for a
> stipulated time (preferably in millisecs) and make perf stat return
> after that time.
> Eg:
>
> perf stat --timeout=10 sleep 100
>
> This will make perf return and report stats after 10 ms...
>
> Hope anyone can shed some more light on the idea
It seems preferable to use the timeout program to do this.
Either sending a handled signal to the perf process like:
timeout -s HUP 10 perf stat sleep 100
Or even better, just use that to kill the monitored process itself
perf stat timeout 10 sleep 100
cheers,
Pádraig.
next prev parent reply other threads:[~2012-10-20 16:57 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-13 15:54 [Perf] Adding timeout option abhishek agarwal
2012-10-19 20:28 ` Pádraig Brady [this message]
2012-10-21 4:18 ` abhishek agarwal
2012-10-22 11:02 ` Pádraig Brady
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=5081B7F8.7040302@draigBrady.com \
--to=p@draigbrady.com \
--cc=abhigem.126@gmail.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