diff options
author | David Ahern <dsahern@gmail.com> | 2013-08-20 13:15:45 -0400 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2013-08-26 16:25:35 -0400 |
commit | ac9be8ee4ecdeae73c78d84ebfe37009e11cf99d (patch) | |
tree | 718b8a8b74c416f9127653b3a84a5dd16307ca1e | |
parent | c24ff998fc420891f17d73acab6766823d492175 (diff) |
perf trace: Make command line arguments consistent with perf-record
Common arguments like thread id, CPU list, mmap pages, etc should be
consistent across perf commands.
v3: Updated man page
v2: rebased to latest core branch
Signed-off-by: David Ahern <dsahern@gmail.com>
Link: http://lkml.kernel.org/r/1377018945-21940-1-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
-rw-r--r-- | tools/perf/Documentation/perf-trace.txt | 6 | ||||
-rw-r--r-- | tools/perf/builtin-trace.c | 12 |
2 files changed, 12 insertions, 6 deletions
diff --git a/tools/perf/Documentation/perf-trace.txt b/tools/perf/Documentation/perf-trace.txt index 2794efce47a1..cb3371eb597d 100644 --- a/tools/perf/Documentation/perf-trace.txt +++ b/tools/perf/Documentation/perf-trace.txt | |||
@@ -23,6 +23,7 @@ analysis phases. | |||
23 | OPTIONS | 23 | OPTIONS |
24 | ------- | 24 | ------- |
25 | 25 | ||
26 | -a:: | ||
26 | --all-cpus:: | 27 | --all-cpus:: |
27 | System-wide collection from all CPUs. | 28 | System-wide collection from all CPUs. |
28 | 29 | ||
@@ -38,18 +39,23 @@ OPTIONS | |||
38 | --pid=:: | 39 | --pid=:: |
39 | Record events on existing process ID (comma separated list). | 40 | Record events on existing process ID (comma separated list). |
40 | 41 | ||
42 | -t:: | ||
41 | --tid=:: | 43 | --tid=:: |
42 | Record events on existing thread ID (comma separated list). | 44 | Record events on existing thread ID (comma separated list). |
43 | 45 | ||
46 | -u:: | ||
44 | --uid=:: | 47 | --uid=:: |
45 | Record events in threads owned by uid. Name or number. | 48 | Record events in threads owned by uid. Name or number. |
46 | 49 | ||
50 | -i:: | ||
47 | --no-inherit:: | 51 | --no-inherit:: |
48 | Child tasks do not inherit counters. | 52 | Child tasks do not inherit counters. |
49 | 53 | ||
54 | -m:: | ||
50 | --mmap-pages=:: | 55 | --mmap-pages=:: |
51 | Number of mmap data pages. Must be a power of two. | 56 | Number of mmap data pages. Must be a power of two. |
52 | 57 | ||
58 | -C:: | ||
53 | --cpu:: | 59 | --cpu:: |
54 | Collect samples only on the list of CPUs provided. Multiple CPUs can be provided as a | 60 | Collect samples only on the list of CPUs provided. Multiple CPUs can be provided as a |
55 | comma-separated list with no space: 0,1. Ranges of CPUs are specified with -: 0-2. | 61 | comma-separated list with no space: 0,1. Ranges of CPUs are specified with -: 0-2. |
diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c index 42353165472a..9891d8cdb73d 100644 --- a/tools/perf/builtin-trace.c +++ b/tools/perf/builtin-trace.c | |||
@@ -693,17 +693,17 @@ int cmd_trace(int argc, const char **argv, const char *prefix __maybe_unused) | |||
693 | OPT_STRING('o', "output", &output_name, "file", "output file name"), | 693 | OPT_STRING('o', "output", &output_name, "file", "output file name"), |
694 | OPT_STRING('p', "pid", &trace.opts.target.pid, "pid", | 694 | OPT_STRING('p', "pid", &trace.opts.target.pid, "pid", |
695 | "trace events on existing process id"), | 695 | "trace events on existing process id"), |
696 | OPT_STRING(0, "tid", &trace.opts.target.tid, "tid", | 696 | OPT_STRING('t', "tid", &trace.opts.target.tid, "tid", |
697 | "trace events on existing thread id"), | 697 | "trace events on existing thread id"), |
698 | OPT_BOOLEAN(0, "all-cpus", &trace.opts.target.system_wide, | 698 | OPT_BOOLEAN('a', "all-cpus", &trace.opts.target.system_wide, |
699 | "system-wide collection from all CPUs"), | 699 | "system-wide collection from all CPUs"), |
700 | OPT_STRING(0, "cpu", &trace.opts.target.cpu_list, "cpu", | 700 | OPT_STRING('C', "cpu", &trace.opts.target.cpu_list, "cpu", |
701 | "list of cpus to monitor"), | 701 | "list of cpus to monitor"), |
702 | OPT_BOOLEAN(0, "no-inherit", &trace.opts.no_inherit, | 702 | OPT_BOOLEAN('i', "no-inherit", &trace.opts.no_inherit, |
703 | "child tasks do not inherit counters"), | 703 | "child tasks do not inherit counters"), |
704 | OPT_UINTEGER(0, "mmap-pages", &trace.opts.mmap_pages, | 704 | OPT_UINTEGER('m', "mmap-pages", &trace.opts.mmap_pages, |
705 | "number of mmap data pages"), | 705 | "number of mmap data pages"), |
706 | OPT_STRING(0, "uid", &trace.opts.target.uid_str, "user", | 706 | OPT_STRING('u', "uid", &trace.opts.target.uid_str, "user", |
707 | "user to profile"), | 707 | "user to profile"), |
708 | OPT_CALLBACK(0, "duration", &trace, "float", | 708 | OPT_CALLBACK(0, "duration", &trace, "float", |
709 | "show only events with duration > N.M ms", | 709 | "show only events with duration > N.M ms", |