All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] perf tools: Add sort__has_comm variable
@ 2016-03-09 14:20 Namhyung Kim
  2016-03-09 14:20 ` [PATCH 2/3] perf hists browser: Allow thread filtering for comm sort key Namhyung Kim
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Namhyung Kim @ 2016-03-09 14:20 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: Ingo Molnar, Peter Zijlstra, Jiri Olsa, LKML, David Ahern

The sort__has_comm variable is to check whether the comm sort key is
given.  This is necessary to support thread filtering in the TUI hists
browser later.

Signed-off-by: Namhyung Kim <namhyung@kernel.org>
---
 tools/perf/util/sort.c | 3 +++
 tools/perf/util/sort.h | 1 +
 2 files changed, 4 insertions(+)

diff --git a/tools/perf/util/sort.c b/tools/perf/util/sort.c
index 84c6654b4065..ca23b3ba0b2f 100644
--- a/tools/perf/util/sort.c
+++ b/tools/perf/util/sort.c
@@ -27,6 +27,7 @@ int		sort__has_sym = 0;
 int		sort__has_dso = 0;
 int		sort__has_socket = 0;
 int		sort__has_thread = 0;
+int		sort__has_comm = 0;
 enum sort_mode	sort__mode = SORT_MODE__NORMAL;
 
 /*
@@ -2255,6 +2256,8 @@ static int sort_dimension__add(const char *tok, struct perf_evlist *evlist,
 			sort__has_socket = 1;
 		} else if (sd->entry == &sort_thread) {
 			sort__has_thread = 1;
+		} else if (sd->entry == &sort_comm) {
+			sort__has_comm = 1;
 		}
 
 		return __sort_dimension__add(sd, level);
diff --git a/tools/perf/util/sort.h b/tools/perf/util/sort.h
index 151afc1b6c2f..3f4e35998119 100644
--- a/tools/perf/util/sort.h
+++ b/tools/perf/util/sort.h
@@ -37,6 +37,7 @@ extern int sort__has_parent;
 extern int sort__has_sym;
 extern int sort__has_socket;
 extern int sort__has_thread;
+extern int sort__has_comm;
 extern enum sort_mode sort__mode;
 extern struct sort_entry sort_comm;
 extern struct sort_entry sort_dso;
-- 
2.7.2

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

end of thread, other threads:[~2016-03-11  8:53 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-09 14:20 [PATCH 1/3] perf tools: Add sort__has_comm variable Namhyung Kim
2016-03-09 14:20 ` [PATCH 2/3] perf hists browser: Allow thread filtering for comm sort key Namhyung Kim
2016-03-09 14:26   ` Arnaldo Carvalho de Melo
2016-03-09 15:14     ` [PATCH v2 " Namhyung Kim
2016-03-11  8:51       ` [tip:perf/core] " tip-bot for Namhyung Kim
2016-03-09 14:20 ` [PATCH 3/3] perf hists browser: Check sort keys before hot key actions Namhyung Kim
2016-03-11  8:51   ` [tip:perf/core] " tip-bot for Namhyung Kim
2016-03-11  8:50 ` [tip:perf/core] perf tools: Add sort__has_comm variable tip-bot for Namhyung Kim

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.