summaryrefslogtreecommitdiffstats
path: root/tools/perf/perf.h
diff options
context:
space:
mode:
authorNamhyung Kim <namhyung.kim@lge.com>2012-04-26 14:15:15 +0900
committerArnaldo Carvalho de Melo <acme@redhat.com>2012-05-02 15:17:58 -0300
commitbea0340582dc47b447a014f5bf9f460925afdaf4 (patch)
tree0fe4a6fe7b287367b127ac7394086ff0c913588a /tools/perf/perf.h
parentc651214e90e5c150015f7524a6bfc298ad61435f (diff)
downloadblackbird-op-linux-bea0340582dc47b447a014f5bf9f460925afdaf4.tar.gz
blackbird-op-linux-bea0340582dc47b447a014f5bf9f460925afdaf4.zip
perf tools: Introduce struct perf_target
The perf_target struct will be used for taking care of cpu/thread maps based on user's input. Since it is used on various subcommands it'd better factoring it out. Thanks to Arnaldo for suggesting the better name. Signed-off-by: Namhyung Kim <namhyung.kim@lge.com> Reviewed-by: David Ahern <dsahern@gmail.com> Cc: David Ahern <dsahern@gmail.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: Namhyung Kim <namhyung@gmail.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1335417327-11796-2-git-send-email-namhyung.kim@lge.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/perf.h')
-rw-r--r--tools/perf/perf.h15
1 files changed, 10 insertions, 5 deletions
diff --git a/tools/perf/perf.h b/tools/perf/perf.h
index 89e3355ab173..7e226c0e0e31 100644
--- a/tools/perf/perf.h
+++ b/tools/perf/perf.h
@@ -207,10 +207,17 @@ extern const char perf_version_string[];
void pthread__unblock_sigwinch(void);
-struct perf_record_opts {
- const char *target_pid;
- const char *target_tid;
+struct perf_target {
+ const char *pid;
+ const char *tid;
+ const char *cpu_list;
+ const char *uid_str;
uid_t uid;
+ bool system_wide;
+};
+
+struct perf_record_opts {
+ struct perf_target target;
bool call_graph;
bool group;
bool inherit_stat;
@@ -223,7 +230,6 @@ struct perf_record_opts {
bool sample_time;
bool sample_id_all_missing;
bool exclude_guest_missing;
- bool system_wide;
bool period;
unsigned int freq;
unsigned int mmap_pages;
@@ -231,7 +237,6 @@ struct perf_record_opts {
int branch_stack;
u64 default_interval;
u64 user_interval;
- const char *cpu_list;
};
#endif
OpenPOWER on IntegriCloud