All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/6][perf/core] perf tools: Fixes
@ 2016-03-24 12:52 Jiri Olsa
  2016-03-24 12:52 ` [PATCH 1/6] perf mem: Add --ldlat option Jiri Olsa
                   ` (6 more replies)
  0 siblings, 7 replies; 16+ messages in thread
From: Jiri Olsa @ 2016-03-24 12:52 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: lkml, David Ahern, Ingo Molnar, Namhyung Kim, Peter Zijlstra,
	Stephane Eranian, Andi Kleen

hi,
sending assorted fixes and leftover from previous mem patchset.

Also available in here:
  git://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
  perf/fixes

thanks,
jirka
---
Jiri Olsa (6):
      perf mem: Add --ldlat option
      perf mem: Add -U/-K (--all-user/--all-kernel) options
      perf tools: Make hists__collapse_insert_entry static
      perf tools: Introduce trim function
      perf tools: Unify -f/--force option documentation
      perf tests: Add test to check for event times

 tools/perf/Documentation/perf-annotate.txt |   2 +-
 tools/perf/Documentation/perf-diff.txt     |   2 +-
 tools/perf/Documentation/perf-mem.txt      |  11 +++++
 tools/perf/Documentation/perf-report.txt   |   2 +-
 tools/perf/Documentation/perf-script.txt   |   4 ++
 tools/perf/builtin-mem.c                   |  12 ++++-
 tools/perf/tests/Build                     |   1 +
 tools/perf/tests/builtin-test.c            |   4 ++
 tools/perf/tests/event-times.c             | 236 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 tools/perf/tests/tests.h                   |   1 +
 tools/perf/ui/browsers/hists.c             |   3 +-
 tools/perf/ui/stdio/hist.c                 |   3 +-
 tools/perf/util/hist.c                     |   5 +-
 tools/perf/util/hist.h                     |   2 -
 tools/perf/util/mem-events.c               |  17 ++++++-
 tools/perf/util/mem-events.h               |   1 +
 tools/perf/util/util.h                     |   5 ++
 17 files changed, 298 insertions(+), 13 deletions(-)
 create mode 100644 tools/perf/tests/event-times.c

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH 1/6] perf mem: Add --ldlat option
  2016-03-24 12:52 [PATCH 0/6][perf/core] perf tools: Fixes Jiri Olsa
@ 2016-03-24 12:52 ` Jiri Olsa
  2016-03-24 15:57   ` Arnaldo Carvalho de Melo
  2016-03-24 12:52 ` [PATCH 2/6] perf mem: Add -U/-K (--all-user/--all-kernel) options Jiri Olsa
                   ` (5 subsequent siblings)
  6 siblings, 1 reply; 16+ messages in thread
From: Jiri Olsa @ 2016-03-24 12:52 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: lkml, David Ahern, Ingo Molnar, Namhyung Kim, Peter Zijlstra,
	Stephane Eranian, Andi Kleen

Adding --ldlat option to specify desired latency
for loads event.

Specify 50 as loads event latency:

  $ perf mem record -e ldlat-loads -v --ldlat 50 true
  calling: record -W -d -e cpu/mem-loads,ldlat=50/P true

Link: http://lkml.kernel.org/n/tip-ec2m0cvivkfs8uhtiv411hfc@git.kernel.org
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
 tools/perf/Documentation/perf-mem.txt |  3 +++
 tools/perf/builtin-mem.c              |  1 +
 tools/perf/util/mem-events.c          | 17 ++++++++++++++++-
 tools/perf/util/mem-events.h          |  1 +
 4 files changed, 21 insertions(+), 1 deletion(-)

diff --git a/tools/perf/Documentation/perf-mem.txt b/tools/perf/Documentation/perf-mem.txt
index 43310d8661fe..6676d2784733 100644
--- a/tools/perf/Documentation/perf-mem.txt
+++ b/tools/perf/Documentation/perf-mem.txt
@@ -48,6 +48,9 @@ OPTIONS
 	option can be passed in record mode. It will be interpreted the same way as perf
 	record.
 
+--ldload::
+	Specify desired latency for loads event.
+
 SEE ALSO
 --------
 linkperf:perf-record[1], linkperf:perf-report[1]
diff --git a/tools/perf/builtin-mem.c b/tools/perf/builtin-mem.c
index 914f6fe192e3..bf0bfca5be20 100644
--- a/tools/perf/builtin-mem.c
+++ b/tools/perf/builtin-mem.c
@@ -66,6 +66,7 @@ static int __cmd_record(int argc, const char **argv, struct perf_mem *mem)
 	OPT_CALLBACK('e', "event", &mem, "event",
 		     "event selector. use 'perf mem record -e list' to list available events",
 		     parse_record_events),
+	OPT_UINTEGER(0, "ldlat", &perf_mem_events__loads_ldlat, "mem-loads latency"),
 	OPT_INCR('v', "verbose", &verbose,
 		 "be more verbose (show counter open errors, etc)"),
 	OPT_END()
diff --git a/tools/perf/util/mem-events.c b/tools/perf/util/mem-events.c
index e6b01e6f70a0..3ff60f08a778 100644
--- a/tools/perf/util/mem-events.c
+++ b/tools/perf/util/mem-events.c
@@ -10,10 +10,12 @@
 #include "debug.h"
 #include "symbol.h"
 
+unsigned int perf_mem_events__loads_ldlat = 30;
+
 #define E(t, n, s) { .tag = t, .name = n, .sysfs_name = s }
 
 struct perf_mem_event perf_mem_events[PERF_MEM_EVENTS__MAX] = {
-	E("ldlat-loads",	"cpu/mem-loads,ldlat=30/P",	"mem-loads"),
+	E("ldlat-loads",	"cpu/mem-loads,ldlat=%u/P",	"mem-loads"),
 	E("ldlat-stores",	"cpu/mem-stores/P",		"mem-stores"),
 	E("stlb-miss-loads",	"cpu/mem-stlb-miss-loads/P",	"mem-stlb-miss-loads"),
 	E("stlb-miss-stores",	"cpu/mem-stlb-miss-stores/P",	"mem-stlb-miss-stores"),
@@ -39,8 +41,21 @@ struct perf_mem_event perf_mem_events[PERF_MEM_EVENTS__MAX] = {
 
 #undef E
 
+static char mem_loads_name[100];
+static bool mem_loads_name__init;
+
 char *perf_mem_events__name(int i)
 {
+	if (i == PERF_MEM_EVENTS__LOAD) {
+		if (!mem_loads_name__init) {
+			mem_loads_name__init = true;
+			scnprintf(mem_loads_name, sizeof(mem_loads_name),
+				  perf_mem_events[i].name,
+				  perf_mem_events__loads_ldlat);
+		}
+		return mem_loads_name;
+	}
+
 	return (char *)perf_mem_events[i].name;
 }
 
diff --git a/tools/perf/util/mem-events.h b/tools/perf/util/mem-events.h
index de88f4267cd1..939786ffab2a 100644
--- a/tools/perf/util/mem-events.h
+++ b/tools/perf/util/mem-events.h
@@ -37,6 +37,7 @@ enum {
 };
 
 extern struct perf_mem_event perf_mem_events[PERF_MEM_EVENTS__MAX];
+extern unsigned int perf_mem_events__loads_ldlat;
 
 int perf_mem_events__parse(const char *str);
 int perf_mem_events__init(void);
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 2/6] perf mem: Add -U/-K (--all-user/--all-kernel) options
  2016-03-24 12:52 [PATCH 0/6][perf/core] perf tools: Fixes Jiri Olsa
  2016-03-24 12:52 ` [PATCH 1/6] perf mem: Add --ldlat option Jiri Olsa
@ 2016-03-24 12:52 ` Jiri Olsa
  2016-03-24 15:58   ` Arnaldo Carvalho de Melo
  2016-03-31  6:51   ` [tip:perf/core] " tip-bot for Jiri Olsa
  2016-03-24 12:52 ` [PATCH 3/6] perf tools: Make hists__collapse_insert_entry static Jiri Olsa
                   ` (4 subsequent siblings)
  6 siblings, 2 replies; 16+ messages in thread
From: Jiri Olsa @ 2016-03-24 12:52 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: lkml, David Ahern, Ingo Molnar, Namhyung Kim, Peter Zijlstra,
	Stephane Eranian, Andi Kleen

Add -U/-K (--all-user/--all-kernel) options to use
the perf record --all-user/--all-kernel options.

Link: http://lkml.kernel.org/n/tip-adxn5c48oe0gmjrjmq6we27q@git.kernel.org
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
 tools/perf/Documentation/perf-mem.txt |  8 ++++++++
 tools/perf/builtin-mem.c              | 11 ++++++++++-
 2 files changed, 18 insertions(+), 1 deletion(-)

diff --git a/tools/perf/Documentation/perf-mem.txt b/tools/perf/Documentation/perf-mem.txt
index 6676d2784733..f8e23f50ce59 100644
--- a/tools/perf/Documentation/perf-mem.txt
+++ b/tools/perf/Documentation/perf-mem.txt
@@ -51,6 +51,14 @@ OPTIONS
 --ldload::
 	Specify desired latency for loads event.
 
+-K::
+--all-kernel::
+	Configure all used events to run in kernel space.
+
+-U::
+--all-user::
+	Configure all used events to run in user space.
+
 SEE ALSO
 --------
 linkperf:perf-record[1], linkperf:perf-report[1]
diff --git a/tools/perf/builtin-mem.c b/tools/perf/builtin-mem.c
index bf0bfca5be20..5dad76e1c8df 100644
--- a/tools/perf/builtin-mem.c
+++ b/tools/perf/builtin-mem.c
@@ -62,6 +62,7 @@ static int __cmd_record(int argc, const char **argv, struct perf_mem *mem)
 	int rec_argc, i = 0, j;
 	const char **rec_argv;
 	int ret;
+	bool all_user = false, all_kernel = false;
 	struct option options[] = {
 	OPT_CALLBACK('e', "event", &mem, "event",
 		     "event selector. use 'perf mem record -e list' to list available events",
@@ -69,13 +70,15 @@ static int __cmd_record(int argc, const char **argv, struct perf_mem *mem)
 	OPT_UINTEGER(0, "ldlat", &perf_mem_events__loads_ldlat, "mem-loads latency"),
 	OPT_INCR('v', "verbose", &verbose,
 		 "be more verbose (show counter open errors, etc)"),
+	OPT_BOOLEAN('U', "--all-user", &all_user, "collect only user level data"),
+	OPT_BOOLEAN('K', "--all-kernel", &all_kernel, "collect only kernel level data"),
 	OPT_END()
 	};
 
 	argc = parse_options(argc, argv, options, record_mem_usage,
 			     PARSE_OPT_STOP_AT_NON_OPTION);
 
-	rec_argc = argc + 7; /* max number of arguments */
+	rec_argc = argc + 9; /* max number of arguments */
 	rec_argv = calloc(rec_argc + 1, sizeof(char *));
 	if (!rec_argv)
 		return -1;
@@ -104,6 +107,12 @@ static int __cmd_record(int argc, const char **argv, struct perf_mem *mem)
 		rec_argv[i++] = perf_mem_events__name(j);
 	};
 
+	if (all_user)
+		rec_argv[i++] = "--all-user";
+
+	if (all_kernel)
+		rec_argv[i++] = "--all-kernel";
+
 	for (j = 0; j < argc; j++, i++)
 		rec_argv[i] = argv[j];
 
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 3/6] perf tools: Make hists__collapse_insert_entry static
  2016-03-24 12:52 [PATCH 0/6][perf/core] perf tools: Fixes Jiri Olsa
  2016-03-24 12:52 ` [PATCH 1/6] perf mem: Add --ldlat option Jiri Olsa
  2016-03-24 12:52 ` [PATCH 2/6] perf mem: Add -U/-K (--all-user/--all-kernel) options Jiri Olsa
@ 2016-03-24 12:52 ` Jiri Olsa
  2016-03-31  6:52   ` [tip:perf/core] " tip-bot for Jiri Olsa
  2016-03-24 12:52 ` [PATCH 4/6] perf tools: Introduce trim function Jiri Olsa
                   ` (3 subsequent siblings)
  6 siblings, 1 reply; 16+ messages in thread
From: Jiri Olsa @ 2016-03-24 12:52 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: lkml, David Ahern, Ingo Molnar, Namhyung Kim, Peter Zijlstra,
	Stephane Eranian, Andi Kleen

No need to export hists__collapse_insert_entry function.

Link: http://lkml.kernel.org/n/tip-7fuk01zwjefo0aoqo42co0vy@git.kernel.org
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
 tools/perf/util/hist.c | 5 +++--
 tools/perf/util/hist.h | 2 --
 2 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/tools/perf/util/hist.c b/tools/perf/util/hist.c
index 31c4641fe5ff..3d34c57dfbe2 100644
--- a/tools/perf/util/hist.c
+++ b/tools/perf/util/hist.c
@@ -1295,8 +1295,9 @@ static int hists__hierarchy_insert_entry(struct hists *hists,
 	return ret;
 }
 
-int hists__collapse_insert_entry(struct hists *hists, struct rb_root *root,
-				 struct hist_entry *he)
+static int hists__collapse_insert_entry(struct hists *hists,
+					struct rb_root *root,
+					struct hist_entry *he)
 {
 	struct rb_node **p = &root->rb_node;
 	struct rb_node *parent = NULL;
diff --git a/tools/perf/util/hist.h b/tools/perf/util/hist.h
index bec0cd660fbd..588596561cb3 100644
--- a/tools/perf/util/hist.h
+++ b/tools/perf/util/hist.h
@@ -199,8 +199,6 @@ int hists__init(void);
 int __hists__init(struct hists *hists, struct perf_hpp_list *hpp_list);
 
 struct rb_root *hists__get_rotate_entries_in(struct hists *hists);
-int hists__collapse_insert_entry(struct hists *hists,
-				  struct rb_root *root, struct hist_entry *he);
 
 struct perf_hpp {
 	char *buf;
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 4/6] perf tools: Introduce trim function
  2016-03-24 12:52 [PATCH 0/6][perf/core] perf tools: Fixes Jiri Olsa
                   ` (2 preceding siblings ...)
  2016-03-24 12:52 ` [PATCH 3/6] perf tools: Make hists__collapse_insert_entry static Jiri Olsa
@ 2016-03-24 12:52 ` Jiri Olsa
  2016-03-24 12:52 ` [PATCH 5/6] perf tools: Unify -f/--force option documentation Jiri Olsa
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 16+ messages in thread
From: Jiri Olsa @ 2016-03-24 12:52 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: lkml, David Ahern, Ingo Molnar, Namhyung Kim, Peter Zijlstra,
	Stephane Eranian, Andi Kleen

To be used in cases for both sides trim.

Link: http://lkml.kernel.org/n/tip-7fuk01zwjefo0aoqo42co0vy@git.kernel.org
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
 tools/perf/ui/browsers/hists.c | 3 +--
 tools/perf/ui/stdio/hist.c     | 3 +--
 tools/perf/util/util.h         | 5 +++++
 3 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
index 4b9816555946..ba10c86cb56c 100644
--- a/tools/perf/ui/browsers/hists.c
+++ b/tools/perf/ui/browsers/hists.c
@@ -1607,9 +1607,8 @@ static int hists_browser__scnprintf_hierarchy_headers(struct hist_browser *brows
 
 			ret = fmt->header(fmt, &dummy_hpp, hists_to_evsel(hists));
 			dummy_hpp.buf[ret] = '\0';
-			rtrim(dummy_hpp.buf);
 
-			start = ltrim(dummy_hpp.buf);
+			start = trim(dummy_hpp.buf);
 			ret = strlen(start);
 
 			if (start != dummy_hpp.buf)
diff --git a/tools/perf/ui/stdio/hist.c b/tools/perf/ui/stdio/hist.c
index 7aff5acf3265..560eb47d56f9 100644
--- a/tools/perf/ui/stdio/hist.c
+++ b/tools/perf/ui/stdio/hist.c
@@ -569,9 +569,8 @@ static int print_hierarchy_header(struct hists *hists, struct perf_hpp *hpp,
 			first_col = false;
 
 			fmt->header(fmt, hpp, hists_to_evsel(hists));
-			rtrim(hpp->buf);
 
-			header_width += fprintf(fp, "%s", ltrim(hpp->buf));
+			header_width += fprintf(fp, "%s", trim(hpp->buf));
 		}
 	}
 
diff --git a/tools/perf/util/util.h b/tools/perf/util/util.h
index 8298d607c738..3bf3de86d429 100644
--- a/tools/perf/util/util.h
+++ b/tools/perf/util/util.h
@@ -254,6 +254,11 @@ int hex2u64(const char *ptr, u64 *val);
 char *ltrim(char *s);
 char *rtrim(char *s);
 
+static inline char *trim(char *s)
+{
+	return ltrim(rtrim(s));
+}
+
 void dump_stack(void);
 void sighandler_dump_stack(int sig);
 
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 5/6] perf tools: Unify -f/--force option documentation
  2016-03-24 12:52 [PATCH 0/6][perf/core] perf tools: Fixes Jiri Olsa
                   ` (3 preceding siblings ...)
  2016-03-24 12:52 ` [PATCH 4/6] perf tools: Introduce trim function Jiri Olsa
@ 2016-03-24 12:52 ` Jiri Olsa
  2016-03-31  6:52   ` [tip:perf/core] perf tools: Make -f/--force option documentation consistent across tools tip-bot for Jiri Olsa
  2016-03-24 12:52 ` [PATCH 6/6] perf tests: Add test to check for event times Jiri Olsa
  2016-03-24 16:06 ` [PATCH 0/6][perf/core] perf tools: Fixes Arnaldo Carvalho de Melo
  6 siblings, 1 reply; 16+ messages in thread
From: Jiri Olsa @ 2016-03-24 12:52 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: lkml, David Ahern, Ingo Molnar, Namhyung Kim, Peter Zijlstra,
	Stephane Eranian, Andi Kleen

Link: http://lkml.kernel.org/n/tip-cximteb8r1a6750wz8sgeajh@git.kernel.org
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
 tools/perf/Documentation/perf-annotate.txt | 2 +-
 tools/perf/Documentation/perf-diff.txt     | 2 +-
 tools/perf/Documentation/perf-report.txt   | 2 +-
 tools/perf/Documentation/perf-script.txt   | 4 ++++
 4 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/tools/perf/Documentation/perf-annotate.txt b/tools/perf/Documentation/perf-annotate.txt
index e9cd39a92dc2..778f54d4d0bd 100644
--- a/tools/perf/Documentation/perf-annotate.txt
+++ b/tools/perf/Documentation/perf-annotate.txt
@@ -33,7 +33,7 @@ OPTIONS
 
 -f::
 --force::
-        Don't complain, do it.
+        Don't do ownership validation.
 
 -v::
 --verbose::
diff --git a/tools/perf/Documentation/perf-diff.txt b/tools/perf/Documentation/perf-diff.txt
index d1deb573877f..3e9490b9c533 100644
--- a/tools/perf/Documentation/perf-diff.txt
+++ b/tools/perf/Documentation/perf-diff.txt
@@ -75,7 +75,7 @@ OPTIONS
 
 -f::
 --force::
-       Don't complain, do it.
+        Don't do ownership validation.
 
 --symfs=<directory>::
         Look for files with symbols relative to this directory.
diff --git a/tools/perf/Documentation/perf-report.txt b/tools/perf/Documentation/perf-report.txt
index 12113992ac9d..496d42cdf02b 100644
--- a/tools/perf/Documentation/perf-report.txt
+++ b/tools/perf/Documentation/perf-report.txt
@@ -285,7 +285,7 @@ OPTIONS
 
 -f::
 --force::
-        Don't complain, do it.
+        Don't do ownership validation.
 
 --symfs=<directory>::
         Look for files with symbols relative to this directory.
diff --git a/tools/perf/Documentation/perf-script.txt b/tools/perf/Documentation/perf-script.txt
index 382ddfb45d1d..22ef3933342a 100644
--- a/tools/perf/Documentation/perf-script.txt
+++ b/tools/perf/Documentation/perf-script.txt
@@ -262,6 +262,10 @@ include::itrace.txt[]
 --ns::
 	Use 9 decimal places when displaying time (i.e. show the nanoseconds)
 
+-f::
+--force::
+	Don't do ownership validation.
+
 SEE ALSO
 --------
 linkperf:perf-record[1], linkperf:perf-script-perl[1],
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 6/6] perf tests: Add test to check for event times
  2016-03-24 12:52 [PATCH 0/6][perf/core] perf tools: Fixes Jiri Olsa
                   ` (4 preceding siblings ...)
  2016-03-24 12:52 ` [PATCH 5/6] perf tools: Unify -f/--force option documentation Jiri Olsa
@ 2016-03-24 12:52 ` Jiri Olsa
  2016-03-31  6:52   ` [tip:perf/core] " tip-bot for Jiri Olsa
  2016-03-24 16:06 ` [PATCH 0/6][perf/core] perf tools: Fixes Arnaldo Carvalho de Melo
  6 siblings, 1 reply; 16+ messages in thread
From: Jiri Olsa @ 2016-03-24 12:52 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: lkml, David Ahern, Ingo Molnar, Namhyung Kim, Peter Zijlstra,
	Stephane Eranian, Andi Kleen

This test creates software event 'cpu-clock'
attaches it in several ways and checks that
enabled and running times match.

Link: http://lkml.kernel.org/n/tip-y1g9g3qru2m03s8hzc2kuaor@git.kernel.org
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
 tools/perf/tests/Build          |   1 +
 tools/perf/tests/builtin-test.c |   4 +
 tools/perf/tests/event-times.c  | 236 ++++++++++++++++++++++++++++++++++++++++
 tools/perf/tests/tests.h        |   1 +
 4 files changed, 242 insertions(+)
 create mode 100644 tools/perf/tests/event-times.c

diff --git a/tools/perf/tests/Build b/tools/perf/tests/Build
index 1ba628ed049a..449fe97a555f 100644
--- a/tools/perf/tests/Build
+++ b/tools/perf/tests/Build
@@ -37,6 +37,7 @@ perf-y += topology.o
 perf-y += cpumap.o
 perf-y += stat.o
 perf-y += event_update.o
+perf-y += event-times.o
 
 $(OUTPUT)tests/llvm-src-base.c: tests/bpf-script-example.c tests/Build
 	$(call rule_mkdir)
diff --git a/tools/perf/tests/builtin-test.c b/tools/perf/tests/builtin-test.c
index f2b1dcac45d3..93c467015e71 100644
--- a/tools/perf/tests/builtin-test.c
+++ b/tools/perf/tests/builtin-test.c
@@ -204,6 +204,10 @@ static struct test generic_tests[] = {
 		.func = test__event_update,
 	},
 	{
+		.desc = "Test events times",
+		.func = test__event_times,
+	},
+	{
 		.func = NULL,
 	},
 };
diff --git a/tools/perf/tests/event-times.c b/tools/perf/tests/event-times.c
new file mode 100644
index 000000000000..95fb744f6628
--- /dev/null
+++ b/tools/perf/tests/event-times.c
@@ -0,0 +1,236 @@
+#include <linux/compiler.h>
+#include <string.h>
+#include "tests.h"
+#include "evlist.h"
+#include "evsel.h"
+#include "util.h"
+#include "debug.h"
+#include "thread_map.h"
+#include "target.h"
+
+static int attach__enable_on_exec(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+	struct target target = {
+		.uid = UINT_MAX,
+	};
+	const char *argv[] = { "true", NULL, };
+	char sbuf[STRERR_BUFSIZE];
+	int err;
+
+	pr_debug("attaching to spawned child, enable on exec\n");
+
+	err = perf_evlist__create_maps(evlist, &target);
+	if (err < 0) {
+		pr_debug("Not enough memory to create thread/cpu maps\n");
+		return err;
+	}
+
+	err = perf_evlist__prepare_workload(evlist, &target, argv, false, NULL);
+	if (err < 0) {
+		pr_debug("Couldn't run the workload!\n");
+		return err;
+	}
+
+	evsel->attr.enable_on_exec = 1;
+
+	err = perf_evlist__open(evlist);
+	if (err < 0) {
+		pr_debug("perf_evlist__open: %s\n",
+			 strerror_r(errno, sbuf, sizeof(sbuf)));
+		return err;
+	}
+
+	return perf_evlist__start_workload(evlist) == 1 ? TEST_OK : TEST_FAIL;
+}
+
+static int detach__enable_on_exec(struct perf_evlist *evlist)
+{
+	waitpid(evlist->workload.pid, NULL, 0);
+	return 0;
+}
+
+static int attach__current_disabled(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+	struct thread_map *threads;
+	int err;
+
+	pr_debug("attaching to current thread as disabled\n");
+
+	threads = thread_map__new(-1, getpid(), UINT_MAX);
+	if (threads == NULL) {
+		pr_debug("thread_map__new\n");
+		return -1;
+	}
+
+	evsel->attr.disabled = 1;
+
+	err = perf_evsel__open_per_thread(evsel, threads);
+	if (err) {
+		pr_debug("Failed to open event cpu-clock:u\n");
+		return err;
+	}
+
+	thread_map__put(threads);
+	return perf_evsel__enable(evsel) == 0 ? TEST_OK : TEST_FAIL;
+}
+
+static int attach__current_enabled(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+	struct thread_map *threads;
+	int err;
+
+	pr_debug("attaching to current thread as enabled\n");
+
+	threads = thread_map__new(-1, getpid(), UINT_MAX);
+	if (threads == NULL) {
+		pr_debug("failed to call thread_map__new\n");
+		return -1;
+	}
+
+	err = perf_evsel__open_per_thread(evsel, threads);
+
+	thread_map__put(threads);
+	return err == 0 ? TEST_OK : TEST_FAIL;
+}
+
+static int detach__disable(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+
+	return perf_evsel__enable(evsel);
+}
+
+static int attach__cpu_disabled(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+	struct cpu_map *cpus;
+	int err;
+
+	pr_debug("attaching to CPU 0 as enabled\n");
+
+	cpus = cpu_map__new("0");
+	if (cpus == NULL) {
+		pr_debug("failed to call cpu_map__new\n");
+		return -1;
+	}
+
+	evsel->attr.disabled = 1;
+
+	err = perf_evsel__open_per_cpu(evsel, cpus);
+	if (err) {
+		if (err == -EACCES)
+			return TEST_SKIP;
+
+		pr_debug("Failed to open event cpu-clock:u\n");
+		return err;
+	}
+
+	cpu_map__put(cpus);
+	return perf_evsel__enable(evsel);
+}
+
+static int attach__cpu_enabled(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+	struct cpu_map *cpus;
+	int err;
+
+	pr_debug("attaching to CPU 0 as enabled\n");
+
+	cpus = cpu_map__new("0");
+	if (cpus == NULL) {
+		pr_debug("failed to call cpu_map__new\n");
+		return -1;
+	}
+
+	err = perf_evsel__open_per_cpu(evsel, cpus);
+	if (err == -EACCES)
+		return TEST_SKIP;
+
+	cpu_map__put(cpus);
+	return err ? TEST_FAIL : TEST_OK;
+}
+
+static int test_times(int (attach)(struct perf_evlist *),
+		      int (detach)(struct perf_evlist *))
+{
+	struct perf_counts_values count;
+	struct perf_evlist *evlist = NULL;
+	struct perf_evsel *evsel;
+	int err = -1, i;
+
+	evlist = perf_evlist__new();
+	if (!evlist) {
+		pr_debug("failed to create event list\n");
+		goto out_err;
+	}
+
+	err = parse_events(evlist, "cpu-clock:u", NULL);
+	if (err) {
+		pr_debug("failed to parse event cpu-clock:u\n");
+		goto out_err;
+	}
+
+	evsel = perf_evlist__last(evlist);
+	evsel->attr.read_format |=
+		PERF_FORMAT_TOTAL_TIME_ENABLED |
+		PERF_FORMAT_TOTAL_TIME_RUNNING;
+
+	err = attach(evlist);
+	if (err == TEST_SKIP) {
+		pr_debug("  SKIP  : not enough rights\n");
+		return err;
+	}
+
+	TEST_ASSERT_VAL("failed to attach", !err);
+
+	for (i = 0; i < 100000000; i++) { }
+
+	TEST_ASSERT_VAL("failed to detach", !detach(evlist));
+
+	perf_evsel__read(evsel, 0, 0, &count);
+
+	err = !(count.ena == count.run);
+
+	pr_debug("  %s: ena %" PRIu64", run %" PRIu64"\n",
+		 !err ? "OK    " : "FAILED",
+		 count.ena, count.run);
+
+out_err:
+	if (evlist)
+		perf_evlist__delete(evlist);
+	return !err ? TEST_OK : TEST_FAIL;
+}
+
+/*
+ * This test creates software event 'cpu-clock'
+ * attaches it in several ways (explained below)
+ * and checks that enabled and running times
+ * match.
+ */
+int test__event_times(int subtest __maybe_unused)
+{
+	int err, ret = 0;
+
+#define _T(attach, detach)			\
+	err = test_times(attach, detach);	\
+	if (err && (ret == TEST_OK || ret == TEST_SKIP))	\
+		ret = err;
+
+	/* attach on newly spawned process after exec */
+	_T(attach__enable_on_exec,   detach__enable_on_exec)
+	/* attach on current process as enabled */
+	_T(attach__current_enabled,  detach__disable)
+	/* attach on current process as disabled */
+	_T(attach__current_disabled, detach__disable)
+	/* attach on cpu as disabled */
+	_T(attach__cpu_disabled,     detach__disable)
+	/* attach on cpu as enabled */
+	_T(attach__cpu_enabled,      detach__disable)
+
+#undef _T
+	return ret;
+}
diff --git a/tools/perf/tests/tests.h b/tools/perf/tests/tests.h
index 82b2b5e6ba7c..0fc946989cf0 100644
--- a/tools/perf/tests/tests.h
+++ b/tools/perf/tests/tests.h
@@ -85,6 +85,7 @@ int test__synthesize_stat_config(int subtest);
 int test__synthesize_stat(int subtest);
 int test__synthesize_stat_round(int subtest);
 int test__event_update(int subtest);
+int test__event_times(int subtest);
 
 #if defined(__arm__) || defined(__aarch64__)
 #ifdef HAVE_DWARF_UNWIND_SUPPORT
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* Re: [PATCH 1/6] perf mem: Add --ldlat option
  2016-03-24 12:52 ` [PATCH 1/6] perf mem: Add --ldlat option Jiri Olsa
@ 2016-03-24 15:57   ` Arnaldo Carvalho de Melo
  2016-03-26 16:06     ` Jiri Olsa
  0 siblings, 1 reply; 16+ messages in thread
From: Arnaldo Carvalho de Melo @ 2016-03-24 15:57 UTC (permalink / raw)
  To: Jiri Olsa
  Cc: lkml, David Ahern, Ingo Molnar, Namhyung Kim, Peter Zijlstra,
	Stephane Eranian, Andi Kleen

Em Thu, Mar 24, 2016 at 01:52:15PM +0100, Jiri Olsa escreveu:
> Adding --ldlat option to specify desired latency
> for loads event.
> 
> Specify 50 as loads event latency:
> 
>   $ perf mem record -e ldlat-loads -v --ldlat 50 true
>   calling: record -W -d -e cpu/mem-loads,ldlat=50/P true

We have all this infrastructure to set per-event settings, on the
command line, and here we end up adding a separate command line option
to do that? Why not something like:

	perf mem record -e ldlat-loads/lat=50/ true

?

- Arnaldo
 
> Link: http://lkml.kernel.org/n/tip-ec2m0cvivkfs8uhtiv411hfc@git.kernel.org
> Signed-off-by: Jiri Olsa <jolsa@kernel.org>
> ---
>  tools/perf/Documentation/perf-mem.txt |  3 +++
>  tools/perf/builtin-mem.c              |  1 +
>  tools/perf/util/mem-events.c          | 17 ++++++++++++++++-
>  tools/perf/util/mem-events.h          |  1 +
>  4 files changed, 21 insertions(+), 1 deletion(-)
> 
> diff --git a/tools/perf/Documentation/perf-mem.txt b/tools/perf/Documentation/perf-mem.txt
> index 43310d8661fe..6676d2784733 100644
> --- a/tools/perf/Documentation/perf-mem.txt
> +++ b/tools/perf/Documentation/perf-mem.txt
> @@ -48,6 +48,9 @@ OPTIONS
>  	option can be passed in record mode. It will be interpreted the same way as perf
>  	record.
>  
> +--ldload::
> +	Specify desired latency for loads event.
> +
>  SEE ALSO
>  --------
>  linkperf:perf-record[1], linkperf:perf-report[1]
> diff --git a/tools/perf/builtin-mem.c b/tools/perf/builtin-mem.c
> index 914f6fe192e3..bf0bfca5be20 100644
> --- a/tools/perf/builtin-mem.c
> +++ b/tools/perf/builtin-mem.c
> @@ -66,6 +66,7 @@ static int __cmd_record(int argc, const char **argv, struct perf_mem *mem)
>  	OPT_CALLBACK('e', "event", &mem, "event",
>  		     "event selector. use 'perf mem record -e list' to list available events",
>  		     parse_record_events),
> +	OPT_UINTEGER(0, "ldlat", &perf_mem_events__loads_ldlat, "mem-loads latency"),
>  	OPT_INCR('v', "verbose", &verbose,
>  		 "be more verbose (show counter open errors, etc)"),
>  	OPT_END()
> diff --git a/tools/perf/util/mem-events.c b/tools/perf/util/mem-events.c
> index e6b01e6f70a0..3ff60f08a778 100644
> --- a/tools/perf/util/mem-events.c
> +++ b/tools/perf/util/mem-events.c
> @@ -10,10 +10,12 @@
>  #include "debug.h"
>  #include "symbol.h"
>  
> +unsigned int perf_mem_events__loads_ldlat = 30;
> +
>  #define E(t, n, s) { .tag = t, .name = n, .sysfs_name = s }
>  
>  struct perf_mem_event perf_mem_events[PERF_MEM_EVENTS__MAX] = {
> -	E("ldlat-loads",	"cpu/mem-loads,ldlat=30/P",	"mem-loads"),
> +	E("ldlat-loads",	"cpu/mem-loads,ldlat=%u/P",	"mem-loads"),
>  	E("ldlat-stores",	"cpu/mem-stores/P",		"mem-stores"),
>  	E("stlb-miss-loads",	"cpu/mem-stlb-miss-loads/P",	"mem-stlb-miss-loads"),
>  	E("stlb-miss-stores",	"cpu/mem-stlb-miss-stores/P",	"mem-stlb-miss-stores"),
> @@ -39,8 +41,21 @@ struct perf_mem_event perf_mem_events[PERF_MEM_EVENTS__MAX] = {
>  
>  #undef E
>  
> +static char mem_loads_name[100];
> +static bool mem_loads_name__init;
> +
>  char *perf_mem_events__name(int i)
>  {
> +	if (i == PERF_MEM_EVENTS__LOAD) {
> +		if (!mem_loads_name__init) {
> +			mem_loads_name__init = true;
> +			scnprintf(mem_loads_name, sizeof(mem_loads_name),
> +				  perf_mem_events[i].name,
> +				  perf_mem_events__loads_ldlat);
> +		}
> +		return mem_loads_name;
> +	}
> +
>  	return (char *)perf_mem_events[i].name;
>  }
>  
> diff --git a/tools/perf/util/mem-events.h b/tools/perf/util/mem-events.h
> index de88f4267cd1..939786ffab2a 100644
> --- a/tools/perf/util/mem-events.h
> +++ b/tools/perf/util/mem-events.h
> @@ -37,6 +37,7 @@ enum {
>  };
>  
>  extern struct perf_mem_event perf_mem_events[PERF_MEM_EVENTS__MAX];
> +extern unsigned int perf_mem_events__loads_ldlat;
>  
>  int perf_mem_events__parse(const char *str);
>  int perf_mem_events__init(void);
> -- 
> 2.4.3

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH 2/6] perf mem: Add -U/-K (--all-user/--all-kernel) options
  2016-03-24 12:52 ` [PATCH 2/6] perf mem: Add -U/-K (--all-user/--all-kernel) options Jiri Olsa
@ 2016-03-24 15:58   ` Arnaldo Carvalho de Melo
  2016-03-31  6:51   ` [tip:perf/core] " tip-bot for Jiri Olsa
  1 sibling, 0 replies; 16+ messages in thread
From: Arnaldo Carvalho de Melo @ 2016-03-24 15:58 UTC (permalink / raw)
  To: Jiri Olsa
  Cc: lkml, David Ahern, Ingo Molnar, Namhyung Kim, Peter Zijlstra,
	Stephane Eranian, Andi Kleen

Em Thu, Mar 24, 2016 at 01:52:16PM +0100, Jiri Olsa escreveu:
> Add -U/-K (--all-user/--all-kernel) options to use
> the perf record --all-user/--all-kernel options.

Applying this after fixing up the clash due to the first patch not being
merged so far.
 
> Link: http://lkml.kernel.org/n/tip-adxn5c48oe0gmjrjmq6we27q@git.kernel.org
> Signed-off-by: Jiri Olsa <jolsa@kernel.org>
> ---
>  tools/perf/Documentation/perf-mem.txt |  8 ++++++++
>  tools/perf/builtin-mem.c              | 11 ++++++++++-
>  2 files changed, 18 insertions(+), 1 deletion(-)
> 
> diff --git a/tools/perf/Documentation/perf-mem.txt b/tools/perf/Documentation/perf-mem.txt
> index 6676d2784733..f8e23f50ce59 100644
> --- a/tools/perf/Documentation/perf-mem.txt
> +++ b/tools/perf/Documentation/perf-mem.txt
> @@ -51,6 +51,14 @@ OPTIONS
>  --ldload::
>  	Specify desired latency for loads event.
>  
> +-K::
> +--all-kernel::
> +	Configure all used events to run in kernel space.
> +
> +-U::
> +--all-user::
> +	Configure all used events to run in user space.
> +
>  SEE ALSO
>  --------
>  linkperf:perf-record[1], linkperf:perf-report[1]
> diff --git a/tools/perf/builtin-mem.c b/tools/perf/builtin-mem.c
> index bf0bfca5be20..5dad76e1c8df 100644
> --- a/tools/perf/builtin-mem.c
> +++ b/tools/perf/builtin-mem.c
> @@ -62,6 +62,7 @@ static int __cmd_record(int argc, const char **argv, struct perf_mem *mem)
>  	int rec_argc, i = 0, j;
>  	const char **rec_argv;
>  	int ret;
> +	bool all_user = false, all_kernel = false;
>  	struct option options[] = {
>  	OPT_CALLBACK('e', "event", &mem, "event",
>  		     "event selector. use 'perf mem record -e list' to list available events",
> @@ -69,13 +70,15 @@ static int __cmd_record(int argc, const char **argv, struct perf_mem *mem)
>  	OPT_UINTEGER(0, "ldlat", &perf_mem_events__loads_ldlat, "mem-loads latency"),
>  	OPT_INCR('v', "verbose", &verbose,
>  		 "be more verbose (show counter open errors, etc)"),
> +	OPT_BOOLEAN('U', "--all-user", &all_user, "collect only user level data"),
> +	OPT_BOOLEAN('K', "--all-kernel", &all_kernel, "collect only kernel level data"),
>  	OPT_END()
>  	};
>  
>  	argc = parse_options(argc, argv, options, record_mem_usage,
>  			     PARSE_OPT_STOP_AT_NON_OPTION);
>  
> -	rec_argc = argc + 7; /* max number of arguments */
> +	rec_argc = argc + 9; /* max number of arguments */
>  	rec_argv = calloc(rec_argc + 1, sizeof(char *));
>  	if (!rec_argv)
>  		return -1;
> @@ -104,6 +107,12 @@ static int __cmd_record(int argc, const char **argv, struct perf_mem *mem)
>  		rec_argv[i++] = perf_mem_events__name(j);
>  	};
>  
> +	if (all_user)
> +		rec_argv[i++] = "--all-user";
> +
> +	if (all_kernel)
> +		rec_argv[i++] = "--all-kernel";
> +
>  	for (j = 0; j < argc; j++, i++)
>  		rec_argv[i] = argv[j];
>  
> -- 
> 2.4.3

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH 0/6][perf/core] perf tools: Fixes
  2016-03-24 12:52 [PATCH 0/6][perf/core] perf tools: Fixes Jiri Olsa
                   ` (5 preceding siblings ...)
  2016-03-24 12:52 ` [PATCH 6/6] perf tests: Add test to check for event times Jiri Olsa
@ 2016-03-24 16:06 ` Arnaldo Carvalho de Melo
  6 siblings, 0 replies; 16+ messages in thread
From: Arnaldo Carvalho de Melo @ 2016-03-24 16:06 UTC (permalink / raw)
  To: Jiri Olsa
  Cc: lkml, David Ahern, Ingo Molnar, Namhyung Kim, Peter Zijlstra,
	Stephane Eranian, Andi Kleen

Em Thu, Mar 24, 2016 at 01:52:14PM +0100, Jiri Olsa escreveu:
> hi,
> sending assorted fixes and leftover from previous mem patchset.
> 
> Also available in here:
>   git://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
>   perf/fixes

Applied all, after adjustments, except for patch 1.

- Arnaldo
 
> thanks,
> jirka
> ---
> Jiri Olsa (6):
>       perf mem: Add --ldlat option
>       perf mem: Add -U/-K (--all-user/--all-kernel) options
>       perf tools: Make hists__collapse_insert_entry static
>       perf tools: Introduce trim function
>       perf tools: Unify -f/--force option documentation
>       perf tests: Add test to check for event times
> 
>  tools/perf/Documentation/perf-annotate.txt |   2 +-
>  tools/perf/Documentation/perf-diff.txt     |   2 +-
>  tools/perf/Documentation/perf-mem.txt      |  11 +++++
>  tools/perf/Documentation/perf-report.txt   |   2 +-
>  tools/perf/Documentation/perf-script.txt   |   4 ++
>  tools/perf/builtin-mem.c                   |  12 ++++-
>  tools/perf/tests/Build                     |   1 +
>  tools/perf/tests/builtin-test.c            |   4 ++
>  tools/perf/tests/event-times.c             | 236 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  tools/perf/tests/tests.h                   |   1 +
>  tools/perf/ui/browsers/hists.c             |   3 +-
>  tools/perf/ui/stdio/hist.c                 |   3 +-
>  tools/perf/util/hist.c                     |   5 +-
>  tools/perf/util/hist.h                     |   2 -
>  tools/perf/util/mem-events.c               |  17 ++++++-
>  tools/perf/util/mem-events.h               |   1 +
>  tools/perf/util/util.h                     |   5 ++
>  17 files changed, 298 insertions(+), 13 deletions(-)
>  create mode 100644 tools/perf/tests/event-times.c

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH 1/6] perf mem: Add --ldlat option
  2016-03-24 15:57   ` Arnaldo Carvalho de Melo
@ 2016-03-26 16:06     ` Jiri Olsa
  2016-04-07 13:58       ` Jiri Olsa
  0 siblings, 1 reply; 16+ messages in thread
From: Jiri Olsa @ 2016-03-26 16:06 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: Jiri Olsa, lkml, David Ahern, Ingo Molnar, Namhyung Kim,
	Peter Zijlstra, Stephane Eranian, Andi Kleen

On Thu, Mar 24, 2016 at 12:57:58PM -0300, Arnaldo Carvalho de Melo wrote:
> Em Thu, Mar 24, 2016 at 01:52:15PM +0100, Jiri Olsa escreveu:
> > Adding --ldlat option to specify desired latency
> > for loads event.
> > 
> > Specify 50 as loads event latency:
> > 
> >   $ perf mem record -e ldlat-loads -v --ldlat 50 true
> >   calling: record -W -d -e cpu/mem-loads,ldlat=50/P true
> 
> We have all this infrastructure to set per-event settings, on the
> command line, and here we end up adding a separate command line option
> to do that? Why not something like:
> 
> 	perf mem record -e ldlat-loads/lat=50/ true

will check ;-)

thanks,
jirka

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [tip:perf/core] perf mem: Add -U/-K (--all-user/--all-kernel) options
  2016-03-24 12:52 ` [PATCH 2/6] perf mem: Add -U/-K (--all-user/--all-kernel) options Jiri Olsa
  2016-03-24 15:58   ` Arnaldo Carvalho de Melo
@ 2016-03-31  6:51   ` tip-bot for Jiri Olsa
  1 sibling, 0 replies; 16+ messages in thread
From: tip-bot for Jiri Olsa @ 2016-03-31  6:51 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: mingo, ak, jolsa, a.p.zijlstra, linux-kernel, dsahern, namhyung,
	hpa, eranian, tglx, acme

Commit-ID:  ad16511b0e404652331a5350c522d0824f8209de
Gitweb:     http://git.kernel.org/tip/ad16511b0e404652331a5350c522d0824f8209de
Author:     Jiri Olsa <jolsa@kernel.org>
AuthorDate: Thu, 24 Mar 2016 13:52:16 +0100
Committer:  Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Wed, 30 Mar 2016 11:14:07 -0300

perf mem: Add -U/-K (--all-user/--all-kernel) options

Add -U/-K (--all-user/--all-kernel) options to use the perf record
--all-user/--all-kernel options.

Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/r/1458823940-24583-3-git-send-email-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
 tools/perf/Documentation/perf-mem.txt |  8 ++++++++
 tools/perf/builtin-mem.c              | 11 ++++++++++-
 2 files changed, 18 insertions(+), 1 deletion(-)

diff --git a/tools/perf/Documentation/perf-mem.txt b/tools/perf/Documentation/perf-mem.txt
index 43310d8..1d6092c 100644
--- a/tools/perf/Documentation/perf-mem.txt
+++ b/tools/perf/Documentation/perf-mem.txt
@@ -48,6 +48,14 @@ OPTIONS
 	option can be passed in record mode. It will be interpreted the same way as perf
 	record.
 
+-K::
+--all-kernel::
+	Configure all used events to run in kernel space.
+
+-U::
+--all-user::
+	Configure all used events to run in user space.
+
 SEE ALSO
 --------
 linkperf:perf-record[1], linkperf:perf-report[1]
diff --git a/tools/perf/builtin-mem.c b/tools/perf/builtin-mem.c
index 85db3be..1dc140c 100644
--- a/tools/perf/builtin-mem.c
+++ b/tools/perf/builtin-mem.c
@@ -62,19 +62,22 @@ static int __cmd_record(int argc, const char **argv, struct perf_mem *mem)
 	int rec_argc, i = 0, j;
 	const char **rec_argv;
 	int ret;
+	bool all_user = false, all_kernel = false;
 	struct option options[] = {
 	OPT_CALLBACK('e', "event", &mem, "event",
 		     "event selector. use 'perf mem record -e list' to list available events",
 		     parse_record_events),
 	OPT_INCR('v', "verbose", &verbose,
 		 "be more verbose (show counter open errors, etc)"),
+	OPT_BOOLEAN('U', "--all-user", &all_user, "collect only user level data"),
+	OPT_BOOLEAN('K', "--all-kernel", &all_kernel, "collect only kernel level data"),
 	OPT_END()
 	};
 
 	argc = parse_options(argc, argv, options, record_mem_usage,
 			     PARSE_OPT_STOP_AT_NON_OPTION);
 
-	rec_argc = argc + 7; /* max number of arguments */
+	rec_argc = argc + 9; /* max number of arguments */
 	rec_argv = calloc(rec_argc + 1, sizeof(char *));
 	if (!rec_argv)
 		return -1;
@@ -103,6 +106,12 @@ static int __cmd_record(int argc, const char **argv, struct perf_mem *mem)
 		rec_argv[i++] = perf_mem_events__name(j);
 	};
 
+	if (all_user)
+		rec_argv[i++] = "--all-user";
+
+	if (all_kernel)
+		rec_argv[i++] = "--all-kernel";
+
 	for (j = 0; j < argc; j++, i++)
 		rec_argv[i] = argv[j];
 

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [tip:perf/core] perf tools: Make hists__collapse_insert_entry static
  2016-03-24 12:52 ` [PATCH 3/6] perf tools: Make hists__collapse_insert_entry static Jiri Olsa
@ 2016-03-31  6:52   ` tip-bot for Jiri Olsa
  0 siblings, 0 replies; 16+ messages in thread
From: tip-bot for Jiri Olsa @ 2016-03-31  6:52 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: namhyung, eranian, hpa, mingo, tglx, dsahern, acme, jolsa, ak,
	linux-kernel, a.p.zijlstra

Commit-ID:  592dac6f35cf222a7687d4ff1ea7df0e6ef722e0
Gitweb:     http://git.kernel.org/tip/592dac6f35cf222a7687d4ff1ea7df0e6ef722e0
Author:     Jiri Olsa <jolsa@kernel.org>
AuthorDate: Thu, 24 Mar 2016 13:52:17 +0100
Committer:  Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Wed, 30 Mar 2016 11:14:07 -0300

perf tools: Make hists__collapse_insert_entry static

No need to export hists__collapse_insert_entry function.

Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/r/1458823940-24583-4-git-send-email-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
 tools/perf/util/hist.c | 5 +++--
 tools/perf/util/hist.h | 2 --
 2 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/tools/perf/util/hist.c b/tools/perf/util/hist.c
index 31c4641..3d34c57 100644
--- a/tools/perf/util/hist.c
+++ b/tools/perf/util/hist.c
@@ -1295,8 +1295,9 @@ static int hists__hierarchy_insert_entry(struct hists *hists,
 	return ret;
 }
 
-int hists__collapse_insert_entry(struct hists *hists, struct rb_root *root,
-				 struct hist_entry *he)
+static int hists__collapse_insert_entry(struct hists *hists,
+					struct rb_root *root,
+					struct hist_entry *he)
 {
 	struct rb_node **p = &root->rb_node;
 	struct rb_node *parent = NULL;
diff --git a/tools/perf/util/hist.h b/tools/perf/util/hist.h
index bec0cd6..5885965 100644
--- a/tools/perf/util/hist.h
+++ b/tools/perf/util/hist.h
@@ -199,8 +199,6 @@ int hists__init(void);
 int __hists__init(struct hists *hists, struct perf_hpp_list *hpp_list);
 
 struct rb_root *hists__get_rotate_entries_in(struct hists *hists);
-int hists__collapse_insert_entry(struct hists *hists,
-				  struct rb_root *root, struct hist_entry *he);
 
 struct perf_hpp {
 	char *buf;

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [tip:perf/core] perf tools: Make -f/--force option documentation consistent across tools
  2016-03-24 12:52 ` [PATCH 5/6] perf tools: Unify -f/--force option documentation Jiri Olsa
@ 2016-03-31  6:52   ` tip-bot for Jiri Olsa
  0 siblings, 0 replies; 16+ messages in thread
From: tip-bot for Jiri Olsa @ 2016-03-31  6:52 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: acme, namhyung, ak, mingo, tglx, dsahern, a.p.zijlstra,
	linux-kernel, jolsa, hpa, eranian

Commit-ID:  e0be62cc0325d65e1b7ae55d23e3d224638c20a6
Gitweb:     http://git.kernel.org/tip/e0be62cc0325d65e1b7ae55d23e3d224638c20a6
Author:     Jiri Olsa <jolsa@kernel.org>
AuthorDate: Thu, 24 Mar 2016 13:52:19 +0100
Committer:  Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Wed, 30 Mar 2016 11:14:08 -0300

perf tools: Make -f/--force option documentation consistent across tools

Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/r/1458823940-24583-6-git-send-email-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
 tools/perf/Documentation/perf-annotate.txt | 2 +-
 tools/perf/Documentation/perf-diff.txt     | 2 +-
 tools/perf/Documentation/perf-report.txt   | 2 +-
 tools/perf/Documentation/perf-script.txt   | 4 ++++
 4 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/tools/perf/Documentation/perf-annotate.txt b/tools/perf/Documentation/perf-annotate.txt
index e9cd39a..778f54d 100644
--- a/tools/perf/Documentation/perf-annotate.txt
+++ b/tools/perf/Documentation/perf-annotate.txt
@@ -33,7 +33,7 @@ OPTIONS
 
 -f::
 --force::
-        Don't complain, do it.
+        Don't do ownership validation.
 
 -v::
 --verbose::
diff --git a/tools/perf/Documentation/perf-diff.txt b/tools/perf/Documentation/perf-diff.txt
index d1deb57..3e9490b 100644
--- a/tools/perf/Documentation/perf-diff.txt
+++ b/tools/perf/Documentation/perf-diff.txt
@@ -75,7 +75,7 @@ OPTIONS
 
 -f::
 --force::
-       Don't complain, do it.
+        Don't do ownership validation.
 
 --symfs=<directory>::
         Look for files with symbols relative to this directory.
diff --git a/tools/perf/Documentation/perf-report.txt b/tools/perf/Documentation/perf-report.txt
index 1211399..496d42c 100644
--- a/tools/perf/Documentation/perf-report.txt
+++ b/tools/perf/Documentation/perf-report.txt
@@ -285,7 +285,7 @@ OPTIONS
 
 -f::
 --force::
-        Don't complain, do it.
+        Don't do ownership validation.
 
 --symfs=<directory>::
         Look for files with symbols relative to this directory.
diff --git a/tools/perf/Documentation/perf-script.txt b/tools/perf/Documentation/perf-script.txt
index 382ddfb..22ef393 100644
--- a/tools/perf/Documentation/perf-script.txt
+++ b/tools/perf/Documentation/perf-script.txt
@@ -262,6 +262,10 @@ include::itrace.txt[]
 --ns::
 	Use 9 decimal places when displaying time (i.e. show the nanoseconds)
 
+-f::
+--force::
+	Don't do ownership validation.
+
 SEE ALSO
 --------
 linkperf:perf-record[1], linkperf:perf-script-perl[1],

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [tip:perf/core] perf tests: Add test to check for event times
  2016-03-24 12:52 ` [PATCH 6/6] perf tests: Add test to check for event times Jiri Olsa
@ 2016-03-31  6:52   ` tip-bot for Jiri Olsa
  0 siblings, 0 replies; 16+ messages in thread
From: tip-bot for Jiri Olsa @ 2016-03-31  6:52 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: ak, dsahern, mingo, a.p.zijlstra, hpa, jolsa, linux-kernel,
	namhyung, tglx, acme, eranian

Commit-ID:  b31d660df37c1701fd18d526faeb9a86f0fc7dd2
Gitweb:     http://git.kernel.org/tip/b31d660df37c1701fd18d526faeb9a86f0fc7dd2
Author:     Jiri Olsa <jolsa@kernel.org>
AuthorDate: Thu, 24 Mar 2016 13:52:20 +0100
Committer:  Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Wed, 30 Mar 2016 11:14:08 -0300

perf tests: Add test to check for event times

This test creates software event 'cpu-clock' attaches it in several ways
and checks that enabled and running times match.

Committer notes:

Testing it:

  [acme@jouet linux]$ perf test -v times
  44: Test events times                                        :
  --- start ---
  test child forked, pid 27170
  attaching to spawned child, enable on exec
    OK    : ena 307328, run 307328
  attaching to current thread as enabled
    OK    : ena 7826, run 7826
  attaching to current thread as disabled
    OK    : ena 738, run 738
  attaching to CPU 0 as enabled
    SKIP  : not enough rights
  attaching to CPU 0 as enabled
    SKIP  : not enough rights
  test child finished with -2
  ---- end ----
  Test events times: Skip
  [acme@jouet linux]$

  [root@jouet ~]# perf test times
  44: Test events times                                        : Ok
  [root@jouet ~]# perf test -v times
  44: Test events times                                        :
  --- start ---
  test child forked, pid 27306
  attaching to spawned child, enable on exec
    OK    : ena 479290, run 479290
  attaching to current thread as enabled
    OK    : ena 11356, run 11356
  attaching to current thread as disabled
    OK    : ena 987, run 987
  attaching to CPU 0 as enabled
    OK    : ena 3717, run 3717
  attaching to CPU 0 as enabled
    OK    : ena 2323, run 2323
  test child finished with 0
  ---- end ----
  Test events times: Ok
  [root@jouet ~]#

Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/r/1458823940-24583-7-git-send-email-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
 tools/perf/tests/Build          |   1 +
 tools/perf/tests/builtin-test.c |   4 +
 tools/perf/tests/event-times.c  | 236 ++++++++++++++++++++++++++++++++++++++++
 tools/perf/tests/tests.h        |   1 +
 4 files changed, 242 insertions(+)

diff --git a/tools/perf/tests/Build b/tools/perf/tests/Build
index 1ba628e..449fe97 100644
--- a/tools/perf/tests/Build
+++ b/tools/perf/tests/Build
@@ -37,6 +37,7 @@ perf-y += topology.o
 perf-y += cpumap.o
 perf-y += stat.o
 perf-y += event_update.o
+perf-y += event-times.o
 
 $(OUTPUT)tests/llvm-src-base.c: tests/bpf-script-example.c tests/Build
 	$(call rule_mkdir)
diff --git a/tools/perf/tests/builtin-test.c b/tools/perf/tests/builtin-test.c
index f2b1dca..93c4670 100644
--- a/tools/perf/tests/builtin-test.c
+++ b/tools/perf/tests/builtin-test.c
@@ -204,6 +204,10 @@ static struct test generic_tests[] = {
 		.func = test__event_update,
 	},
 	{
+		.desc = "Test events times",
+		.func = test__event_times,
+	},
+	{
 		.func = NULL,
 	},
 };
diff --git a/tools/perf/tests/event-times.c b/tools/perf/tests/event-times.c
new file mode 100644
index 0000000..95fb744
--- /dev/null
+++ b/tools/perf/tests/event-times.c
@@ -0,0 +1,236 @@
+#include <linux/compiler.h>
+#include <string.h>
+#include "tests.h"
+#include "evlist.h"
+#include "evsel.h"
+#include "util.h"
+#include "debug.h"
+#include "thread_map.h"
+#include "target.h"
+
+static int attach__enable_on_exec(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+	struct target target = {
+		.uid = UINT_MAX,
+	};
+	const char *argv[] = { "true", NULL, };
+	char sbuf[STRERR_BUFSIZE];
+	int err;
+
+	pr_debug("attaching to spawned child, enable on exec\n");
+
+	err = perf_evlist__create_maps(evlist, &target);
+	if (err < 0) {
+		pr_debug("Not enough memory to create thread/cpu maps\n");
+		return err;
+	}
+
+	err = perf_evlist__prepare_workload(evlist, &target, argv, false, NULL);
+	if (err < 0) {
+		pr_debug("Couldn't run the workload!\n");
+		return err;
+	}
+
+	evsel->attr.enable_on_exec = 1;
+
+	err = perf_evlist__open(evlist);
+	if (err < 0) {
+		pr_debug("perf_evlist__open: %s\n",
+			 strerror_r(errno, sbuf, sizeof(sbuf)));
+		return err;
+	}
+
+	return perf_evlist__start_workload(evlist) == 1 ? TEST_OK : TEST_FAIL;
+}
+
+static int detach__enable_on_exec(struct perf_evlist *evlist)
+{
+	waitpid(evlist->workload.pid, NULL, 0);
+	return 0;
+}
+
+static int attach__current_disabled(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+	struct thread_map *threads;
+	int err;
+
+	pr_debug("attaching to current thread as disabled\n");
+
+	threads = thread_map__new(-1, getpid(), UINT_MAX);
+	if (threads == NULL) {
+		pr_debug("thread_map__new\n");
+		return -1;
+	}
+
+	evsel->attr.disabled = 1;
+
+	err = perf_evsel__open_per_thread(evsel, threads);
+	if (err) {
+		pr_debug("Failed to open event cpu-clock:u\n");
+		return err;
+	}
+
+	thread_map__put(threads);
+	return perf_evsel__enable(evsel) == 0 ? TEST_OK : TEST_FAIL;
+}
+
+static int attach__current_enabled(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+	struct thread_map *threads;
+	int err;
+
+	pr_debug("attaching to current thread as enabled\n");
+
+	threads = thread_map__new(-1, getpid(), UINT_MAX);
+	if (threads == NULL) {
+		pr_debug("failed to call thread_map__new\n");
+		return -1;
+	}
+
+	err = perf_evsel__open_per_thread(evsel, threads);
+
+	thread_map__put(threads);
+	return err == 0 ? TEST_OK : TEST_FAIL;
+}
+
+static int detach__disable(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+
+	return perf_evsel__enable(evsel);
+}
+
+static int attach__cpu_disabled(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+	struct cpu_map *cpus;
+	int err;
+
+	pr_debug("attaching to CPU 0 as enabled\n");
+
+	cpus = cpu_map__new("0");
+	if (cpus == NULL) {
+		pr_debug("failed to call cpu_map__new\n");
+		return -1;
+	}
+
+	evsel->attr.disabled = 1;
+
+	err = perf_evsel__open_per_cpu(evsel, cpus);
+	if (err) {
+		if (err == -EACCES)
+			return TEST_SKIP;
+
+		pr_debug("Failed to open event cpu-clock:u\n");
+		return err;
+	}
+
+	cpu_map__put(cpus);
+	return perf_evsel__enable(evsel);
+}
+
+static int attach__cpu_enabled(struct perf_evlist *evlist)
+{
+	struct perf_evsel *evsel = perf_evlist__last(evlist);
+	struct cpu_map *cpus;
+	int err;
+
+	pr_debug("attaching to CPU 0 as enabled\n");
+
+	cpus = cpu_map__new("0");
+	if (cpus == NULL) {
+		pr_debug("failed to call cpu_map__new\n");
+		return -1;
+	}
+
+	err = perf_evsel__open_per_cpu(evsel, cpus);
+	if (err == -EACCES)
+		return TEST_SKIP;
+
+	cpu_map__put(cpus);
+	return err ? TEST_FAIL : TEST_OK;
+}
+
+static int test_times(int (attach)(struct perf_evlist *),
+		      int (detach)(struct perf_evlist *))
+{
+	struct perf_counts_values count;
+	struct perf_evlist *evlist = NULL;
+	struct perf_evsel *evsel;
+	int err = -1, i;
+
+	evlist = perf_evlist__new();
+	if (!evlist) {
+		pr_debug("failed to create event list\n");
+		goto out_err;
+	}
+
+	err = parse_events(evlist, "cpu-clock:u", NULL);
+	if (err) {
+		pr_debug("failed to parse event cpu-clock:u\n");
+		goto out_err;
+	}
+
+	evsel = perf_evlist__last(evlist);
+	evsel->attr.read_format |=
+		PERF_FORMAT_TOTAL_TIME_ENABLED |
+		PERF_FORMAT_TOTAL_TIME_RUNNING;
+
+	err = attach(evlist);
+	if (err == TEST_SKIP) {
+		pr_debug("  SKIP  : not enough rights\n");
+		return err;
+	}
+
+	TEST_ASSERT_VAL("failed to attach", !err);
+
+	for (i = 0; i < 100000000; i++) { }
+
+	TEST_ASSERT_VAL("failed to detach", !detach(evlist));
+
+	perf_evsel__read(evsel, 0, 0, &count);
+
+	err = !(count.ena == count.run);
+
+	pr_debug("  %s: ena %" PRIu64", run %" PRIu64"\n",
+		 !err ? "OK    " : "FAILED",
+		 count.ena, count.run);
+
+out_err:
+	if (evlist)
+		perf_evlist__delete(evlist);
+	return !err ? TEST_OK : TEST_FAIL;
+}
+
+/*
+ * This test creates software event 'cpu-clock'
+ * attaches it in several ways (explained below)
+ * and checks that enabled and running times
+ * match.
+ */
+int test__event_times(int subtest __maybe_unused)
+{
+	int err, ret = 0;
+
+#define _T(attach, detach)			\
+	err = test_times(attach, detach);	\
+	if (err && (ret == TEST_OK || ret == TEST_SKIP))	\
+		ret = err;
+
+	/* attach on newly spawned process after exec */
+	_T(attach__enable_on_exec,   detach__enable_on_exec)
+	/* attach on current process as enabled */
+	_T(attach__current_enabled,  detach__disable)
+	/* attach on current process as disabled */
+	_T(attach__current_disabled, detach__disable)
+	/* attach on cpu as disabled */
+	_T(attach__cpu_disabled,     detach__disable)
+	/* attach on cpu as enabled */
+	_T(attach__cpu_enabled,      detach__disable)
+
+#undef _T
+	return ret;
+}
diff --git a/tools/perf/tests/tests.h b/tools/perf/tests/tests.h
index 82b2b5e..0fc9469 100644
--- a/tools/perf/tests/tests.h
+++ b/tools/perf/tests/tests.h
@@ -85,6 +85,7 @@ int test__synthesize_stat_config(int subtest);
 int test__synthesize_stat(int subtest);
 int test__synthesize_stat_round(int subtest);
 int test__event_update(int subtest);
+int test__event_times(int subtest);
 
 #if defined(__arm__) || defined(__aarch64__)
 #ifdef HAVE_DWARF_UNWIND_SUPPORT

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* Re: [PATCH 1/6] perf mem: Add --ldlat option
  2016-03-26 16:06     ` Jiri Olsa
@ 2016-04-07 13:58       ` Jiri Olsa
  0 siblings, 0 replies; 16+ messages in thread
From: Jiri Olsa @ 2016-04-07 13:58 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: Jiri Olsa, lkml, David Ahern, Ingo Molnar, Namhyung Kim,
	Peter Zijlstra, Stephane Eranian, Andi Kleen

On Sat, Mar 26, 2016 at 05:06:38PM +0100, Jiri Olsa wrote:
> On Thu, Mar 24, 2016 at 12:57:58PM -0300, Arnaldo Carvalho de Melo wrote:
> > Em Thu, Mar 24, 2016 at 01:52:15PM +0100, Jiri Olsa escreveu:
> > > Adding --ldlat option to specify desired latency
> > > for loads event.
> > > 
> > > Specify 50 as loads event latency:
> > > 
> > >   $ perf mem record -e ldlat-loads -v --ldlat 50 true
> > >   calling: record -W -d -e cpu/mem-loads,ldlat=50/P true
> > 
> > We have all this infrastructure to set per-event settings, on the
> > command line, and here we end up adding a separate command line option
> > to do that? Why not something like:
> > 
> > 	perf mem record -e ldlat-loads/lat=50/ true
> 
> will check ;-)

sry for delay..

the thing is, that we can already do that via record command:
  perf record -e "cpu/mem-loads,ldlat=30/" ls

but this option is in perf mem command, which provides
the way to use short config:
   $ perf mem record --ldlat 50 ls

and adds also '-W -d' options for record command:

  $ ./perf mem record -v --ldlat 50 ls 
  calling: record -W -d -e cpu/mem-loads,ldlat=50/P ls 

jirka

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2016-04-07 13:58 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-24 12:52 [PATCH 0/6][perf/core] perf tools: Fixes Jiri Olsa
2016-03-24 12:52 ` [PATCH 1/6] perf mem: Add --ldlat option Jiri Olsa
2016-03-24 15:57   ` Arnaldo Carvalho de Melo
2016-03-26 16:06     ` Jiri Olsa
2016-04-07 13:58       ` Jiri Olsa
2016-03-24 12:52 ` [PATCH 2/6] perf mem: Add -U/-K (--all-user/--all-kernel) options Jiri Olsa
2016-03-24 15:58   ` Arnaldo Carvalho de Melo
2016-03-31  6:51   ` [tip:perf/core] " tip-bot for Jiri Olsa
2016-03-24 12:52 ` [PATCH 3/6] perf tools: Make hists__collapse_insert_entry static Jiri Olsa
2016-03-31  6:52   ` [tip:perf/core] " tip-bot for Jiri Olsa
2016-03-24 12:52 ` [PATCH 4/6] perf tools: Introduce trim function Jiri Olsa
2016-03-24 12:52 ` [PATCH 5/6] perf tools: Unify -f/--force option documentation Jiri Olsa
2016-03-31  6:52   ` [tip:perf/core] perf tools: Make -f/--force option documentation consistent across tools tip-bot for Jiri Olsa
2016-03-24 12:52 ` [PATCH 6/6] perf tests: Add test to check for event times Jiri Olsa
2016-03-31  6:52   ` [tip:perf/core] " tip-bot for Jiri Olsa
2016-03-24 16:06 ` [PATCH 0/6][perf/core] perf tools: Fixes Arnaldo Carvalho de Melo

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.