public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Wang Nan <wangnan0@huawei.com>
Cc: linux-kernel@vger.kernel.org, pi3orama@163.com,
	He Kuang <hekuang@huawei.com>,
	Arnaldo Carvalho de Melo <acme@redhat.com>,
	Adrian Hunter <adrian.hunter@intel.com>,
	Jiri Olsa <jolsa@kernel.org>,
	Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>,
	Namhyung Kim <namhyung@kernel.org>, Zefan Li <lizefan@huawei.com>
Subject: Re: [PATCH v2 2/6] perf record: Split output into multiple files via '--switch-output'
Date: Thu, 14 Apr 2016 20:59:13 -0300	[thread overview]
Message-ID: <20160414235913.GK9056@kernel.org> (raw)
In-Reply-To: <1460643725-167413-3-git-send-email-wangnan0@huawei.com>

Em Thu, Apr 14, 2016 at 02:22:01PM +0000, Wang Nan escreveu:
> Allow 'perf record' splits its output into multiple files.
> 
> For example:
> 
>  # ~/perf record -a --timestamp-filename --switch-output &
>  [1] 10763
>  # kill -s SIGUSR2 10763
>  [ perf record: dump data: Woken up 1 times ]
>  # [ perf record: Dump perf.data.2015122622314468 ]
> 
>  # kill -s SIGUSR2 10763
>  [ perf record: dump data: Woken up 1 times ]
>  # [ perf record: Dump perf.data.2015122622314762 ]
> 
>  # kill -s SIGUSR2 10763
>  [ perf record: dump data: Woken up 1 times ]
>  #[ perf record: Dump perf.data.2015122622315171 ]
> 
>  # fg
>  perf record -a --timestamp-filename --switch-output
>  ^C[ perf record: Woken up 1 times to write data ]
>  [ perf record: Dump perf.data.2015122622315513 ]
>  [ perf record: Captured and wrote 0.014 MB perf.data.<timestamp> (296 samples) ]

Added this as an initial man page entry:


diff --git a/tools/perf/Documentation/perf-record.txt b/tools/perf/Documentation/perf-record.txt
index 19aa17532a16..a77a431ca4ef 100644
--- a/tools/perf/Documentation/perf-record.txt
+++ b/tools/perf/Documentation/perf-record.txt
@@ -347,6 +347,14 @@ Configure all used events to run in kernel space.
 --all-user::
 Configure all used events to run in user space.
 
+--switch-output::
+Generate multiple perf.data files, timestamp prefixed, switching to a new one
+when receiving a SIGUSR2.
+
+A possible use case is to, given an external event, slice the perf.data file
+that gets then processed, possibly via a perf script, to decide if that
+particular perf.data snapshot should be kept or not.
+
 SEE ALSO
 --------
 linkperf:perf-stat[1], linkperf:perf-list[1]

  reply	other threads:[~2016-04-14 23:59 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-14 14:21 [PATCH v2 0/6] perf tools: Use SIGUSR2 control data dumpping Wang Nan
2016-04-14 14:22 ` [PATCH v2 1/6] perf tools: Extrace trigger class from auxtrace_snapshot Wang Nan
2016-04-14 14:22 ` [PATCH v2 2/6] perf record: Split output into multiple files via '--switch-output' Wang Nan
2016-04-14 23:59   ` Arnaldo Carvalho de Melo [this message]
2016-04-14 14:22 ` [PATCH v2 3/6] perf record: Force enable --timestamp-filename when --switch-output is provided Wang Nan
2016-04-14 14:22 ` [PATCH v2 4/6] perf record: Disable buildid cache options by default in switch output mode Wang Nan
2016-04-14 14:22 ` [PATCH v2 5/6] perf record: Re-synthesize tracking events after output switching Wang Nan
2016-04-14 14:22 ` [PATCH v2 6/6] perf record: Generate tracking events for process forked by perf Wang Nan
2016-04-15  0:19 ` [PATCH v2 0/6] perf tools: Use SIGUSR2 control data dumpping Arnaldo Carvalho de Melo
2016-04-15 13:14   ` Adrian Hunter
2016-04-15 13:35     ` Arnaldo Carvalho de Melo
2016-04-15 13:41       ` Wangnan (F)

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=20160414235913.GK9056@kernel.org \
    --to=acme@kernel.org \
    --cc=acme@redhat.com \
    --cc=adrian.hunter@intel.com \
    --cc=hekuang@huawei.com \
    --cc=jolsa@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lizefan@huawei.com \
    --cc=masami.hiramatsu.pt@hitachi.com \
    --cc=namhyung@kernel.org \
    --cc=pi3orama@163.com \
    --cc=wangnan0@huawei.com \
    /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