* [GIT PULL 00/31] perf/core improvements and fixes
@ 2015-03-19 17:04 Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 01/31] perf hists browser: Simplify symbol annotation menu setup Arnaldo Carvalho de Melo
` (30 more replies)
0 siblings, 31 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Borislav Petkov, Corey Ashford, David Ahern, Don Zickus,
Frederic Weisbecker, H . J . Lu, Jiri Olsa, Li Zefan,
Namhyung Kim, Paul Mackerras, Peter Zijlstra, pi3orama,
Stephane Eranian, Wang Nan, Yunlong Song,
Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling, more to come,
- Arnaldo
The following changes since commit 107eb964d8c04417e8bce9e9ec2ed61d9261aec6:
Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2015-03-13 13:30:10 +0100)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-core-for-mingo
for you to fetch changes up to 0c8c20779c5d56b93b8cb4cd30ba129a927ab437:
perf report: Don't allow empty argument for '-t'. (2015-03-19 13:53:28 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
User visible:
- Bash completion for subcommands (Yunlong Song)
- Allow annotating entries in callchains in the hists browser (top/report).
TODO: give some visual cue to what entries in callchains have samples and thus
can be annotated and/or allow showing the source code for functions without
samples (Arnaldo Carvalho de Melo)
- Don't allow empty argument for '-t' in perf report, fixing segfault (Wang Nan)
Infrastructure:
- Prep work for moving the perf feature tests build system to tools/build (Jiri Olsa)
- Fix perf-read-vdsox32 not building and lib64 install dir (H.J. Lu)
- ARM64: fix building error and eh/debug frame offset cache fixes (Wang Nan)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Arnaldo Carvalho de Melo (4):
perf hists browser: Simplify symbol annotation menu setup
perf hists browser: Fix up some branch alignment
perf hists: Remove hist_entry->used, not used anymore
perf hists browser: Allow annotating entries in callchains
H.J. Lu (1):
perf tools: Fix perf-read-vdsox32 not building and lib64 install dir
Jiri Olsa (10):
perf build: Disable default check for libbabeltrace
perf build: Move features build output under features directory
perf build: Fix pthread-attr-setaffinity-np include in test-all
perf build: Get rid of LIB_INCLUDE variable
perf build: Rename CORE_FEATURE_TESTS to FEATURE_TESTS
perf build: Get rid of VF_FEATURE_TESTS
perf build: Rename display_lib into feature_display
perf build: Rename display_vf to feature_verbose
perf build: Rename PERF-FEATURES into FEATURE-DUMP
perf build: Rename feature_print_var_code to print_var_code
Wang Nan (3):
perf tools: Fix building error for arm64.
perf callchain: Separate eh/debug frame offset cache.
perf report: Don't allow empty argument for '-t'.
Yunlong Song (13):
perf tools: Fix the bash completion for listing options of perf subcommand
perf tools: Fix the bash completion for listing subsubcommands of perf subcommand
perf tools: Provide the right bash completion for listing options of perf subcommand subsubcommand
perf tools: Fix the bash completion for listing events of perf subcommand record|stat|top -e
perf tools: Fix the bash completion to support listing events for --event
perf tools: Fix the bash completion for listing subcommands of perf
perf tools: Add the bash completion for listing subsubcommands of perf data
perf tools: Add the bash completion for listing subsubcommands of perf help
perf tools: Add the bash completion for listing subsubcommands of perf script
perf tools: Add the bash completion for listing subsubcommands of perf test
perf tools: Add the bash completion for listing subsubcommands of perf timechart
perf tools: Add the bash completion for listing subsubcommands of perf trace
perf tools: Avoid confusion with preloaded bash function for perf bash completion
tools/perf/Makefile.perf | 3 +-
tools/perf/builtin-data.c | 6 +-
tools/perf/builtin-help.c | 17 ++++-
tools/perf/builtin-report.c | 2 +-
tools/perf/builtin-script.c | 5 +-
tools/perf/builtin-timechart.c | 7 +-
tools/perf/builtin-trace.c | 7 +-
tools/perf/config/Makefile | 111 ++++++++++++----------------
tools/perf/config/Makefile.arch | 2 +-
tools/perf/config/feature-checks/Makefile | 7 +-
tools/perf/config/feature-checks/test-all.c | 11 ++-
tools/perf/perf-completion.sh | 88 +++++++++++++++++-----
tools/perf/tests/builtin-test.c | 5 +-
tools/perf/tests/make | 2 +-
tools/perf/ui/browsers/annotate.c | 8 +-
tools/perf/ui/browsers/hists.c | 59 +++++++--------
tools/perf/util/dso.h | 3 +-
tools/perf/util/hist.c | 8 +-
tools/perf/util/hist.h | 9 +++
tools/perf/util/parse-options.c | 21 +++++-
tools/perf/util/parse-options.h | 2 +
tools/perf/util/sort.h | 1 -
tools/perf/util/unwind-libunwind.c | 8 +-
23 files changed, 237 insertions(+), 155 deletions(-)
^ permalink raw reply [flat|nested] 42+ messages in thread
* [PATCH 01/31] perf hists browser: Simplify symbol annotation menu setup
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 02/31] perf hists browser: Fix up some branch alignment Arnaldo Carvalho de Melo
` (29 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Borislav Petkov, David Ahern, Don Zickus, Frederic Weisbecker,
Jiri Olsa, Namhyung Kim, Stephane Eranian
From: Arnaldo Carvalho de Melo <acme@redhat.com>
No need to repeat some tests, skip annotation instead.
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: David Ahern <dsahern@gmail.com>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-6h6igrb81u4e6rwfmx7dv47n@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/ui/browsers/hists.c | 20 +++++++++++---------
1 file changed, 11 insertions(+), 9 deletions(-)
diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
index 49eddeb81458..f69371b7f49b 100644
--- a/tools/perf/ui/browsers/hists.c
+++ b/tools/perf/ui/browsers/hists.c
@@ -1612,19 +1612,22 @@ static int perf_evsel__hists_browse(struct perf_evsel *evsel, int nr_events,
if (!sort__has_sym)
goto add_exit_option;
+ if (browser->selection == NULL)
+ goto skip_annotation;
+
if (sort__mode == SORT_MODE__BRANCH) {
bi = browser->he_selection->branch_info;
- if (browser->selection != NULL &&
- bi &&
- bi->from.sym != NULL &&
+
+ if (bi == NULL)
+ goto skip_annotation;
+
+ if (bi->from.sym != NULL &&
!bi->from.map->dso->annotate_warned &&
asprintf(&options[nr_options], "Annotate %s",
bi->from.sym->name) > 0)
annotate_f = nr_options++;
- if (browser->selection != NULL &&
- bi &&
- bi->to.sym != NULL &&
+ if (bi->to.sym != NULL &&
!bi->to.map->dso->annotate_warned &&
(bi->to.sym != bi->from.sym ||
bi->to.map->dso != bi->from.map->dso) &&
@@ -1632,8 +1635,7 @@ static int perf_evsel__hists_browse(struct perf_evsel *evsel, int nr_events,
bi->to.sym->name) > 0)
annotate_t = nr_options++;
} else {
- if (browser->selection != NULL &&
- browser->selection->sym != NULL &&
+ if (browser->selection->sym != NULL &&
!browser->selection->map->dso->annotate_warned) {
struct annotation *notes;
@@ -1645,7 +1647,7 @@ static int perf_evsel__hists_browse(struct perf_evsel *evsel, int nr_events,
annotate = nr_options++;
}
}
-
+skip_annotation:
if (thread != NULL &&
asprintf(&options[nr_options], "Zoom %s %s(%d) thread",
(browser->hists->thread_filter ? "out of" : "into"),
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 02/31] perf hists browser: Fix up some branch alignment
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 01/31] perf hists browser: Simplify symbol annotation menu setup Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 03/31] perf hists: Remove hist_entry->used, not used anymore Arnaldo Carvalho de Melo
` (28 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Borislav Petkov, David Ahern, Don Zickus, Frederic Weisbecker,
Jiri Olsa, Namhyung Kim, Stephane Eranian
From: Arnaldo Carvalho de Melo <acme@redhat.com>
Those asprintf return checks should be aligned with the other
conditionals, fix it.
Also add {} blocks to further clarify.
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: David Ahern <dsahern@gmail.com>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Stephane Eranian <eranian@google.com>
echo Link: http://lkml.kernel.org/n/tip-`ranpwd -l 24`@git.kernel.org
Link: http://lkml.kernel.org/n/tip-nqgs07jfphbkw67wja870d3r@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/ui/browsers/hists.c | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
index f69371b7f49b..ebd9d3afe2d6 100644
--- a/tools/perf/ui/browsers/hists.c
+++ b/tools/perf/ui/browsers/hists.c
@@ -1623,17 +1623,17 @@ static int perf_evsel__hists_browse(struct perf_evsel *evsel, int nr_events,
if (bi->from.sym != NULL &&
!bi->from.map->dso->annotate_warned &&
- asprintf(&options[nr_options], "Annotate %s",
- bi->from.sym->name) > 0)
+ asprintf(&options[nr_options], "Annotate %s", bi->from.sym->name) > 0) {
annotate_f = nr_options++;
+ }
if (bi->to.sym != NULL &&
!bi->to.map->dso->annotate_warned &&
(bi->to.sym != bi->from.sym ||
bi->to.map->dso != bi->from.map->dso) &&
- asprintf(&options[nr_options], "Annotate %s",
- bi->to.sym->name) > 0)
+ asprintf(&options[nr_options], "Annotate %s", bi->to.sym->name) > 0) {
annotate_t = nr_options++;
+ }
} else {
if (browser->selection->sym != NULL &&
!browser->selection->map->dso->annotate_warned) {
@@ -1643,8 +1643,9 @@ static int perf_evsel__hists_browse(struct perf_evsel *evsel, int nr_events,
if (notes->src &&
asprintf(&options[nr_options], "Annotate %s",
- browser->selection->sym->name) > 0)
+ browser->selection->sym->name) > 0) {
annotate = nr_options++;
+ }
}
}
skip_annotation:
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 03/31] perf hists: Remove hist_entry->used, not used anymore
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 01/31] perf hists browser: Simplify symbol annotation menu setup Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 02/31] perf hists browser: Fix up some branch alignment Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 04/31] perf hists browser: Allow annotating entries in callchains Arnaldo Carvalho de Melo
` (27 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Borislav Petkov, David Ahern, Don Zickus, Frederic Weisbecker,
Jiri Olsa, Namhyung Kim, Stephane Eranian
From: Arnaldo Carvalho de Melo <acme@redhat.com>
Since hist_entry__delete() nowadays doesn't actually frees anything that
may be in use by the annotation code.
Eventually we will solve this for good by reference counting struct
symbol.
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: David Ahern <dsahern@gmail.com>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-uldtgljymtrkns0knpiso5op@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/ui/browsers/hists.c | 5 -----
tools/perf/util/hist.c | 8 +-------
tools/perf/util/sort.h | 1 -
3 files changed, 1 insertion(+), 13 deletions(-)
diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
index ebd9d3afe2d6..c37e70ae0b20 100644
--- a/tools/perf/ui/browsers/hists.c
+++ b/tools/perf/ui/browsers/hists.c
@@ -1731,12 +1731,7 @@ do_annotate:
if (!notes->src)
continue;
- /*
- * Don't let this be freed, say, by hists__decay_entry.
- */
- he->used = true;
err = hist_entry__tui_annotate(he, evsel, hbt);
- he->used = false;
/*
* offer option to annotate the other branch source or target
* (if they exists) when returning from annotate
diff --git a/tools/perf/util/hist.c b/tools/perf/util/hist.c
index d9a6d35eda17..cc22b9158b93 100644
--- a/tools/perf/util/hist.c
+++ b/tools/perf/util/hist.c
@@ -263,15 +263,9 @@ void hists__decay_entries(struct hists *hists, bool zap_user, bool zap_kernel)
while (next) {
n = rb_entry(next, struct hist_entry, rb_node);
next = rb_next(&n->rb_node);
- /*
- * We may be annotating this, for instance, so keep it here in
- * case some it gets new samples, we'll eventually free it when
- * the user stops browsing and it agains gets fully decayed.
- */
if (((zap_user && n->level == '.') ||
(zap_kernel && n->level != '.') ||
- hists__decay_entry(hists, n)) &&
- !n->used) {
+ hists__decay_entry(hists, n))) {
hists__delete_entry(hists, n);
}
}
diff --git a/tools/perf/util/sort.h b/tools/perf/util/sort.h
index c03e4ff8beff..9c01b83eebca 100644
--- a/tools/perf/util/sort.h
+++ b/tools/perf/util/sort.h
@@ -102,7 +102,6 @@ struct hist_entry {
bool init_have_children;
char level;
- bool used;
u8 filtered;
char *srcline;
struct symbol *parent;
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 04/31] perf hists browser: Allow annotating entries in callchains
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (2 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 03/31] perf hists: Remove hist_entry->used, not used anymore Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 05/31] perf tools: Fix building error for arm64 Arnaldo Carvalho de Melo
` (26 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Borislav Petkov, David Ahern, Don Zickus, Frederic Weisbecker,
Jiri Olsa, Namhyung Kim
From: Arnaldo Carvalho de Melo <acme@redhat.com>
Instead of annotating just the top level hist_entry, allow instead
annotating a map_symbol, i.e. the top level hist_entry or one of the
callchains for which there were samples.
Suggested-by: Stephane Eranian <eranian@google.com>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: David Ahern <dsahern@gmail.com>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Link: http://lkml.kernel.org/n/tip-k1zxj5564je9jei4yd15ouwn@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/ui/browsers/annotate.c | 8 +++++++-
tools/perf/ui/browsers/hists.c | 23 ++++++++++-------------
tools/perf/util/hist.h | 9 +++++++++
3 files changed, 26 insertions(+), 14 deletions(-)
diff --git a/tools/perf/ui/browsers/annotate.c b/tools/perf/ui/browsers/annotate.c
index 9d32e3c0cfee..e5250eb2dd57 100644
--- a/tools/perf/ui/browsers/annotate.c
+++ b/tools/perf/ui/browsers/annotate.c
@@ -829,10 +829,16 @@ out:
return key;
}
+int map_symbol__tui_annotate(struct map_symbol *ms, struct perf_evsel *evsel,
+ struct hist_browser_timer *hbt)
+{
+ return symbol__tui_annotate(ms->sym, ms->map, evsel, hbt);
+}
+
int hist_entry__tui_annotate(struct hist_entry *he, struct perf_evsel *evsel,
struct hist_browser_timer *hbt)
{
- return symbol__tui_annotate(he->ms.sym, he->ms.map, evsel, hbt);
+ return map_symbol__tui_annotate(&he->ms, evsel, hbt);
}
static void annotate_browser__mark_jump_targets(struct annotate_browser *browser,
diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
index c37e70ae0b20..cd7350aeb8e7 100644
--- a/tools/perf/ui/browsers/hists.c
+++ b/tools/perf/ui/browsers/hists.c
@@ -1704,6 +1704,7 @@ retry_popup_menu:
if (choice == annotate || choice == annotate_t || choice == annotate_f) {
struct hist_entry *he;
struct annotation *notes;
+ struct map_symbol ms;
int err;
do_annotate:
if (!objdump_path && perf_session_env__lookup_objdump(env))
@@ -1713,25 +1714,21 @@ do_annotate:
if (he == NULL)
continue;
- /*
- * we stash the branch_info symbol + map into the
- * the ms so we don't have to rewrite all the annotation
- * code to use branch_info.
- * in branch mode, the ms struct is not used
- */
if (choice == annotate_f) {
- he->ms.sym = he->branch_info->from.sym;
- he->ms.map = he->branch_info->from.map;
- } else if (choice == annotate_t) {
- he->ms.sym = he->branch_info->to.sym;
- he->ms.map = he->branch_info->to.map;
+ ms.map = he->branch_info->from.map;
+ ms.sym = he->branch_info->from.sym;
+ } else if (choice == annotate_t) {
+ ms.map = he->branch_info->to.map;
+ ms.sym = he->branch_info->to.sym;
+ } else {
+ ms = *browser->selection;
}
- notes = symbol__annotation(he->ms.sym);
+ notes = symbol__annotation(ms.sym);
if (!notes->src)
continue;
- err = hist_entry__tui_annotate(he, evsel, hbt);
+ err = map_symbol__tui_annotate(&ms, evsel, hbt);
/*
* offer option to annotate the other branch source or target
* (if they exists) when returning from annotate
diff --git a/tools/perf/util/hist.h b/tools/perf/util/hist.h
index e988c9fcd1bc..9f31b89a527a 100644
--- a/tools/perf/util/hist.h
+++ b/tools/perf/util/hist.h
@@ -303,6 +303,9 @@ struct hist_browser_timer {
#ifdef HAVE_SLANG_SUPPORT
#include "../ui/keysyms.h"
+int map_symbol__tui_annotate(struct map_symbol *ms, struct perf_evsel *evsel,
+ struct hist_browser_timer *hbt);
+
int hist_entry__tui_annotate(struct hist_entry *he, struct perf_evsel *evsel,
struct hist_browser_timer *hbt);
@@ -321,6 +324,12 @@ int perf_evlist__tui_browse_hists(struct perf_evlist *evlist __maybe_unused,
{
return 0;
}
+static inline int map_symbol__tui_annotate(struct map_symbol *ms __maybe_unused,
+ struct perf_evsel *evsel __maybe_unused,
+ struct hist_browser_timer *hbt __maybe_unused)
+{
+ return 0;
+}
static inline int hist_entry__tui_annotate(struct hist_entry *he __maybe_unused,
struct perf_evsel *evsel __maybe_unused,
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 05/31] perf tools: Fix building error for arm64.
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (3 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 04/31] perf hists browser: Allow annotating entries in callchains Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 06/31] perf build: Disable default check for libbabeltrace Arnaldo Carvalho de Melo
` (25 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Wang Nan, Jiri Olsa, Zefan Li, Arnaldo Carvalho de Melo
From: Wang Nan <wangnan0@huawei.com>
Commit b11db6581beaccef8ae9a388ae96074aa5cc144f ("perf tools: Fix build
error on ARCH=i386/x86_64/sparc64") uses sed on ARCH, which triggers a
bug in sequence of sed expression, where 's/arm.*/arm/' will replace
'arm64' to 'arm', causes arm64 building failure.
This patch prevent 'arm64' to be mached for 'arm.*' case.
Signed-off-by: Wang Nan <wangnan0@huawei.com>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Zefan Li <lizefan@huawei.com>
Link: http://lkml.kernel.org/r/1426598987-75245-1-git-send-email-wangnan0@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/config/Makefile.arch | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/perf/config/Makefile.arch b/tools/perf/config/Makefile.arch
index e9720571341d..e11fbd6fae78 100644
--- a/tools/perf/config/Makefile.arch
+++ b/tools/perf/config/Makefile.arch
@@ -4,7 +4,7 @@ endif
ARCH := $(shell echo $(ARCH) | sed -e s/i.86/x86/ -e s/x86_64/x86/ \
-e s/sun4u/sparc/ -e s/sparc64/sparc/ \
- -e s/arm.*/arm/ -e s/sa110/arm/ \
+ -e /arm64/!s/arm.*/arm/ -e s/sa110/arm/ \
-e s/s390x/s390/ -e s/parisc64/parisc/ \
-e s/ppc.*/powerpc/ -e s/mips.*/mips/ \
-e s/sh[234].*/sh/ -e s/aarch64.*/arm64/ \
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 06/31] perf build: Disable default check for libbabeltrace
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (4 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 05/31] perf tools: Fix building error for arm64 Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 07/31] perf build: Move features build output under features directory Arnaldo Carvalho de Melo
` (24 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
Remove libbabeltrace check from default features set, because the
requested version is not released yet in most distributions. We'll
enable later.
Calling libbabeltrace check manually via feature_check before
$(feature-libbabeltrace) is used.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Acked-by: Ingo Molnar <mingo@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <david.ahern@oracle.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-5n7mr6ugcwdbxk0n1z8uukaa@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/config/Makefile | 11 +++++------
tools/perf/config/feature-checks/Makefile | 2 +-
tools/perf/config/feature-checks/test-all.c | 9 ++++++++-
3 files changed, 14 insertions(+), 8 deletions(-)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index bd097187724b..b799649ab0e7 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -227,7 +227,6 @@ CORE_FEATURE_TESTS = \
stackprotector-all \
timerfd \
libdw-dwarf-unwind \
- libbabeltrace \
zlib
LIB_FEATURE_TESTS = \
@@ -243,7 +242,6 @@ LIB_FEATURE_TESTS = \
libslang \
libunwind \
libdw-dwarf-unwind \
- libbabeltrace \
zlib
VF_FEATURE_TESTS = \
@@ -705,14 +703,15 @@ else
endif
ifndef NO_LIBBABELTRACE
- ifeq ($(feature-libbabeltrace), 0)
- msg := $(warning No libbabeltrace found, disables 'perf data' CTF format support, please install libbabeltrace-dev[el]/libbabeltrace-ctf-dev);
- NO_LIBBABELTRACE := 1
- else
+ $(call feature_check,libbabeltrace)
+ ifeq ($(feature-libbabeltrace), 1)
CFLAGS += -DHAVE_LIBBABELTRACE_SUPPORT $(LIBBABELTRACE_CFLAGS)
LDFLAGS += $(LIBBABELTRACE_LDFLAGS)
EXTLIBS += -lbabeltrace-ctf
$(call detected,CONFIG_LIBBABELTRACE)
+ else
+ msg := $(warning No libbabeltrace found, disables 'perf data' CTF format support, please install libbabeltrace-dev[el]/libbabeltrace-ctf-dev);
+ NO_LIBBABELTRACE := 1
endif
endif
diff --git a/tools/perf/config/feature-checks/Makefile b/tools/perf/config/feature-checks/Makefile
index 8fe067864957..b6e2e312ba54 100644
--- a/tools/perf/config/feature-checks/Makefile
+++ b/tools/perf/config/feature-checks/Makefile
@@ -44,7 +44,7 @@ BUILD = $(CC) $(CFLAGS) -Wall -Werror -o $(OUTPUT)$@ $(patsubst %.bin,%.c,$@) $(
###############################
test-all.bin:
- $(BUILD) -fstack-protector-all -O2 -D_FORTIFY_SOURCE=2 -ldw -lelf -lnuma -lelf -laudit -I/usr/include/slang -lslang $(shell $(PKG_CONFIG) --libs --cflags gtk+-2.0 2>/dev/null) $(FLAGS_PERL_EMBED) $(FLAGS_PYTHON_EMBED) -DPACKAGE='"perf"' -lbfd -ldl -lz -lbabeltrace
+ $(BUILD) -fstack-protector-all -O2 -D_FORTIFY_SOURCE=2 -ldw -lelf -lnuma -lelf -laudit -I/usr/include/slang -lslang $(shell $(PKG_CONFIG) --libs --cflags gtk+-2.0 2>/dev/null) $(FLAGS_PERL_EMBED) $(FLAGS_PYTHON_EMBED) -DPACKAGE='"perf"' -lbfd -ldl -lz
test-hello.bin:
$(BUILD)
diff --git a/tools/perf/config/feature-checks/test-all.c b/tools/perf/config/feature-checks/test-all.c
index 1ffc3da5ca10..06f5c8a67cb2 100644
--- a/tools/perf/config/feature-checks/test-all.c
+++ b/tools/perf/config/feature-checks/test-all.c
@@ -101,9 +101,17 @@
# include "test-pthread_attr_setaffinity_np.c"
#undef main
+# if 0
+/*
+ * Disable libbabeltrace check for test-all, because the requested
+ * library version is not released yet in most distributions. Will
+ * reenable later.
+ */
+
#define main main_test_libbabeltrace
# include "test-libbabeltrace.c"
#undef main
+#endif
int main(int argc, char *argv[])
{
@@ -130,7 +138,6 @@ int main(int argc, char *argv[])
main_test_sync_compare_and_swap(argc, argv);
main_test_zlib();
main_test_pthread_attr_setaffinity_np();
- main_test_libbabeltrace();
return 0;
}
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 07/31] perf build: Move features build output under features directory
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (5 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 06/31] perf build: Disable default check for libbabeltrace Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 08/31] perf build: Fix pthread-attr-setaffinity-np include in test-all Arnaldo Carvalho de Melo
` (23 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
Following commit introduced features build dump:
443a70541c56 perf tools: Output feature detection's gcc output to a file
Moving them into to have code more compact and renaming build dump
files. For each feature 'test-X' new file 'test-X.make.output' is
created and contains the build out. It's created in the same directory
as the feature itself.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <david.ahern@oracle.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-dk6svnhcephrzgz4mfpcmtm7@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/Makefile.perf | 1 -
tools/perf/config/Makefile | 2 +-
tools/perf/config/feature-checks/Makefile | 5 +++--
3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/tools/perf/Makefile.perf b/tools/perf/Makefile.perf
index 933d70345f87..ec4c063ed9f3 100644
--- a/tools/perf/Makefile.perf
+++ b/tools/perf/Makefile.perf
@@ -529,7 +529,6 @@ clean: $(LIBTRACEEVENT)-clean $(LIBAPI)-clean config-clean
$(Q)$(RM) .config-detected
$(call QUIET_CLEAN, core-progs) $(RM) $(ALL_PROGRAMS) perf perf-read-vdso32 perf-read-vdsox32
$(call QUIET_CLEAN, core-gen) $(RM) *.spec *.pyc *.pyo */*.pyc */*.pyo $(OUTPUT)common-cmds.h TAGS tags cscope* $(OUTPUT)PERF-VERSION-FILE $(OUTPUT)PERF-FEATURES $(OUTPUT)util/*-bison* $(OUTPUT)util/*-flex*
- $(call QUIET_CLEAN, feature-detect) $(RM) $(OUTPUT)config/feature-checks/.make-*.output
$(QUIET_SUBDIR0)Documentation $(QUIET_SUBDIR1) clean
$(python-clean)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index b799649ab0e7..45f61253ccce 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -184,7 +184,7 @@ endif
feature_check = $(eval $(feature_check_code))
define feature_check_code
- feature-$(1) := $(shell $(MAKE) OUTPUT=$(OUTPUT_FEATURES) CFLAGS="$(EXTRA_CFLAGS) $(FEATURE_CHECK_CFLAGS-$(1))" LDFLAGS="$(LDFLAGS) $(FEATURE_CHECK_LDFLAGS-$(1))" -C config/feature-checks test-$1.bin > $(OUTPUT)config/feature-checks/.make-$(1).output 2>&1 && echo 1 || echo 0)
+ feature-$(1) := $(shell $(MAKE) OUTPUT=$(OUTPUT_FEATURES) CFLAGS="$(EXTRA_CFLAGS) $(FEATURE_CHECK_CFLAGS-$(1))" LDFLAGS="$(LDFLAGS) $(FEATURE_CHECK_LDFLAGS-$(1))" -C config/feature-checks test-$1.bin >/dev/null 2>/dev/null && echo 1 || echo 0)
endef
feature_set = $(eval $(feature_set_code))
diff --git a/tools/perf/config/feature-checks/Makefile b/tools/perf/config/feature-checks/Makefile
index b6e2e312ba54..0d694a94cda2 100644
--- a/tools/perf/config/feature-checks/Makefile
+++ b/tools/perf/config/feature-checks/Makefile
@@ -39,7 +39,8 @@ PKG_CONFIG := $(CROSS_COMPILE)pkg-config
all: $(FILES)
-BUILD = $(CC) $(CFLAGS) -Wall -Werror -o $(OUTPUT)$@ $(patsubst %.bin,%.c,$@) $(LDFLAGS)
+__BUILD = $(CC) $(CFLAGS) -Wall -Werror -o $(OUTPUT)$@ $(patsubst %.bin,%.c,$@) $(LDFLAGS)
+ BUILD = $(__BUILD) > $(OUTPUT)$(@:.bin=.make.output) 2>&1
###############################
@@ -156,4 +157,4 @@ test-zlib.bin:
###############################
clean:
- rm -f $(FILES) *.d
+ rm -f $(FILES) *.d $(FILES:.bin=.make.output)
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 08/31] perf build: Fix pthread-attr-setaffinity-np include in test-all
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (6 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 07/31] perf build: Move features build output under features directory Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 09/31] perf build: Get rid of LIB_INCLUDE variable Arnaldo Carvalho de Melo
` (22 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
The test-all fails to build due to type in pthread-attr-setaffinity-np
include.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <david.ahern@oracle.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-awn2658267slejnebyrlns86@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/config/feature-checks/test-all.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/perf/config/feature-checks/test-all.c b/tools/perf/config/feature-checks/test-all.c
index 06f5c8a67cb2..a61c20456705 100644
--- a/tools/perf/config/feature-checks/test-all.c
+++ b/tools/perf/config/feature-checks/test-all.c
@@ -98,7 +98,7 @@
#undef main
#define main main_test_pthread_attr_setaffinity_np
-# include "test-pthread_attr_setaffinity_np.c"
+# include "test-pthread-attr-setaffinity-np.c"
#undef main
# if 0
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 09/31] perf build: Get rid of LIB_INCLUDE variable
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (7 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 08/31] perf build: Fix pthread-attr-setaffinity-np include in test-all Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 10/31] perf build: Rename CORE_FEATURE_TESTS to FEATURE_TESTS Arnaldo Carvalho de Melo
` (21 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
It has no use, so we can directly use the value for CFLAGS.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <david.ahern@oracle.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-ywyr5v962s32daq5hpgfkjap@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/config/Makefile | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index 45f61253ccce..467106bc5fab 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -15,7 +15,6 @@ $(shell echo -n > .config-detected)
detected = $(shell echo "$(1)=y" >> .config-detected)
detected_var = $(shell echo "$(1)=$($(1))" >> .config-detected)
-LIB_INCLUDE := $(srctree)/tools/lib/
CFLAGS := $(EXTRA_CFLAGS) $(EXTRA_WARNINGS)
include $(src-perf)/config/Makefile.arch
@@ -320,7 +319,7 @@ endif
CFLAGS += -I$(src-perf)/util
CFLAGS += -I$(src-perf)
-CFLAGS += -I$(LIB_INCLUDE)
+CFLAGS += -I$(srctree)/tools/lib/
CFLAGS += -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 10/31] perf build: Rename CORE_FEATURE_TESTS to FEATURE_TESTS
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (8 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 09/31] perf build: Get rid of LIB_INCLUDE variable Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 11/31] perf build: Get rid of VF_FEATURE_TESTS Arnaldo Carvalho de Melo
` (20 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
Preparing for feature checks separation, moving related stuff under
'FEATURE*' namespace.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <david.ahern@oracle.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-iobj4f9gygcakrk2v5u61159@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/config/Makefile | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index 467106bc5fab..507350566e7f 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -203,7 +203,7 @@ endef
# the rule that uses them - an example for that is the 'bionic'
# feature check. ]
#
-CORE_FEATURE_TESTS = \
+FEATURE_TESTS = \
backtrace \
dwarf \
fortify-source \
@@ -262,7 +262,7 @@ VF_FEATURE_TESTS = \
compile-32 \
compile-x32
-# Set FEATURE_CHECK_(C|LD)FLAGS-all for all CORE_FEATURE_TESTS features.
+# Set FEATURE_CHECK_(C|LD)FLAGS-all for all FEATURE_TESTS features.
# If in the future we need per-feature checks/flags for features not
# mentioned in this list we need to refactor this ;-).
set_test_all_flags = $(eval $(set_test_all_flags_code))
@@ -271,7 +271,7 @@ define set_test_all_flags_code
FEATURE_CHECK_LDFLAGS-all += $(FEATURE_CHECK_LDFLAGS-$(1))
endef
-$(foreach feat,$(CORE_FEATURE_TESTS),$(call set_test_all_flags,$(feat)))
+$(foreach feat,$(FEATURE_TESTS),$(call set_test_all_flags,$(feat)))
#
# Special fast-path for the 'all features are available' case:
@@ -286,10 +286,10 @@ ifeq ($(feature-all), 1)
#
# test-all.c passed - just set all the core feature flags to 1:
#
- $(foreach feat,$(CORE_FEATURE_TESTS),$(call feature_set,$(feat)))
+ $(foreach feat,$(FEATURE_TESTS),$(call feature_set,$(feat)))
else
- $(shell $(MAKE) OUTPUT=$(OUTPUT_FEATURES) CFLAGS="$(EXTRA_CFLAGS)" LDFLAGS=$(LDFLAGS) -i -j -C config/feature-checks $(addsuffix .bin,$(CORE_FEATURE_TESTS)) >/dev/null 2>&1)
- $(foreach feat,$(CORE_FEATURE_TESTS),$(call feature_check,$(feat)))
+ $(shell $(MAKE) OUTPUT=$(OUTPUT_FEATURES) CFLAGS="$(EXTRA_CFLAGS)" LDFLAGS=$(LDFLAGS) -i -j -C config/feature-checks $(addsuffix .bin,$(FEATURE_TESTS)) >/dev/null 2>&1)
+ $(foreach feat,$(FEATURE_TESTS),$(call feature_check,$(feat)))
endif
ifeq ($(feature-stackprotector-all), 1)
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 11/31] perf build: Get rid of VF_FEATURE_TESTS
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (9 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 10/31] perf build: Rename CORE_FEATURE_TESTS to FEATURE_TESTS Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 12/31] perf build: Rename display_lib into feature_display Arnaldo Carvalho de Melo
` (19 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
It only contains (FEATURE_TESTS - FEATURE_DISPLAY) tests to display the
rest of the checks on 'make VF=1'. But we can actually compute this
list, which is less confusing.
Also renaming LIB_FEATURE_TESTS into FEATURE_DISPLAY, so it reflects
what this variable actually does - display its tests status to user.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <david.ahern@oracle.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-gs160y03hpmx5ezpcr4gunxc@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/config/Makefile | 32 +++++++-------------------------
1 file changed, 7 insertions(+), 25 deletions(-)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index 507350566e7f..198609e1d696 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -228,7 +228,7 @@ FEATURE_TESTS = \
libdw-dwarf-unwind \
zlib
-LIB_FEATURE_TESTS = \
+FEATURE_DISPLAY = \
dwarf \
glibc \
gtk2 \
@@ -243,25 +243,6 @@ LIB_FEATURE_TESTS = \
libdw-dwarf-unwind \
zlib
-VF_FEATURE_TESTS = \
- backtrace \
- fortify-source \
- sync-compare-and-swap \
- gtk2-infobar \
- libelf-getphdrnum \
- libelf-mmap \
- libpython-version \
- pthread-attr-setaffinity-np \
- stackprotector-all \
- timerfd \
- libunwind-debug-frame \
- bionic \
- liberty \
- liberty-z \
- cplus-demangle \
- compile-32 \
- compile-x32
-
# Set FEATURE_CHECK_(C|LD)FLAGS-all for all FEATURE_TESTS features.
# If in the future we need per-feature checks/flags for features not
# mentioned in this list we need to refactor this ;-).
@@ -805,7 +786,7 @@ define feature_print_text_code
MSG = $(shell printf '...%30s: %s' $(1) $(2))
endef
-PERF_FEATURES := $(foreach feat,$(LIB_FEATURE_TESTS),feature-$(feat)($(feature-$(feat))))
+PERF_FEATURES := $(foreach feat,$(FEATURE_DISPLAY),feature-$(feat)($(feature-$(feat))))
PERF_FEATURES_FILE := $(shell touch $(OUTPUT)PERF-FEATURES; cat $(OUTPUT)PERF-FEATURES)
ifeq ($(dwarf-post-unwind),1)
@@ -816,7 +797,7 @@ endif
# output. It's set if:
# - detected features differes from stored features from
# last build (in PERF-FEATURES file)
-# - one of the $(LIB_FEATURE_TESTS) is not detected
+# - one of the $(FEATURE_DISPLAY) is not detected
# - VF is enabled
ifneq ("$(PERF_FEATURES)","$(PERF_FEATURES_FILE)")
@@ -831,7 +812,7 @@ define feature_check_code
endif
endef
-$(foreach feat,$(LIB_FEATURE_TESTS),$(call feature_check,$(feat)))
+$(foreach feat,$(FEATURE_DISPLAY),$(call feature_check,$(feat)))
ifeq ($(VF),1)
display_lib := 1
@@ -841,7 +822,7 @@ endif
ifeq ($(display_lib),1)
$(info )
$(info Auto-detecting system features:)
- $(foreach feat,$(LIB_FEATURE_TESTS),$(call feature_print_status,$(feat),))
+ $(foreach feat,$(FEATURE_DISPLAY),$(call feature_print_status,$(feat),))
ifeq ($(dwarf-post-unwind),1)
$(call feature_print_text,"DWARF post unwind library", $(dwarf-post-unwind-text))
@@ -849,7 +830,8 @@ ifeq ($(display_lib),1)
endif
ifeq ($(display_vf),1)
- $(foreach feat,$(VF_FEATURE_TESTS),$(call feature_print_status,$(feat),))
+ TMP := $(filter-out $(FEATURE_DISPLAY),$(FEATURE_TESTS))
+ $(foreach feat,$(TMP),$(call feature_print_status,$(feat),))
$(info )
$(call feature_print_var,prefix)
$(call feature_print_var,bindir)
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 12/31] perf build: Rename display_lib into feature_display
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (10 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 11/31] perf build: Get rid of VF_FEATURE_TESTS Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 13/31] perf build: Rename display_vf to feature_verbose Arnaldo Carvalho de Melo
` (18 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
Preparing for feature checks separation, moving related stuff under
'feature*' namespace.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <david.ahern@oracle.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-t72o4nwx81owjv14y43b2wpf@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/config/Makefile | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index 198609e1d696..f80fc7ec8036 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -793,7 +793,7 @@ ifeq ($(dwarf-post-unwind),1)
PERF_FEATURES += dwarf-post-unwind($(dwarf-post-unwind-text))
endif
-# The $(display_lib) controls the default detection message
+# The $(feature_display) controls the default detection message
# output. It's set if:
# - detected features differes from stored features from
# last build (in PERF-FEATURES file)
@@ -802,24 +802,24 @@ endif
ifneq ("$(PERF_FEATURES)","$(PERF_FEATURES_FILE)")
$(shell echo "$(PERF_FEATURES)" > $(OUTPUT)PERF-FEATURES)
- display_lib := 1
+ feature_display := 1
endif
feature_check = $(eval $(feature_check_code))
define feature_check_code
ifneq ($(feature-$(1)), 1)
- display_lib := 1
+ feature_display := 1
endif
endef
$(foreach feat,$(FEATURE_DISPLAY),$(call feature_check,$(feat)))
ifeq ($(VF),1)
- display_lib := 1
+ feature_display := 1
display_vf := 1
endif
-ifeq ($(display_lib),1)
+ifeq ($(feature_display),1)
$(info )
$(info Auto-detecting system features:)
$(foreach feat,$(FEATURE_DISPLAY),$(call feature_print_status,$(feat),))
@@ -841,7 +841,7 @@ ifeq ($(display_vf),1)
$(call feature_print_var,LIBDW_DIR)
endif
-ifeq ($(display_lib),1)
+ifeq ($(feature_display),1)
$(info )
endif
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 13/31] perf build: Rename display_vf to feature_verbose
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (11 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 12/31] perf build: Rename display_lib into feature_display Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 14/31] perf build: Rename PERF-FEATURES into FEATURE-DUMP Arnaldo Carvalho de Melo
` (17 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
Preparing for feature checks separation, moving related
stuff under 'feature*' namespace.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <david.ahern@oracle.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-ciaflab01mf0ljmfb9xr4p41@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/config/Makefile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index f80fc7ec8036..370ad509422b 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -816,7 +816,7 @@ $(foreach feat,$(FEATURE_DISPLAY),$(call feature_check,$(feat)))
ifeq ($(VF),1)
feature_display := 1
- display_vf := 1
+ feature_verbose := 1
endif
ifeq ($(feature_display),1)
@@ -829,7 +829,7 @@ ifeq ($(feature_display),1)
endif
endif
-ifeq ($(display_vf),1)
+ifeq ($(feature_verbose),1)
TMP := $(filter-out $(FEATURE_DISPLAY),$(FEATURE_TESTS))
$(foreach feat,$(TMP),$(call feature_print_status,$(feat),))
$(info )
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 14/31] perf build: Rename PERF-FEATURES into FEATURE-DUMP
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (12 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 13/31] perf build: Rename display_vf to feature_verbose Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-22 10:19 ` Ingo Molnar
2015-03-19 17:04 ` [PATCH 15/31] perf build: Rename feature_print_var_code to print_var_code Arnaldo Carvalho de Melo
` (16 subsequent siblings)
30 siblings, 1 reply; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
Preparing for feature checks separation, moving related stuff under
'FEATURE*' namespace.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <david.ahern@oracle.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-v9oo22ra70rrk1dy495a7bjc@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/Makefile.perf | 2 +-
tools/perf/config/Makefile | 12 ++++++------
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/tools/perf/Makefile.perf b/tools/perf/Makefile.perf
index ec4c063ed9f3..e323eab10694 100644
--- a/tools/perf/Makefile.perf
+++ b/tools/perf/Makefile.perf
@@ -528,7 +528,7 @@ clean: $(LIBTRACEEVENT)-clean $(LIBAPI)-clean config-clean
$(Q)find . -name '*.o' -delete -o -name '\.*.cmd' -delete -o -name '\.*.d' -delete
$(Q)$(RM) .config-detected
$(call QUIET_CLEAN, core-progs) $(RM) $(ALL_PROGRAMS) perf perf-read-vdso32 perf-read-vdsox32
- $(call QUIET_CLEAN, core-gen) $(RM) *.spec *.pyc *.pyo */*.pyc */*.pyo $(OUTPUT)common-cmds.h TAGS tags cscope* $(OUTPUT)PERF-VERSION-FILE $(OUTPUT)PERF-FEATURES $(OUTPUT)util/*-bison* $(OUTPUT)util/*-flex*
+ $(call QUIET_CLEAN, core-gen) $(RM) *.spec *.pyc *.pyo */*.pyc */*.pyo $(OUTPUT)common-cmds.h TAGS tags cscope* $(OUTPUT)PERF-VERSION-FILE $(OUTPUT)FEATURE-DUMP $(OUTPUT)util/*-bison* $(OUTPUT)util/*-flex*
$(QUIET_SUBDIR0)Documentation $(QUIET_SUBDIR1) clean
$(python-clean)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index 370ad509422b..b98ab77ca179 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -786,22 +786,22 @@ define feature_print_text_code
MSG = $(shell printf '...%30s: %s' $(1) $(2))
endef
-PERF_FEATURES := $(foreach feat,$(FEATURE_DISPLAY),feature-$(feat)($(feature-$(feat))))
-PERF_FEATURES_FILE := $(shell touch $(OUTPUT)PERF-FEATURES; cat $(OUTPUT)PERF-FEATURES)
+FEATURE_DUMP := $(foreach feat,$(FEATURE_DISPLAY),feature-$(feat)($(feature-$(feat))))
+FEATURE_DUMP_FILE := $(shell touch $(OUTPUT)FEATURE-DUMP; cat $(OUTPUT)FEATURE-DUMP)
ifeq ($(dwarf-post-unwind),1)
- PERF_FEATURES += dwarf-post-unwind($(dwarf-post-unwind-text))
+ FEATURE_DUMP += dwarf-post-unwind($(dwarf-post-unwind-text))
endif
# The $(feature_display) controls the default detection message
# output. It's set if:
# - detected features differes from stored features from
-# last build (in PERF-FEATURES file)
+# last build (in FEATURE-DUMP file)
# - one of the $(FEATURE_DISPLAY) is not detected
# - VF is enabled
-ifneq ("$(PERF_FEATURES)","$(PERF_FEATURES_FILE)")
- $(shell echo "$(PERF_FEATURES)" > $(OUTPUT)PERF-FEATURES)
+ifneq ("$(FEATURE_DUMP)","$(FEATURE_DUMP_FILE)")
+ $(shell echo "$(FEATURE_DUMP)" > $(OUTPUT)FEATURE-DUMP)
feature_display := 1
endif
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 15/31] perf build: Rename feature_print_var_code to print_var_code
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (13 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 14/31] perf build: Rename PERF-FEATURES into FEATURE-DUMP Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 17/31] perf tools: Fix the bash completion for listing options of perf subcommand Arnaldo Carvalho de Melo
` (15 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
As it has nothing to do with features and won't be moved
into tools/build.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <david.ahern@oracle.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-6qgf37nss4wwjatgj5i4ng0o@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/config/Makefile | 23 ++++++++++++-----------
1 file changed, 12 insertions(+), 11 deletions(-)
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
index b98ab77ca179..489d33305b16 100644
--- a/tools/perf/config/Makefile
+++ b/tools/perf/config/Makefile
@@ -776,8 +776,8 @@ define feature_print_status_code
endif
endef
-feature_print_var = $(eval $(feature_print_var_code)) $(info $(MSG))
-define feature_print_var_code
+print_var = $(eval $(print_var_code)) $(info $(MSG))
+define print_var_code
MSG = $(shell printf '...%30s: %s' $(1) $($(1)))
endef
@@ -827,21 +827,22 @@ ifeq ($(feature_display),1)
ifeq ($(dwarf-post-unwind),1)
$(call feature_print_text,"DWARF post unwind library", $(dwarf-post-unwind-text))
endif
+
+ ifneq ($(feature_verbose),1)
+ $(info )
+ endif
endif
ifeq ($(feature_verbose),1)
TMP := $(filter-out $(FEATURE_DISPLAY),$(FEATURE_TESTS))
$(foreach feat,$(TMP),$(call feature_print_status,$(feat),))
$(info )
- $(call feature_print_var,prefix)
- $(call feature_print_var,bindir)
- $(call feature_print_var,libdir)
- $(call feature_print_var,sysconfdir)
- $(call feature_print_var,LIBUNWIND_DIR)
- $(call feature_print_var,LIBDW_DIR)
-endif
-
-ifeq ($(feature_display),1)
+ $(call print_var,prefix)
+ $(call print_var,bindir)
+ $(call print_var,libdir)
+ $(call print_var,sysconfdir)
+ $(call print_var,LIBUNWIND_DIR)
+ $(call print_var,LIBDW_DIR)
$(info )
endif
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 17/31] perf tools: Fix the bash completion for listing options of perf subcommand
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (14 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 15/31] perf build: Rename feature_print_var_code to print_var_code Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 18/31] perf tools: Fix the bash completion for listing subsubcommands " Arnaldo Carvalho de Melo
` (14 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion does not support listing options for 'perf
kvm|kmem|mem|lock|sched --<TAB>', where 'kvm|kmem|mem|lock|sched' are
all subcommands of perf.
Example:
Before this patch:
$ perf kvm --<TAB>
$
As shown above, the options of perf kvm does not come out.
After this patch:
$ perf kvm --<TAB>
--alloc --caller --input --line --raw-ip --sort
--verbose
As shown above, the options of perf kvm can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-2-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/perf-completion.sh | 21 ++++++++++++---------
1 file changed, 12 insertions(+), 9 deletions(-)
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index c2595e9bd69b..4822ed38e23e 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -119,15 +119,18 @@ __perf_main ()
elif [[ $prev == "-e" && "${words[1]}" == @(record|stat|top) ]]; then
evts=$($cmd list --raw-dump)
__perfcomp_colon "$evts" "$cur"
- # List subcommands for perf commands
- elif [[ $prev == @(kvm|kmem|mem|lock|sched) ]]; then
- subcmds=$($cmd $prev --list-cmds)
- __perfcomp_colon "$subcmds" "$cur"
- # List long option names
- elif [[ $cur == --* ]]; then
- subcmd=${words[1]}
- opts=$($cmd $subcmd --list-opts)
- __perfcomp "$opts" "$cur"
+ else
+ # List subcommands for perf commands
+ if [[ $prev == @(kvm|kmem|mem|lock|sched) ]]; then
+ subcmds=$($cmd $prev --list-cmds)
+ __perfcomp_colon "$subcmds" "$cur"
+ fi
+ # List long option names
+ if [[ $cur == --* ]]; then
+ subcmd=${words[1]}
+ opts=$($cmd $subcmd --list-opts)
+ __perfcomp "$opts" "$cur"
+ fi
fi
}
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 18/31] perf tools: Fix the bash completion for listing subsubcommands of perf subcommand
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (15 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 17/31] perf tools: Fix the bash completion for listing options of perf subcommand Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 19/31] perf tools: Provide the right bash completion for listing options of perf subcommand subsubcommand Arnaldo Carvalho de Melo
` (13 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Peter Zijlstra, Paul Mackerras,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion does not support listing subsubcommands for 'perf
kvm|kmem|mem|lock|sched --<long option> <TAB>', where 'kvm|kmem|mem|
lock|sched' are all subcommands of perf.
Example:
Before this patch:
$ perf kvm --verbose <TAB>
$
As shown above, the subsubcommands of perf kvm does not come out.
After this patch:
$ perf kvm --verbose <TAB>
buildid-list diff record report stat
top
As shown above, the subsubcommands of perf kvm can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-3-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/perf-completion.sh | 23 +++++++++++++++++++++--
1 file changed, 21 insertions(+), 2 deletions(-)
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index 4822ed38e23e..bbb61d0b79cd 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -100,6 +100,23 @@ __perfcomp_colon ()
__ltrim_colon_completions $cur
}
+__perf_prev_skip_opts ()
+{
+ local i cmd_ cmds_
+
+ let i=cword-1
+ cmds_=$($cmd --list-cmds)
+ prev_skip_opts=()
+ while [ $i -ge 0 ]; do
+ for cmd_ in $cmds_; do
+ if [[ ${words[i]} == $cmd_ ]]; then
+ prev_skip_opts=${words[i]}
+ return
+ fi
+ done
+ ((i--))
+ done
+}
__perf_main ()
{
local cmd
@@ -107,6 +124,8 @@ __perf_main ()
cmd=${words[0]}
COMPREPLY=()
+ # Skip options backward and find the last perf command
+ __perf_prev_skip_opts
# List perf subcommands or long options
if [ $cword -eq 1 ]; then
if [[ $cur == --* ]]; then
@@ -121,8 +140,8 @@ __perf_main ()
__perfcomp_colon "$evts" "$cur"
else
# List subcommands for perf commands
- if [[ $prev == @(kvm|kmem|mem|lock|sched) ]]; then
- subcmds=$($cmd $prev --list-cmds)
+ if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched) ]]; then
+ subcmds=$($cmd $prev_skip_opts --list-cmds)
__perfcomp_colon "$subcmds" "$cur"
fi
# List long option names
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 19/31] perf tools: Provide the right bash completion for listing options of perf subcommand subsubcommand
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (16 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 18/31] perf tools: Fix the bash completion for listing subsubcommands " Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 20/31] perf tools: Fix the bash completion for listing events of perf subcommand record|stat|top -e Arnaldo Carvalho de Melo
` (12 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion gives wrong options for 'perf kvm|kmem|mem|lock|
sched subsubcommand --<TAB>', where 'kvm|kmem|mem|lock|sched' are all
subcommands of perf and 'subsubcommand' is a subcommand of 'kvm|kmem|mem
|lock|sched'. In fact, the result incorrectly lists the bash completion
of 'perf subcommand' rather than 'perf subcommand subsubcommand'.
Example:
Before this patch:
$ perf kvm record --<TAB>
--guest --guestkallsyms --guestmodules --guestmount
--guestvmlinux --host --input --output
--verbose
As shown above, the result is the options of kvm rather than record.
After this patch:
$ perf kvm record --<TAB>
--all-cpus --cgroup --delay --group
--no-buildid --output --quiet --stat
--uid
--branch-any --count --event --intr-regs
--no-buildid-cache --period --raw-samples --tid
--verbose
--branch-filter --cpu --filter --mmap-pages
--no-inherit --per-thread --realtime --timestamp
--weight
--call-graph --data --freq
--no-buffering --no-samples --pid
--running-time --transaction
As shown above, the result is exactly the options of record as we wished.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-4-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/perf-completion.sh | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index bbb61d0b79cd..01ce841f155b 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -105,9 +105,12 @@ __perf_prev_skip_opts ()
local i cmd_ cmds_
let i=cword-1
- cmds_=$($cmd --list-cmds)
+ cmds_=$($cmd $1 --list-cmds)
prev_skip_opts=()
while [ $i -ge 0 ]; do
+ if [[ ${words[i]} == $1 ]]; then
+ return
+ fi
for cmd_ in $cmds_; do
if [[ ${words[i]} == $cmd_ ]]; then
prev_skip_opts=${words[i]}
@@ -146,7 +149,9 @@ __perf_main ()
fi
# List long option names
if [[ $cur == --* ]]; then
- subcmd=${words[1]}
+ subcmd=$prev_skip_opts
+ __perf_prev_skip_opts $subcmd
+ subcmd=$subcmd" "$prev_skip_opts
opts=$($cmd $subcmd --list-opts)
__perfcomp "$opts" "$cur"
fi
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 20/31] perf tools: Fix the bash completion for listing events of perf subcommand record|stat|top -e
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (17 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 19/31] perf tools: Provide the right bash completion for listing options of perf subcommand subsubcommand Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 21/31] perf tools: Fix the bash completion to support listing events for --event Arnaldo Carvalho de Melo
` (11 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion does not support listing events for 'perf kvm|kmem|
mem|lock|sched record|stat|top -e <TAB>', where 'kvm|kmem|mem|lock|sched'
are all subcommands of perf.
Example:
Before this patch:
$ perf kvm record -e <TAB>
$
As shown above, the events of record does not come out.
After this patch:
$ perf kvm record -e <TAB>
alignment-faults cpu/instructions/
L1-dcache-prefetch-misses node-prefetches
uncore_rbox_0/qpi0_idle_filt/
branch-instructions cpu/mem-loads/
L1-dcache-store-misses node-prefetch-misses
uncore_rbox_0/qpi1_date_response/
branch-load-misses cpu-migrations
L1-dcache-stores node-store-misses
uncore_rbox_0/qpi1_filt_send/
branch-loads dTLB-load-misses
L1-icache-load-misses node-stores
uncore_rbox_0/qpi1_idle_filt/
...
As shown above, the events of record can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-5-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/perf-completion.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index 01ce841f155b..4b58ac2ae578 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -138,7 +138,7 @@ __perf_main ()
fi
__perfcomp "$cmds" "$cur"
# List possible events for -e option
- elif [[ $prev == "-e" && "${words[1]}" == @(record|stat|top) ]]; then
+ elif [[ $prev == "-e" && $prev_skip_opts == @(record|stat|top) ]]; then
evts=$($cmd list --raw-dump)
__perfcomp_colon "$evts" "$cur"
else
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 21/31] perf tools: Fix the bash completion to support listing events for --event
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (18 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 20/31] perf tools: Fix the bash completion for listing events of perf subcommand record|stat|top -e Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 22/31] perf tools: Fix the bash completion for listing subcommands of perf Arnaldo Carvalho de Melo
` (10 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion only supports -e rather than --event, so fix it.
Example:
Before this patch:
$ perf record --event <TAB>
$
As shown above, the events of record does not come out.
After this patch:
$ perf record --event <TAB>
lignment-faults cpu/instructions/
L1-dcache-prefetch-misses node-prefetches
uncore_rbox_0/qpi0_idle_filt/
branch-instructions cpu/mem-loads/
L1-dcache-store-misses node-prefetch-misses
uncore_rbox_0/qpi1_date_response/
branch-load-misses cpu-migrations
L1-dcache-stores node-store-misses
uncore_rbox_0/qpi1_filt_send/
branch-loads dTLB-load-misses
L1-icache-load-misses node-stores
uncore_rbox_0/qpi1_idle_filt/
...
As shown above, the events of record can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-6-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/perf-completion.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index 4b58ac2ae578..3e25d3ea17f9 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -137,8 +137,8 @@ __perf_main ()
cmds=$($cmd --list-cmds)
fi
__perfcomp "$cmds" "$cur"
- # List possible events for -e option
- elif [[ $prev == "-e" && $prev_skip_opts == @(record|stat|top) ]]; then
+ # List possible events for -e and --event option
+ elif [[ $prev == @("-e"|"--event") && $prev_skip_opts == @(record|stat|top) ]]; then
evts=$($cmd list --raw-dump)
__perfcomp_colon "$evts" "$cur"
else
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 22/31] perf tools: Fix the bash completion for listing subcommands of perf
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (19 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 21/31] perf tools: Fix the bash completion to support listing events for --event Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 23/31] perf tools: Add the bash completion for listing subsubcommands of perf data Arnaldo Carvalho de Melo
` (9 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion does not support listing subcommands for 'perf
--<long option> <TAB>'.
Example:
Before this patch:
$ perf --debug <TAB>
$
As shown above, the subcommands of perf does not come out.
After this patch:
$ perf --debug <TAB>
annotate buildid-cache data evlist inject
kvm lock probe report script
test top version
bench buildid-list diff help kmem
list mem record sched stat
timechart trace
As shown above, the subcommands of perf can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-7-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/perf-completion.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index 3e25d3ea17f9..7b98ae48f0bf 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -130,7 +130,7 @@ __perf_main ()
# Skip options backward and find the last perf command
__perf_prev_skip_opts
# List perf subcommands or long options
- if [ $cword -eq 1 ]; then
+ if [ -z $prev_skip_opts ]; then
if [[ $cur == --* ]]; then
cmds=$($cmd --list-opts)
else
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 23/31] perf tools: Add the bash completion for listing subsubcommands of perf data
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (20 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 22/31] perf tools: Fix the bash completion for listing subcommands of perf Arnaldo Carvalho de Melo
@ 2015-03-19 17:04 ` Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 24/31] perf tools: Add the bash completion for listing subsubcommands of perf help Arnaldo Carvalho de Melo
` (8 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion does not support listing subsubcommands for 'perf
data <TAB>', so fix it.
Example:
Before this patch:
$ perf data <TAB>
$
As shown above, the subsubcommands of perf data does not come out.
After this patch:
$ perf data <TAB>
convert
As shown above, the subsubcommands of perf data can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-8-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-data.c | 6 ++++--
tools/perf/perf-completion.sh | 2 +-
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/tools/perf/builtin-data.c b/tools/perf/builtin-data.c
index 155cf75b8199..709152a7b408 100644
--- a/tools/perf/builtin-data.c
+++ b/tools/perf/builtin-data.c
@@ -22,7 +22,9 @@ static const struct option data_options[] = {
OPT_END()
};
-static const char * const data_usage[] = {
+static const char * const data_subcommands[] = { "convert", NULL };
+
+static const char *data_usage[] = {
"perf data [<common options>] <command> [<options>]",
NULL
};
@@ -98,7 +100,7 @@ int cmd_data(int argc, const char **argv, const char *prefix)
if (argc < 2)
goto usage;
- argc = parse_options(argc, argv, data_options, data_usage,
+ argc = parse_options_subcommand(argc, argv, data_options, data_subcommands, data_usage,
PARSE_OPT_STOP_AT_NON_OPTION);
if (argc < 1)
goto usage;
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index 7b98ae48f0bf..535ff72babc7 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -143,7 +143,7 @@ __perf_main ()
__perfcomp_colon "$evts" "$cur"
else
# List subcommands for perf commands
- if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched) ]]; then
+ if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|data) ]]; then
subcmds=$($cmd $prev_skip_opts --list-cmds)
__perfcomp_colon "$subcmds" "$cur"
fi
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 24/31] perf tools: Add the bash completion for listing subsubcommands of perf help
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (21 preceding siblings ...)
2015-03-19 17:04 ` [PATCH 23/31] perf tools: Add the bash completion for listing subsubcommands of perf data Arnaldo Carvalho de Melo
@ 2015-03-19 17:05 ` Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 25/31] perf tools: Add the bash completion for listing subsubcommands of perf script Arnaldo Carvalho de Melo
` (7 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:05 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion does not support listing subsubcommands for 'perf
help <TAB>', so fix it.
Example:
Before this patch:
$ perf help <TAB>
$
As shown above, the subsubcommands of perf help does not come out.
After this patch:
$ perf help <TAB>
annotate buildid-cache data evlist inject
kvm lock probe report script
test top
bench buildid-list diff help kmem
list mem record sched stat
timechart trace
As shown above, the subsubcommands of perf help can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-9-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-help.c | 17 ++++++++++++++---
tools/perf/perf-completion.sh | 2 +-
2 files changed, 15 insertions(+), 4 deletions(-)
diff --git a/tools/perf/builtin-help.c b/tools/perf/builtin-help.c
index 25d20628212e..36486eade1ef 100644
--- a/tools/perf/builtin-help.c
+++ b/tools/perf/builtin-help.c
@@ -437,7 +437,18 @@ int cmd_help(int argc, const char **argv, const char *prefix __maybe_unused)
HELP_FORMAT_INFO),
OPT_END(),
};
- const char * const builtin_help_usage[] = {
+ const char * const builtin_help_subcommands[] = {
+ "buildid-cache", "buildid-list", "diff", "evlist", "help", "list",
+ "record", "report", "bench", "stat", "timechart", "top", "annotate",
+ "script", "sched", "kmem", "lock", "kvm", "test", "inject", "mem", "data",
+#ifdef HAVE_LIBELF_SUPPORT
+ "probe",
+#endif
+#ifdef HAVE_LIBAUDIT_SUPPORT
+ "trace",
+#endif
+ NULL };
+ const char *builtin_help_usage[] = {
"perf help [--all] [--man|--web|--info] [command]",
NULL
};
@@ -448,8 +459,8 @@ int cmd_help(int argc, const char **argv, const char *prefix __maybe_unused)
perf_config(perf_help_config, &help_format);
- argc = parse_options(argc, argv, builtin_help_options,
- builtin_help_usage, 0);
+ argc = parse_options_subcommand(argc, argv, builtin_help_options,
+ builtin_help_subcommands, builtin_help_usage, 0);
if (show_all) {
printf("\n usage: %s\n\n", perf_usage_string);
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index 535ff72babc7..dbca6a66f401 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -143,7 +143,7 @@ __perf_main ()
__perfcomp_colon "$evts" "$cur"
else
# List subcommands for perf commands
- if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|data) ]]; then
+ if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|data|help) ]]; then
subcmds=$($cmd $prev_skip_opts --list-cmds)
__perfcomp_colon "$subcmds" "$cur"
fi
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 25/31] perf tools: Add the bash completion for listing subsubcommands of perf script
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (22 preceding siblings ...)
2015-03-19 17:05 ` [PATCH 24/31] perf tools: Add the bash completion for listing subsubcommands of perf help Arnaldo Carvalho de Melo
@ 2015-03-19 17:05 ` Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 26/31] perf tools: Add the bash completion for listing subsubcommands of perf test Arnaldo Carvalho de Melo
` (6 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:05 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion does not support listing subsubcommands for 'perf
script <TAB>', so fix it.
Example:
Before this patch:
$ perf script <TAB>
$
As shown above, the subsubcommands of perf script does not come out.
After this patch:
$ perf script <TAB>
record report
As shown above, the subsubcommands of perf script can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-10-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-script.c | 5 +++--
tools/perf/perf-completion.sh | 2 +-
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/tools/perf/builtin-script.c b/tools/perf/builtin-script.c
index c7e6750923ef..f2a348b57b8f 100644
--- a/tools/perf/builtin-script.c
+++ b/tools/perf/builtin-script.c
@@ -1572,7 +1572,8 @@ int cmd_script(int argc, const char **argv, const char *prefix __maybe_unused)
"Show the mmap events"),
OPT_END()
};
- const char * const script_usage[] = {
+ const char * const script_subcommands[] = { "record", "report", NULL };
+ const char *script_usage[] = {
"perf script [<options>]",
"perf script [<options>] record <script> [<record-options>] <command>",
"perf script [<options>] report <script> [script-args]",
@@ -1586,7 +1587,7 @@ int cmd_script(int argc, const char **argv, const char *prefix __maybe_unused)
setup_scripting();
- argc = parse_options(argc, argv, options, script_usage,
+ argc = parse_options_subcommand(argc, argv, options, script_subcommands, script_usage,
PARSE_OPT_STOP_AT_NON_OPTION);
file.path = input_name;
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index dbca6a66f401..8739a1345017 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -143,7 +143,7 @@ __perf_main ()
__perfcomp_colon "$evts" "$cur"
else
# List subcommands for perf commands
- if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|data|help) ]]; then
+ if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|data|help|script) ]]; then
subcmds=$($cmd $prev_skip_opts --list-cmds)
__perfcomp_colon "$subcmds" "$cur"
fi
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 26/31] perf tools: Add the bash completion for listing subsubcommands of perf test
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (23 preceding siblings ...)
2015-03-19 17:05 ` [PATCH 25/31] perf tools: Add the bash completion for listing subsubcommands of perf script Arnaldo Carvalho de Melo
@ 2015-03-19 17:05 ` Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 27/31] perf tools: Add the bash completion for listing subsubcommands of perf timechart Arnaldo Carvalho de Melo
` (5 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:05 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion does not support listing subsubcommands for 'perf
test <TAB>', so fix it.
Example:
Before this patch:
$ perf test <TAB>
$
As shown above, the subsubcommands of perf test does not come out.
After this patch:
$ perf test <TAB>
list
As shown above, the subsubcommands of perf test can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-11-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/perf-completion.sh | 2 +-
tools/perf/tests/builtin-test.c | 5 +++--
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index 8739a1345017..35f43fd7a38b 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -143,7 +143,7 @@ __perf_main ()
__perfcomp_colon "$evts" "$cur"
else
# List subcommands for perf commands
- if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|data|help|script) ]]; then
+ if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|data|help|script|test) ]]; then
subcmds=$($cmd $prev_skip_opts --list-cmds)
__perfcomp_colon "$subcmds" "$cur"
fi
diff --git a/tools/perf/tests/builtin-test.c b/tools/perf/tests/builtin-test.c
index 4b7d9ab0f049..ed8e05c6839a 100644
--- a/tools/perf/tests/builtin-test.c
+++ b/tools/perf/tests/builtin-test.c
@@ -291,7 +291,7 @@ static int perf_test__list(int argc, const char **argv)
int cmd_test(int argc, const char **argv, const char *prefix __maybe_unused)
{
- const char * const test_usage[] = {
+ const char *test_usage[] = {
"perf test [<options>] [{list <test-name-fragment>|[<test-name-fragments>|<test-numbers>]}]",
NULL,
};
@@ -302,13 +302,14 @@ int cmd_test(int argc, const char **argv, const char *prefix __maybe_unused)
"be more verbose (show symbol address, etc)"),
OPT_END()
};
+ const char * const test_subcommands[] = { "list", NULL };
struct intlist *skiplist = NULL;
int ret = hists__init();
if (ret < 0)
return ret;
- argc = parse_options(argc, argv, test_options, test_usage, 0);
+ argc = parse_options_subcommand(argc, argv, test_options, test_subcommands, test_usage, 0);
if (argc >= 1 && !strcmp(argv[0], "list"))
return perf_test__list(argc, argv);
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 27/31] perf tools: Add the bash completion for listing subsubcommands of perf timechart
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (24 preceding siblings ...)
2015-03-19 17:05 ` [PATCH 26/31] perf tools: Add the bash completion for listing subsubcommands of perf test Arnaldo Carvalho de Melo
@ 2015-03-19 17:05 ` Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 28/31] perf tools: Add the bash completion for listing subsubcommands of perf trace Arnaldo Carvalho de Melo
` (4 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:05 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion does not support listing subsubcommands for 'perf
timechart <TAB>', so fix it.
Example:
Before this patch:
$ perf timechart <TAB>
$
As shown above, the subsubcommands of perf timechart does not come out.
After this patch:
$ perf timechart <TAB>
record
As shown above, the subsubcommands of perf timechart can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-12-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-timechart.c | 7 ++++---
tools/perf/perf-completion.sh | 2 +-
2 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/tools/perf/builtin-timechart.c b/tools/perf/builtin-timechart.c
index 51440d1fc722..494b3bbe5ea4 100644
--- a/tools/perf/builtin-timechart.c
+++ b/tools/perf/builtin-timechart.c
@@ -1958,7 +1958,8 @@ int cmd_timechart(int argc, const char **argv,
parse_time),
OPT_END()
};
- const char * const timechart_usage[] = {
+ const char * const timechart_subcommands[] = { "record", NULL };
+ const char *timechart_usage[] = {
"perf timechart [<options>] {record}",
NULL
};
@@ -1976,8 +1977,8 @@ int cmd_timechart(int argc, const char **argv,
"perf timechart record [<options>]",
NULL
};
- argc = parse_options(argc, argv, timechart_options, timechart_usage,
- PARSE_OPT_STOP_AT_NON_OPTION);
+ argc = parse_options_subcommand(argc, argv, timechart_options, timechart_subcommands,
+ timechart_usage, PARSE_OPT_STOP_AT_NON_OPTION);
if (tchart.power_only && tchart.tasks_only) {
pr_err("-P and -T options cannot be used at the same time.\n");
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index 35f43fd7a38b..a33d2ef53ae4 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -143,7 +143,7 @@ __perf_main ()
__perfcomp_colon "$evts" "$cur"
else
# List subcommands for perf commands
- if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|data|help|script|test) ]]; then
+ if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|data|help|script|test|timechart) ]]; then
subcmds=$($cmd $prev_skip_opts --list-cmds)
__perfcomp_colon "$subcmds" "$cur"
fi
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 28/31] perf tools: Add the bash completion for listing subsubcommands of perf trace
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (25 preceding siblings ...)
2015-03-19 17:05 ` [PATCH 27/31] perf tools: Add the bash completion for listing subsubcommands of perf timechart Arnaldo Carvalho de Melo
@ 2015-03-19 17:05 ` Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 29/31] perf tools: Avoid confusion with preloaded bash function for perf bash completion Arnaldo Carvalho de Melo
` (3 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:05 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
The bash completion does not support listing subsubcommands for 'perf
trace <TAB>', so fix it.
Example:
Before this patch:
$ perf trace <TAB>
$
As shown above, the subsubcommands of perf trace does not come out.
After this patch:
$ perf trace <TAB>
record
As shown above, the subsubcommands of perf trace can come out now.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-13-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-trace.c | 7 ++++---
tools/perf/perf-completion.sh | 9 ++++++---
2 files changed, 10 insertions(+), 6 deletions(-)
diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
index 6969ba98ff2f..0b3b4e4984b9 100644
--- a/tools/perf/builtin-trace.c
+++ b/tools/perf/builtin-trace.c
@@ -2609,7 +2609,7 @@ static void evlist__set_evsel_handler(struct perf_evlist *evlist, void *handler)
int cmd_trace(int argc, const char **argv, const char *prefix __maybe_unused)
{
- const char * const trace_usage[] = {
+ const char *trace_usage[] = {
"perf trace [<options>] [<command>]",
"perf trace [<options>] -- <command> [<options>]",
"perf trace record [<options>] [<command>]",
@@ -2684,6 +2684,7 @@ int cmd_trace(int argc, const char **argv, const char *prefix __maybe_unused)
OPT_BOOLEAN(0, "syscalls", &trace.trace_syscalls, "Trace syscalls"),
OPT_END()
};
+ const char * const trace_subcommands[] = { "record", NULL };
int err;
char bf[BUFSIZ];
@@ -2699,8 +2700,8 @@ int cmd_trace(int argc, const char **argv, const char *prefix __maybe_unused)
goto out;
}
- argc = parse_options(argc, argv, trace_options, trace_usage,
- PARSE_OPT_STOP_AT_NON_OPTION);
+ argc = parse_options_subcommand(argc, argv, trace_options, trace_subcommands,
+ trace_usage, PARSE_OPT_STOP_AT_NON_OPTION);
if (trace.trace_pgfaults) {
trace.opts.sample_address = true;
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index a33d2ef53ae4..bdd40350870a 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -120,6 +120,7 @@ __perf_prev_skip_opts ()
((i--))
done
}
+
__perf_main ()
{
local cmd
@@ -137,13 +138,15 @@ __perf_main ()
cmds=$($cmd --list-cmds)
fi
__perfcomp "$cmds" "$cur"
- # List possible events for -e and --event option
- elif [[ $prev == @("-e"|"--event") && $prev_skip_opts == @(record|stat|top) ]]; then
+ # List possible events for -e option
+ elif [[ $prev == @("-e"|"--event") &&
+ $prev_skip_opts == @(record|stat|top) ]]; then
evts=$($cmd list --raw-dump)
__perfcomp_colon "$evts" "$cur"
else
# List subcommands for perf commands
- if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|data|help|script|test|timechart) ]]; then
+ if [[ $prev_skip_opts == @(kvm|kmem|mem|lock|sched|
+ |data|help|script|test|timechart|trace) ]]; then
subcmds=$($cmd $prev_skip_opts --list-cmds)
__perfcomp_colon "$subcmds" "$cur"
fi
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 29/31] perf tools: Avoid confusion with preloaded bash function for perf bash completion
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (26 preceding siblings ...)
2015-03-19 17:05 ` [PATCH 28/31] perf tools: Add the bash completion for listing subsubcommands of perf trace Arnaldo Carvalho de Melo
@ 2015-03-19 17:05 ` Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 30/31] perf callchain: Separate eh/debug frame offset cache Arnaldo Carvalho de Melo
` (2 subsequent siblings)
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:05 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Yunlong Song, Paul Mackerras, Peter Zijlstra,
Wang Nan, Arnaldo Carvalho de Melo
From: Yunlong Song <yunlong.song@huawei.com>
Since some functions (e.g. '_get_comp_words_by_ref()') in perf bash
completion script are originally taken from git bash completion script,
these functions may be preloaded before perf bash completion script
runs.
In order to avoid repeating loading the same function twice, some test
constraints are used before these function definitions in the perf bash
completion script (e.g. 'type _get_comp_words_by_ref &>/dev/null ||').
The problem is that, if these functions in perf bash completion script
are changed for some reason, perf will still use the preloaded bash
functions rather than the customized functions of its own.
As a result, the perf bash completion will behave incorrectly. To get
rid of this problem, a flag can be defined to determine the proper
situation.
And to avoid overwriting the preloaded functions, the names of these
functions in perf bash completion script should be renamed to the
perf-customized ones.
Example:
Before this patch:
$ type _get_comp_words_by_ref
_get_comp_words_by_ref is a function
_get_comp_words_by_ref ()
{
local exclude flag i OPTIND=1;
local cur cword words=();
local upargs=() upvars=() vcur vcword vprev vwords;
while getopts "c:i:n:p:w:" flag "$@"; do
case $flag in
c)
vcur=$OPTARG
;;
i)
vcword=$OPTARG
;;
n)
exclude=$OPTARG
;;
p)
vprev=$OPTARG
;;
w)
vwords=$OPTARG
;;
esac;
done;
while [[ $# -ge $OPTIND ]]; do
case ${!OPTIND} in
cur)
vcur=cur
;;
prev)
vprev=prev
;;
cword)
vcword=cword
;;
words)
vwords=words
;;
*)
echo "bash: $FUNCNAME(): \`${!OPTIND}': unknown argument" 1>&2;
return 1
;;
esac;
let "OPTIND += 1";
done;
__get_cword_at_cursor_by_ref "$exclude" words cword cur;
[[ -n $vcur ]] && {
upvars+=("$vcur");
upargs+=(-v $vcur "$cur")
};
[[ -n $vcword ]] && {
upvars+=("$vcword");
upargs+=(-v $vcword "$cword")
};
[[ -n $vprev && $cword -ge 1 ]] && {
upvars+=("$vprev");
upargs+=(-v $vprev "${words[cword - 1]}")
};
[[ -n $vwords ]] && {
upvars+=("$vwords");
upargs+=(-a${#words[@]} $vwords "${words[@]}")
};
(( ${#upvars[@]} )) && local "${upvars[@]}" && _upvars "${upargs[@]}"
}
As shown above, the _get_comp_words_by_ref is the preloaded function in
fact, rather than the function defined in perf-completion.sh. So if we
happen to change the function for some reason, the result will behave in
a wrong state.
After this patch:
We can set preload_get_comp_words_by_ref="false" to not use the preloaded
function. Instead, it will use the function defined in perf-completion.sh,
which is renamed as __perf_get_comp_words_by_ref to avoid overwriting
the preloaded function _get_comp_words_by_ref.
$ type __perf_get_comp_words_by_ref
__perf_get_comp_words_by_ref is a function
__perf_get_comp_words_by_ref ()
{
local exclude cur_ words_ cword_;
if [ "$1" = "-n" ]; then
exclude=$2;
shift 2;
fi;
__my_reassemble_comp_words_by_ref "$exclude";
cur_=${words_[cword_]};
while [ $# -gt 0 ]; do
case "$1" in
cur)
cur=$cur_
;;
prev)
prev=${words_[$cword_-1]}
;;
words)
words=("${words_[@]}")
;;
cword)
cword=$cword_
;;
esac;
shift;
done
}
As shown above, the function __perf_get_comp_words_by_ref is loaded and
can work this time.
Note that we do not change the original behavior when those functions are
not preloaded before perf bash completion script runs. In this case,
although the flag is set to "true", the code will still change it to
"false" to use the function defined in perf-completion.sh.
Signed-off-by: Yunlong Song <yunlong.song@huawei.com>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/r/1426685758-25488-14-git-send-email-yunlong.song@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/perf-completion.sh | 36 ++++++++++++++++++++++++++++++------
1 file changed, 30 insertions(+), 6 deletions(-)
diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index bdd40350870a..3ba80b2359cc 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -47,8 +47,16 @@ __my_reassemble_comp_words_by_ref()
done
}
-type _get_comp_words_by_ref &>/dev/null ||
-_get_comp_words_by_ref()
+# Define preload_get_comp_words_by_ref="false", if the function
+# __perf_get_comp_words_by_ref() is required instead.
+preload_get_comp_words_by_ref="true"
+
+if [ $preload_get_comp_words_by_ref = "true" ]; then
+ type _get_comp_words_by_ref &>/dev/null ||
+ preload_get_comp_words_by_ref="false"
+fi
+[ $preload_get_comp_words_by_ref = "true" ] ||
+__perf_get_comp_words_by_ref()
{
local exclude cur_ words_ cword_
if [ "$1" = "-n" ]; then
@@ -76,8 +84,16 @@ _get_comp_words_by_ref()
done
}
-type __ltrim_colon_completions &>/dev/null ||
-__ltrim_colon_completions()
+# Define preload__ltrim_colon_completions="false", if the function
+# __perf__ltrim_colon_completions() is required instead.
+preload__ltrim_colon_completions="true"
+
+if [ $preload__ltrim_colon_completions = "true" ]; then
+ type __ltrim_colon_completions &>/dev/null ||
+ preload__ltrim_colon_completions="false"
+fi
+[ $preload__ltrim_colon_completions = "true" ] ||
+__perf__ltrim_colon_completions()
{
if [[ "$1" == *:* && "$COMP_WORDBREAKS" == *:* ]]; then
# Remove colon-word prefix from COMPREPLY items
@@ -97,7 +113,11 @@ __perfcomp ()
__perfcomp_colon ()
{
__perfcomp "$1" "$2"
- __ltrim_colon_completions $cur
+ if [ $preload__ltrim_colon_completions = "true" ]; then
+ __ltrim_colon_completions $cur
+ else
+ __perf__ltrim_colon_completions $cur
+ fi
}
__perf_prev_skip_opts ()
@@ -226,7 +246,11 @@ type perf &>/dev/null &&
_perf()
{
local cur words cword prev
- _get_comp_words_by_ref -n =: cur words cword prev
+ if [ $preload_get_comp_words_by_ref = "true" ]; then
+ _get_comp_words_by_ref -n =: cur words cword prev
+ else
+ __perf_get_comp_words_by_ref -n =: cur words cword prev
+ fi
__perf_main
} &&
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 30/31] perf callchain: Separate eh/debug frame offset cache.
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (27 preceding siblings ...)
2015-03-19 17:05 ` [PATCH 29/31] perf tools: Avoid confusion with preloaded bash function for perf bash completion Arnaldo Carvalho de Melo
@ 2015-03-19 17:05 ` Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 31/31] perf report: Don't allow empty argument for '-t' Arnaldo Carvalho de Melo
2015-03-22 9:55 ` [GIT PULL 00/31] perf/core improvements and fixes Ingo Molnar
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:05 UTC (permalink / raw)
To: Ingo Molnar; +Cc: linux-kernel, Wang Nan, Li Zefan, Arnaldo Carvalho de Melo
From: Wang Nan <wangnan0@huawei.com>
Commit f1f13af99a90 ("perf callchain: Cache eh/debug frame offset for
dwarf unwind") introduces a cache for .debug_frame and .eh_frame_hdr.
Unfortunately, it makes them share a same cache (dso->frame_offset).
Which causes unwind failure on ARM:
$ perf test unwind
Test dwarf unwind: FAILED!
The reason is that, if a dso has '.debug_frame' but doesn't have
'.eh_frame_hdr' (like ARM), dso->frame_offset will be filled by offset
of '.debug_frame' during the first time calling of find_proc_info() ->
read_unwind_spec_debug_frame(), and be regarded to '.eh_frame_hdr' when
the second time calling of find_proc_info() ->
read_unwind_spec_eh_frame(), since '.eh_frame_hdr' is checked prior to
'.debug_frame'.
This patch solves the problem by creating two cache fields for
'.eh_frame_hdr' and '.debug_frame'.
Signed-off-by: Wang Nan <wangnan0@huawei.com>
Acked-by: Jiri Olsa <jolsa@redhat.com>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Cc: Li Zefan <lizefan@huawei.com>
Link: http://lkml.kernel.org/r/55028BA0.1030701@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/util/dso.h | 3 ++-
tools/perf/util/unwind-libunwind.c | 8 ++++----
2 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/tools/perf/util/dso.h b/tools/perf/util/dso.h
index ced92841ff97..408c65f1a757 100644
--- a/tools/perf/util/dso.h
+++ b/tools/perf/util/dso.h
@@ -139,7 +139,8 @@ struct dso {
u32 status_seen;
size_t file_size;
struct list_head open_entry;
- u64 frame_offset;
+ u64 debug_frame_offset;
+ u64 eh_frame_hdr_offset;
} data;
union { /* Tool specific area */
diff --git a/tools/perf/util/unwind-libunwind.c b/tools/perf/util/unwind-libunwind.c
index e3c40a520a25..7b09a443a280 100644
--- a/tools/perf/util/unwind-libunwind.c
+++ b/tools/perf/util/unwind-libunwind.c
@@ -266,7 +266,7 @@ static int read_unwind_spec_eh_frame(struct dso *dso, struct machine *machine,
u64 *fde_count)
{
int ret = -EINVAL, fd;
- u64 offset = dso->data.frame_offset;
+ u64 offset = dso->data.eh_frame_hdr_offset;
if (offset == 0) {
fd = dso__data_fd(dso, machine);
@@ -275,7 +275,7 @@ static int read_unwind_spec_eh_frame(struct dso *dso, struct machine *machine,
/* Check the .eh_frame section for unwinding info */
offset = elf_section_offset(fd, ".eh_frame_hdr");
- dso->data.frame_offset = offset;
+ dso->data.eh_frame_hdr_offset = offset;
}
if (offset)
@@ -291,7 +291,7 @@ static int read_unwind_spec_debug_frame(struct dso *dso,
struct machine *machine, u64 *offset)
{
int fd;
- u64 ofs = dso->data.frame_offset;
+ u64 ofs = dso->data.debug_frame_offset;
if (ofs == 0) {
fd = dso__data_fd(dso, machine);
@@ -300,7 +300,7 @@ static int read_unwind_spec_debug_frame(struct dso *dso,
/* Check the .debug_frame section for unwinding info */
ofs = elf_section_offset(fd, ".debug_frame");
- dso->data.frame_offset = ofs;
+ dso->data.debug_frame_offset = ofs;
}
*offset = ofs;
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* [PATCH 31/31] perf report: Don't allow empty argument for '-t'.
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (28 preceding siblings ...)
2015-03-19 17:05 ` [PATCH 30/31] perf callchain: Separate eh/debug frame offset cache Arnaldo Carvalho de Melo
@ 2015-03-19 17:05 ` Arnaldo Carvalho de Melo
2015-03-22 9:55 ` [GIT PULL 00/31] perf/core improvements and fixes Ingo Molnar
30 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-19 17:05 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Wang Nan, pi3orama, Jiri Olsa, Zefan Li,
Arnaldo Carvalho de Melo
From: Wang Nan <wangnan0@huawei.com>
Without this patch, perf report cause segfault if pass "" as '-t':
$ perf report -t ""
# To display the perf.data header info, please use --header/--header-only options.
#
# Samples: 37 of event 'syscalls:sys_enter_write'
# Event count (approx.): 37
#
# Children SelfCommand Shared Object Symbol
Segmentation fault
Since -t is used to add field-separator for generate table, -t "" is
actually meanless. This patch defines a new OPT_STRING_NOEMPTY() option
generator to ensure user never pass empty string to that option.
Signed-off-by: Wang Nan <wangnan0@huawei.com>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Cc: pi3orama@163.com
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Zefan Li <lizefan@huawei.com>
Link: http://lkml.kernel.org/r/1426251114-198991-1-git-send-email-wangnan0@huawei.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-report.c | 2 +-
tools/perf/util/parse-options.c | 21 +++++++++++++++++++--
tools/perf/util/parse-options.h | 2 ++
3 files changed, 22 insertions(+), 3 deletions(-)
diff --git a/tools/perf/builtin-report.c b/tools/perf/builtin-report.c
index 52f74e1367e9..0ae482689e3c 100644
--- a/tools/perf/builtin-report.c
+++ b/tools/perf/builtin-report.c
@@ -676,7 +676,7 @@ int cmd_report(int argc, const char **argv, const char *prefix __maybe_unused)
OPT_STRING('w', "column-widths", &symbol_conf.col_width_list_str,
"width[,width...]",
"don't try to adjust column width, use these fixed values"),
- OPT_STRING('t', "field-separator", &symbol_conf.field_sep, "separator",
+ OPT_STRING_NOEMPTY('t', "field-separator", &symbol_conf.field_sep, "separator",
"separator for columns, no spaces will be added between "
"columns '.' is reserved."),
OPT_BOOLEAN('U', "hide-unresolved", &report.hide_unresolved,
diff --git a/tools/perf/util/parse-options.c b/tools/perf/util/parse-options.c
index 1457d6639b60..01626be2a8eb 100644
--- a/tools/perf/util/parse-options.c
+++ b/tools/perf/util/parse-options.c
@@ -37,6 +37,7 @@ static int get_value(struct parse_opt_ctx_t *p,
{
const char *s, *arg = NULL;
const int unset = flags & OPT_UNSET;
+ int err;
if (unset && p->opt)
return opterror(opt, "takes no value", flags);
@@ -114,13 +115,29 @@ static int get_value(struct parse_opt_ctx_t *p,
return 0;
case OPTION_STRING:
+ err = 0;
if (unset)
*(const char **)opt->value = NULL;
else if (opt->flags & PARSE_OPT_OPTARG && !p->opt)
*(const char **)opt->value = (const char *)opt->defval;
else
- return get_arg(p, opt, flags, (const char **)opt->value);
- return 0;
+ err = get_arg(p, opt, flags, (const char **)opt->value);
+
+ /* PARSE_OPT_NOEMPTY: Allow NULL but disallow empty string. */
+ if (opt->flags & PARSE_OPT_NOEMPTY) {
+ const char *val = *(const char **)opt->value;
+
+ if (!val)
+ return err;
+
+ /* Similar to unset if we are given an empty string. */
+ if (val[0] == '\0') {
+ *(const char **)opt->value = NULL;
+ return 0;
+ }
+ }
+
+ return err;
case OPTION_CALLBACK:
if (unset)
diff --git a/tools/perf/util/parse-options.h b/tools/perf/util/parse-options.h
index 97b153fb4999..59561fd86278 100644
--- a/tools/perf/util/parse-options.h
+++ b/tools/perf/util/parse-options.h
@@ -40,6 +40,7 @@ enum parse_opt_option_flags {
PARSE_OPT_LASTARG_DEFAULT = 16,
PARSE_OPT_DISABLED = 32,
PARSE_OPT_EXCLUSIVE = 64,
+ PARSE_OPT_NOEMPTY = 128,
};
struct option;
@@ -122,6 +123,7 @@ struct option {
#define OPT_LONG(s, l, v, h) { .type = OPTION_LONG, .short_name = (s), .long_name = (l), .value = check_vtype(v, long *), .help = (h) }
#define OPT_U64(s, l, v, h) { .type = OPTION_U64, .short_name = (s), .long_name = (l), .value = check_vtype(v, u64 *), .help = (h) }
#define OPT_STRING(s, l, v, a, h) { .type = OPTION_STRING, .short_name = (s), .long_name = (l), .value = check_vtype(v, const char **), (a), .help = (h) }
+#define OPT_STRING_NOEMPTY(s, l, v, a, h) { .type = OPTION_STRING, .short_name = (s), .long_name = (l), .value = check_vtype(v, const char **), (a), .help = (h), .flags = PARSE_OPT_NOEMPTY}
#define OPT_DATE(s, l, v, h) \
{ .type = OPTION_CALLBACK, .short_name = (s), .long_name = (l), .value = (v), .argh = "time", .help = (h), .callback = parse_opt_approxidate_cb }
#define OPT_CALLBACK(s, l, v, a, h, f) \
--
1.9.3
^ permalink raw reply related [flat|nested] 42+ messages in thread
* Re: [GIT PULL 00/31] perf/core improvements and fixes
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (29 preceding siblings ...)
2015-03-19 17:05 ` [PATCH 31/31] perf report: Don't allow empty argument for '-t' Arnaldo Carvalho de Melo
@ 2015-03-22 9:55 ` Ingo Molnar
30 siblings, 0 replies; 42+ messages in thread
From: Ingo Molnar @ 2015-03-22 9:55 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Adrian Hunter, Borislav Petkov, Corey Ashford,
David Ahern, Don Zickus, Frederic Weisbecker, H . J . Lu,
Jiri Olsa, Li Zefan, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, pi3orama, Stephane Eranian, Wang Nan,
Yunlong Song, Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling, more to come,
>
> - Arnaldo
>
> The following changes since commit 107eb964d8c04417e8bce9e9ec2ed61d9261aec6:
>
> Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2015-03-13 13:30:10 +0100)
>
> are available in the git repository at:
>
>
> git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-core-for-mingo
>
> for you to fetch changes up to 0c8c20779c5d56b93b8cb4cd30ba129a927ab437:
>
> perf report: Don't allow empty argument for '-t'. (2015-03-19 13:53:28 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> User visible:
>
> - Bash completion for subcommands (Yunlong Song)
>
> - Allow annotating entries in callchains in the hists browser (top/report).
> TODO: give some visual cue to what entries in callchains have samples and thus
> can be annotated and/or allow showing the source code for functions without
> samples (Arnaldo Carvalho de Melo)
>
> - Don't allow empty argument for '-t' in perf report, fixing segfault (Wang Nan)
>
> Infrastructure:
>
> - Prep work for moving the perf feature tests build system to tools/build (Jiri Olsa)
>
> - Fix perf-read-vdsox32 not building and lib64 install dir (H.J. Lu)
>
> - ARM64: fix building error and eh/debug frame offset cache fixes (Wang Nan)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Arnaldo Carvalho de Melo (4):
> perf hists browser: Simplify symbol annotation menu setup
> perf hists browser: Fix up some branch alignment
> perf hists: Remove hist_entry->used, not used anymore
> perf hists browser: Allow annotating entries in callchains
>
> H.J. Lu (1):
> perf tools: Fix perf-read-vdsox32 not building and lib64 install dir
>
> Jiri Olsa (10):
> perf build: Disable default check for libbabeltrace
> perf build: Move features build output under features directory
> perf build: Fix pthread-attr-setaffinity-np include in test-all
> perf build: Get rid of LIB_INCLUDE variable
> perf build: Rename CORE_FEATURE_TESTS to FEATURE_TESTS
> perf build: Get rid of VF_FEATURE_TESTS
> perf build: Rename display_lib into feature_display
> perf build: Rename display_vf to feature_verbose
> perf build: Rename PERF-FEATURES into FEATURE-DUMP
> perf build: Rename feature_print_var_code to print_var_code
>
> Wang Nan (3):
> perf tools: Fix building error for arm64.
> perf callchain: Separate eh/debug frame offset cache.
> perf report: Don't allow empty argument for '-t'.
>
> Yunlong Song (13):
> perf tools: Fix the bash completion for listing options of perf subcommand
> perf tools: Fix the bash completion for listing subsubcommands of perf subcommand
> perf tools: Provide the right bash completion for listing options of perf subcommand subsubcommand
> perf tools: Fix the bash completion for listing events of perf subcommand record|stat|top -e
> perf tools: Fix the bash completion to support listing events for --event
> perf tools: Fix the bash completion for listing subcommands of perf
> perf tools: Add the bash completion for listing subsubcommands of perf data
> perf tools: Add the bash completion for listing subsubcommands of perf help
> perf tools: Add the bash completion for listing subsubcommands of perf script
> perf tools: Add the bash completion for listing subsubcommands of perf test
> perf tools: Add the bash completion for listing subsubcommands of perf timechart
> perf tools: Add the bash completion for listing subsubcommands of perf trace
> perf tools: Avoid confusion with preloaded bash function for perf bash completion
>
> tools/perf/Makefile.perf | 3 +-
> tools/perf/builtin-data.c | 6 +-
> tools/perf/builtin-help.c | 17 ++++-
> tools/perf/builtin-report.c | 2 +-
> tools/perf/builtin-script.c | 5 +-
> tools/perf/builtin-timechart.c | 7 +-
> tools/perf/builtin-trace.c | 7 +-
> tools/perf/config/Makefile | 111 ++++++++++++----------------
> tools/perf/config/Makefile.arch | 2 +-
> tools/perf/config/feature-checks/Makefile | 7 +-
> tools/perf/config/feature-checks/test-all.c | 11 ++-
> tools/perf/perf-completion.sh | 88 +++++++++++++++++-----
> tools/perf/tests/builtin-test.c | 5 +-
> tools/perf/tests/make | 2 +-
> tools/perf/ui/browsers/annotate.c | 8 +-
> tools/perf/ui/browsers/hists.c | 59 +++++++--------
> tools/perf/util/dso.h | 3 +-
> tools/perf/util/hist.c | 8 +-
> tools/perf/util/hist.h | 9 +++
> tools/perf/util/parse-options.c | 21 +++++-
> tools/perf/util/parse-options.h | 2 +
> tools/perf/util/sort.h | 1 -
> tools/perf/util/unwind-libunwind.c | 8 +-
> 23 files changed, 237 insertions(+), 155 deletions(-)
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 42+ messages in thread
* Re: [PATCH 14/31] perf build: Rename PERF-FEATURES into FEATURE-DUMP
2015-03-19 17:04 ` [PATCH 14/31] perf build: Rename PERF-FEATURES into FEATURE-DUMP Arnaldo Carvalho de Melo
@ 2015-03-22 10:19 ` Ingo Molnar
2015-03-23 10:57 ` Jiri Olsa
2015-03-23 14:13 ` Arnaldo Carvalho de Melo
0 siblings, 2 replies; 42+ messages in thread
From: Ingo Molnar @ 2015-03-22 10:19 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> From: Jiri Olsa <jolsa@kernel.org>
>
> Preparing for feature checks separation, moving related stuff under
> 'FEATURE*' namespace.
>
> Signed-off-by: Jiri Olsa <jolsa@kernel.org>
> Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
> Cc: David Ahern <david.ahern@oracle.com>
> Cc: Namhyung Kim <namhyung@kernel.org>
> Cc: Paul Mackerras <paulus@samba.org>
> Cc: Peter Zijlstra <peterz@infradead.org>
> Link: http://lkml.kernel.org/n/tip-v9oo22ra70rrk1dy495a7bjc@git.kernel.org
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
So I think the various capital letter files in $(cwd) are highly
suboptimal:
FEATURE-DUMP
PERF-CFLAGS
PERF-VERSION-FILE
I think we should standardize on something less pushy (no shouting),
plus more standardized, more logical, more coherent names, i.e.
something like:
.build.features.cache
.build.cflags
.build.version
?
.build.features.* would be reserved to the generic feature detection
machinery.
.build.cflags and .build.version could be used by the perf build -
hopefully exported to tools/build/ as well in the future! :-)
That way the .gitignore could just ignore .build.* and we'd not have
to update it much.
Btw., another small nit: could we please do a (git-)rename of
tools/build/feature/ to tools/build/features/?
Plural is what is used typically for generic frameworks that deal with
a set of items (features in this case) - for example we have
tools/tests/, and tools/perf/scripts/, not tools/test/ and
tools/perf/script/.
Thanks,
Ingo
^ permalink raw reply [flat|nested] 42+ messages in thread
* Re: [PATCH 14/31] perf build: Rename PERF-FEATURES into FEATURE-DUMP
2015-03-22 10:19 ` Ingo Molnar
@ 2015-03-23 10:57 ` Jiri Olsa
2015-03-23 14:13 ` Arnaldo Carvalho de Melo
1 sibling, 0 replies; 42+ messages in thread
From: Jiri Olsa @ 2015-03-23 10:57 UTC (permalink / raw)
To: Ingo Molnar
Cc: Arnaldo Carvalho de Melo, linux-kernel, Jiri Olsa, Corey Ashford,
David Ahern, Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
On Sun, Mar 22, 2015 at 11:19:33AM +0100, Ingo Molnar wrote:
>
> * Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
>
> > From: Jiri Olsa <jolsa@kernel.org>
> >
> > Preparing for feature checks separation, moving related stuff under
> > 'FEATURE*' namespace.
> >
> > Signed-off-by: Jiri Olsa <jolsa@kernel.org>
> > Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
> > Cc: David Ahern <david.ahern@oracle.com>
> > Cc: Namhyung Kim <namhyung@kernel.org>
> > Cc: Paul Mackerras <paulus@samba.org>
> > Cc: Peter Zijlstra <peterz@infradead.org>
> > Link: http://lkml.kernel.org/n/tip-v9oo22ra70rrk1dy495a7bjc@git.kernel.org
> > Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> So I think the various capital letter files in $(cwd) are highly
> suboptimal:
>
> FEATURE-DUMP
> PERF-CFLAGS
> PERF-VERSION-FILE
we no longer have the PERF-CFLAGS file:
db8486626246 perf build: Remove PERF-CFLAGS file
forgot to update the .gitignore file, will do
> I think we should standardize on something less pushy (no shouting),
> plus more standardized, more logical, more coherent names, i.e.
> something like:
>
> .build.features.cache
> .build.cflags
> .build.version
>
> ?
>
> .build.features.* would be reserved to the generic feature detection
> machinery.
>
> .build.cflags and .build.version could be used by the perf build -
> hopefully exported to tools/build/ as well in the future! :-)
ok, noted ;-)
> That way the .gitignore could just ignore .build.* and we'd not have
> to update it much.
agreed
>
> Btw., another small nit: could we please do a (git-)rename of
> tools/build/feature/ to tools/build/features/?
>
> Plural is what is used typically for generic frameworks that deal with
> a set of items (features in this case) - for example we have
> tools/tests/, and tools/perf/scripts/, not tools/test/ and
> tools/perf/script/.
ok, I'll try to address all this in the next build update
jirka
^ permalink raw reply [flat|nested] 42+ messages in thread
* Re: [PATCH 14/31] perf build: Rename PERF-FEATURES into FEATURE-DUMP
2015-03-22 10:19 ` Ingo Molnar
2015-03-23 10:57 ` Jiri Olsa
@ 2015-03-23 14:13 ` Arnaldo Carvalho de Melo
1 sibling, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-03-23 14:13 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Namhyung Kim, Paul Mackerras, Peter Zijlstra
Em Sun, Mar 22, 2015 at 11:19:33AM +0100, Ingo Molnar escreveu:
>
> * Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
>
> > From: Jiri Olsa <jolsa@kernel.org>
> >
> > Preparing for feature checks separation, moving related stuff under
> > 'FEATURE*' namespace.
> >
> > Signed-off-by: Jiri Olsa <jolsa@kernel.org>
> > Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
> > Cc: David Ahern <david.ahern@oracle.com>
> > Cc: Namhyung Kim <namhyung@kernel.org>
> > Cc: Paul Mackerras <paulus@samba.org>
> > Cc: Peter Zijlstra <peterz@infradead.org>
> > Link: http://lkml.kernel.org/n/tip-v9oo22ra70rrk1dy495a7bjc@git.kernel.org
> > Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> So I think the various capital letter files in $(cwd) are highly
> suboptimal:
>
> FEATURE-DUMP
> PERF-CFLAGS
> PERF-VERSION-FILE
>
> I think we should standardize on something less pushy (no shouting),
> plus more standardized, more logical, more coherent names, i.e.
> something like:
>
> .build.features.cache
> .build.cflags
> .build.version
>
> ?
>
> .build.features.* would be reserved to the generic feature detection
> machinery.
>
> .build.cflags and .build.version could be used by the perf build -
> hopefully exported to tools/build/ as well in the future! :-)
>
> That way the .gitignore could just ignore .build.* and we'd not have
> to update it much.
Agreed, Jiri?
> Btw., another small nit: could we please do a (git-)rename of
> tools/build/feature/ to tools/build/features/?
> Plural is what is used typically for generic frameworks that deal with
> a set of items (features in this case) - for example we have
> tools/tests/, and tools/perf/scripts/, not tools/test/ and
> tools/perf/script/.
This one is easy enough, will do in my next pull req.
- Arnaldo
^ permalink raw reply [flat|nested] 42+ messages in thread
* [GIT PULL 00/31] perf/core improvements and fixes
@ 2018-03-13 12:04 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2018-03-13 12:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, linux-perf-users, Arnaldo Carvalho de Melo,
Adrian Hunter, Alexander Shishkin, Andi Kleen, Clark Williams,
Christian Hansen, David Ahern, Ganapatrao Kulkarni,
Heiko Carstens, Hendrik Brueckner, Jayachandran C, Jiri Olsa,
Joe Mario, John Garry, Kim Phillips, Leo Yan, linuxarm,
linux-arm-kernel, Mark Rutland, Martin Schwidefsky,
Martin Vuille, Namhyung Kim, Naveen N . Rao, Peter Zijlstra,
Robert Richter, Sandipan Das, Shaokun Zhang, Thomas Richter,
Wang Nan, Will Deacon, William Cohen, Yisheng Xie,
Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling,
- Arnaldo
Test results at the end of this message, as usual.
The following changes since commit 33801b94741d6c3be9713c10aa627477216c21e2:
perf/core: Fix installing cgroup events on CPU (2018-03-12 15:28:51 +0100)
are available in the Git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-core-for-mingo-4.17-20180313
for you to fetch changes up to 1b442ed71f0b32d07db03efba150d4592875f988:
perf test: Fix exit code for record+probe_libc_inet_pton.sh (2018-03-12 15:25:20 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
- Add support for pmu events vendor subdirectories, move vendor event
files (JSON format) to "arm" and "cavium" subdirectories (John Garry)
- Enable ThunderX2 B0 events in the "cavium" vendor event files (Ganapatrao Kulkarni)
- Show zero counters as well in 'perf report --stat' (Ingo Molnar)
- Record physical addresses in samples in 'perf c2c record', so that
the NUMA node can be displayed for cacheline addresses (Jiri Olsa)
- Fix kernel MMAP name setup when --vmlinux is used (Jiri Olsa)
- Display llvm eBPF compiling command in debug output (Jiri Olsa)
- Add libdw DWARF post unwind support for ARM64 (Jean Pihet, Kim Phillips)
- Unwind with libdw doesn't take symfs into account (Martin Vuille)
- Fix exit code for record+probe_libc_inet_pton.sh 'perf test' entry (Sandipan Das)
- Fix code dump when using transaction events with 'perf stat -T' (Thomas Richter)
- Do not call perf_dafault_config() twice in 'perf record' (Yisheng Xie)
- Fix top.call-graph config variable processing in 'perf top' (Yisheng Xie)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Ganapatrao Kulkarni (1):
perf vendor events arm64: Enable JSON events for ThunderX2 B0
Ingo Molnar (1):
perf report: Show zero counters as well in 'perf report --stat'
Jiri Olsa (11):
perf env: Free memory nodes data
perf tools: Add mem2node object
perf tests: Add mem2node object test
perf c2c record: Record physical addresses in samples
perf c2c report: Make calc_width work with struct c2c_hist_entry
perf c2c report: Call calc_width() only for displayed entries
perf c2c report: Display node for cacheline address
perf c2c report: Add span header over cacheline data
perf c2c report: Add cacheline address count column
perf llvm: Display eBPF compiling command in debug output
perf machine: Fix mmap name setup
John Garry (11):
perf vendor events: Drop incomplete multiple mapfile support
perf vendor events: Fix error code in json_events()
perf vendor events: Drop support for unused topic directories
perf vendor events: Add support for pmu events vendor subdirectory
perf vendor events arm64: Relocate ThunderX2 JSON to cavium subdirectory
perf vendor events arm64: Relocate Cortex A53 JSONs to arm subdirectory
perf vendor events: Add support for arch standard events
perf vendor events arm64: Add armv8-recommended.json
perf vendor events arm64: Fixup ThunderX2 to use recommended events
perf vendor events arm64: fixup A53 to use recommended events
perf vendor events arm64: add HiSilicon hip08 JSON file
Kim Phillips (1):
perf tools arm64: Add libdw DWARF post unwind support for ARM64
Martin Vuille (1):
perf unwind: Unwind with libdw doesn't take symfs into account
Sandipan Das (1):
perf test: Fix exit code for record+probe_libc_inet_pton.sh
Thomas Richter (2):
perf stat: Fix core dump when flag T is used
perf stat: Make function perf_stat_evsel_id_init static
Yisheng Xie (2):
perf record: Avoid duplicate call of perf_default_config()
perf top: Fix top.call-graph config option reading
tools/perf/Documentation/perf-c2c.txt | 2 +-
tools/perf/Makefile.config | 2 +-
tools/perf/arch/arm64/include/arch-tests.h | 12 +
tools/perf/arch/arm64/tests/Build | 2 +
tools/perf/arch/arm64/tests/arch-tests.c | 16 +
tools/perf/arch/arm64/util/Build | 1 +
tools/perf/arch/arm64/util/unwind-libdw.c | 60 +++
tools/perf/builtin-c2c.c | 223 +++++++++-
tools/perf/builtin-record.c | 8 +-
tools/perf/builtin-stat.c | 9 +-
tools/perf/builtin-top.c | 6 +-
tools/perf/pmu-events/Build | 2 +
tools/perf/pmu-events/README | 15 +-
.../arch/arm64/{ => arm}/cortex-a53/branch.json | 14 +-
.../pmu-events/arch/arm64/arm/cortex-a53/bus.json | 8 +
.../arch/arm64/arm/cortex-a53/cache.json | 27 ++
.../arch/arm64/{ => arm}/cortex-a53/memory.json | 14 +-
.../arch/arm64/arm/cortex-a53/other.json | 28 ++
.../arch/arm64/{ => arm}/cortex-a53/pipeline.json | 20 +-
.../pmu-events/arch/arm64/armv8-recommended.json | 452 +++++++++++++++++++++
.../arch/arm64/cavium/thunderx2-imp-def.json | 62 ---
.../arch/arm64/cavium/thunderx2/core-imp-def.json | 32 ++
.../perf/pmu-events/arch/arm64/cortex-a53/bus.json | 22 -
.../pmu-events/arch/arm64/cortex-a53/cache.json | 27 --
.../pmu-events/arch/arm64/cortex-a53/other.json | 32 --
.../arch/arm64/hisilicon/hip08/core-imp-def.json | 122 ++++++
tools/perf/pmu-events/arch/arm64/mapfile.csv | 6 +-
tools/perf/pmu-events/jevents.c | 288 ++++++++++---
tools/perf/tests/Build | 1 +
tools/perf/tests/builtin-test.c | 4 +
tools/perf/tests/mem2node.c | 75 ++++
.../tests/shell/record+probe_libc_inet_pton.sh | 5 +-
tools/perf/tests/tests.h | 1 +
tools/perf/ui/stdio/hist.c | 6 +-
tools/perf/util/Build | 1 +
tools/perf/util/env.c | 4 +
tools/perf/util/llvm-utils.c | 14 +
tools/perf/util/machine.c | 28 +-
tools/perf/util/mem2node.c | 134 ++++++
tools/perf/util/mem2node.h | 19 +
tools/perf/util/stat.c | 2 +-
tools/perf/util/stat.h | 2 -
tools/perf/util/unwind-libdw.c | 2 +-
43 files changed, 1533 insertions(+), 277 deletions(-)
create mode 100644 tools/perf/arch/arm64/include/arch-tests.h
create mode 100644 tools/perf/arch/arm64/tests/arch-tests.c
create mode 100644 tools/perf/arch/arm64/util/unwind-libdw.c
rename tools/perf/pmu-events/arch/arm64/{ => arm}/cortex-a53/branch.json (76%)
create mode 100644 tools/perf/pmu-events/arch/arm64/arm/cortex-a53/bus.json
create mode 100644 tools/perf/pmu-events/arch/arm64/arm/cortex-a53/cache.json
rename tools/perf/pmu-events/arch/arm64/{ => arm}/cortex-a53/memory.json (50%)
create mode 100644 tools/perf/pmu-events/arch/arm64/arm/cortex-a53/other.json
rename tools/perf/pmu-events/arch/arm64/{ => arm}/cortex-a53/pipeline.json (97%)
create mode 100644 tools/perf/pmu-events/arch/arm64/armv8-recommended.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cavium/thunderx2-imp-def.json
create mode 100644 tools/perf/pmu-events/arch/arm64/cavium/thunderx2/core-imp-def.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cortex-a53/bus.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cortex-a53/cache.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cortex-a53/other.json
create mode 100644 tools/perf/pmu-events/arch/arm64/hisilicon/hip08/core-imp-def.json
create mode 100644 tools/perf/tests/mem2node.c
create mode 100644 tools/perf/util/mem2node.c
create mode 100644 tools/perf/util/mem2node.h
Test results:
The first ones are container (docker) based builds of tools/perf with and
without libelf support. Where clang is available, it is also used to build
perf with/without libelf.
The objtool and samples/bpf/ builds are disabled now that I'm switching from
using the sources in a local volume to fetching them from a http server to
build it inside the container, to make it easier to build in a container cluster.
Those will come back later.
Several are cross builds, the ones with -x-ARCH and the android one, and those
may not have all the features built, due to lack of multi-arch devel packages,
available and being used so far on just a few, like
debian:experimental-x-{arm64,mipsel}.
The 'perf test' one will perform a variety of tests exercising
tools/perf/util/, tools/lib/{bpf,traceevent,etc}, as well as run perf commands
with a variety of command line event specifications to then intercept the
sys_perf_event syscall to check that the perf_event_attr fields are set up as
expected, among a variety of other unit tests.
Then there is the 'make -C tools/perf build-test' ones, that build tools/perf/
with a variety of feature sets, exercising the build with an incomplete set of
features as well as with a complete one. It is planned to have it run on each
of the containers mentioned above, using some container orchestration
infrastructure. Get in contact if interested in helping having this in place.
# dm
1 alpine:3.4 : Ok gcc (Alpine 5.3.0) 5.3.0
2 alpine:3.5 : Ok gcc (Alpine 6.2.1) 6.2.1 20160822
3 alpine:3.6 : Ok gcc (Alpine 6.3.0) 6.3.0
4 alpine:3.7 : Ok gcc (Alpine 6.4.0) 6.4.0
5 alpine:edge : Ok gcc (Alpine 6.4.0) 6.4.0
6 amazonlinux:1 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
7 amazonlinux:2 : Ok gcc (GCC) 7.2.1 20170915 (Red Hat 7.2.1-2)
8 android-ndk:r12b-arm : Ok arm-linux-androideabi-gcc (GCC) 4.9.x 20150123 (prerelease)
9 android-ndk:r15c-arm : Ok arm-linux-androideabi-gcc (GCC) 4.9.x 20150123 (prerelease)
10 centos:5 : Ok gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-55)
11 centos:6 : Ok gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-18)
12 centos:7 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-16)
13 debian:7 : Ok gcc (Debian 4.7.2-5) 4.7.2
14 debian:8 : Ok gcc (Debian 4.9.2-10+deb8u1) 4.9.2
15 debian:9 : Ok gcc (Debian 6.3.0-18) 6.3.0 20170516
16 debian:experimental : Ok gcc (Debian 7.2.0-17) 7.2.1 20171205
17 debian:experimental-x-arm64 : Ok aarch64-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
18 debian:experimental-x-mips : Ok mips-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
19 debian:experimental-x-mips64 : Ok mips64-linux-gnuabi64-gcc (Debian 7.2.0-11) 7.2.0
20 debian:experimental-x-mipsel : Ok mipsel-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
21 fedora:20 : Ok gcc (GCC) 4.8.3 20140911 (Red Hat 4.8.3-7)
22 fedora:21 : Ok gcc (GCC) 4.9.2 20150212 (Red Hat 4.9.2-6)
23 fedora:22 : Ok gcc (GCC) 5.3.1 20160406 (Red Hat 5.3.1-6)
24 fedora:23 : Ok gcc (GCC) 5.3.1 20160406 (Red Hat 5.3.1-6)
25 fedora:24 : Ok gcc (GCC) 6.3.1 20161221 (Red Hat 6.3.1-1)
26 fedora:24-x-ARC-uClibc : Ok arc-linux-gcc (ARCompact ISA Linux uClibc toolchain 2017.09-rc2) 7.1.1 20170710
27 fedora:25 : Ok gcc (GCC) 6.4.1 20170727 (Red Hat 6.4.1-1)
28 fedora:26 : Ok gcc (GCC) 7.2.1 20170915 (Red Hat 7.2.1-2)
29 fedora:27 : Ok gcc (GCC) 7.3.1 20180303 (Red Hat 7.3.1-5)
30 fedora:rawhide : Ok gcc (GCC) 7.2.1 20170829 (Red Hat 7.2.1-1)
31 gentoo-stage3-amd64:latest : Ok gcc (Gentoo 6.4.0-r1 p1.3) 6.4.0
32 mageia:5 : Ok gcc (GCC) 4.9.2
33 mageia:6 : Ok gcc (Mageia 5.4.0-5.mga6) 5.4.0
34 opensuse:42.1 : Ok gcc (SUSE Linux) 4.8.5
35 opensuse:42.2 : Ok gcc (SUSE Linux) 4.8.5
36 opensuse:42.3 : Ok gcc (SUSE Linux) 4.8.5
37 opensuse:tumbleweed : Ok gcc (SUSE Linux) 7.3.0
38 oraclelinux:6 : Ok gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-18)
39 oraclelinux:7 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-16)
40 ubuntu:12.04.5 : Ok gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
41 ubuntu:14.04.4 : Ok gcc (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4
42 ubuntu:14.04.4-x-linaro-arm64 : Ok aarch64-linux-gnu-gcc (Linaro GCC 5.4-2017.05) 5.4.1 20170404
43 ubuntu:15.04 : Ok gcc (Ubuntu 4.9.2-10ubuntu13) 4.9.2
44 ubuntu:16.04 : Ok gcc (Ubuntu 5.4.0-6ubuntu1~16.04.5) 5.4.0 20160609
45 ubuntu:16.04-x-arm : Ok arm-linux-gnueabihf-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
46 ubuntu:16.04-x-arm64 : Ok aarch64-linux-gnu-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
47 ubuntu:16.04-x-powerpc : Ok powerpc-linux-gnu-gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
48 ubuntu:16.04-x-powerpc64 : Ok powerpc64-linux-gnu-gcc (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.1) 5.4.0 20160609
49 ubuntu:16.04-x-powerpc64el : Ok powerpc64le-linux-gnu-gcc (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
50 ubuntu:16.04-x-s390 : Ok s390x-linux-gnu-gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
51 ubuntu:16.10 : Ok gcc (Ubuntu 6.2.0-5ubuntu12) 6.2.0 20161005
52 ubuntu:17.04 : Ok gcc (Ubuntu 6.3.0-12ubuntu2) 6.3.0 20170406
53 ubuntu:17.10 : Ok gcc (Ubuntu 7.2.0-8ubuntu3) 7.2.0
54 ubuntu:18.04 : Ok gcc (Ubuntu 7.2.0-16ubuntu1) 7.2.0
# uname -a
Linux jouet 4.16.0-rc4 #1 SMP Mon Mar 5 12:18:05 -03 2018 x86_64 x86_64 x86_64 GNU/Linux
# perf test
1: vmlinux symtab matches kallsyms : Ok
2: Detect openat syscall event : Ok
3: Detect openat syscall event on all cpus : Ok
4: Read samples using the mmap interface : Ok
5: Test data source output : Ok
6: Parse event definition strings : Ok
7: Simple expression parser : Ok
8: PERF_RECORD_* events & perf_sample fields : Ok
9: Parse perf pmu format : Ok
10: DSO data read : Ok
11: DSO data cache : Ok
12: DSO data reopen : Ok
13: Roundtrip evsel->name : Ok
14: Parse sched tracepoints fields : Ok
15: syscalls:sys_enter_openat event fields : Ok
16: Setup struct perf_event_attr : Ok
17: Match and link multiple hists : Ok
18: 'import perf' in python : Ok
19: Breakpoint overflow signal handler : Ok
20: Breakpoint overflow sampling : Ok
21: Number of exit events of a simple workload : Ok
22: Software clock events period values : Ok
23: Object code reading : Ok
24: Sample parsing : Ok
25: Use a dummy software event to keep tracking : Ok
26: Parse with no sample_id_all bit set : Ok
27: Filter hist entries : Ok
28: Lookup mmap thread : Ok
29: Share thread mg : Ok
30: Sort output of hist entries : Ok
31: Cumulate child hist entries : Ok
32: Track with sched_switch : Ok
33: Filter fds with revents mask in a fdarray : Ok
34: Add fd to a fdarray, making it autogrow : Ok
35: kmod_path__parse : Ok
36: Thread map : Ok
37: LLVM search and compile :
37.1: Basic BPF llvm compile : Ok
37.2: kbuild searching : Ok
37.3: Compile source for BPF prologue generation : Ok
37.4: Compile source for BPF relocation : Ok
38: Session topology : Ok
39: BPF filter :
39.1: Basic BPF filtering : Ok
39.2: BPF pinning : Ok
39.3: BPF prologue generation : Ok
39.4: BPF relocation checker : Ok
40: Synthesize thread map : Ok
41: Remove thread map : Ok
42: Synthesize cpu map : Ok
43: Synthesize stat config : Ok
44: Synthesize stat : Ok
45: Synthesize stat round : Ok
46: Synthesize attr update : Ok
47: Event times : Ok
48: Read backward ring buffer : Ok
49: Print cpu map : Ok
50: Probe SDT events : Ok
51: is_printable_array : Ok
52: Print bitmap : Ok
53: perf hooks : Ok
54: builtin clang support : Skip (not compiled in)
55: unit_number__scnprintf : Ok
56: mem2node : Ok
57: x86 rdpmc : Ok
58: Convert perf time to TSC : Ok
59: DWARF unwind : Ok
60: x86 instruction decoder - new instructions : Ok
61: Use vfs_getname probe to get syscall args filenames : Ok
62: Check open filename arg using perf trace + vfs_getname: Ok
63: probe libc's inet_pton & backtrace it with ping : Ok
64: Add vfs_getname probe to get syscall args filenames : Ok
#
$ make -C tools/perf build-test
make: Entering directory '/home/acme/git/perf/tools/perf'
- tarpkg: ./tests/perf-targz-src-pkg .
make_no_libperl_O: make NO_LIBPERL=1
make_no_newt_O: make NO_NEWT=1
make_debug_O: make DEBUG=1
make_with_clangllvm_O: make LIBCLANGLLVM=1
make_no_demangle_O: make NO_DEMANGLE=1
make_no_libelf_O: make NO_LIBELF=1
make_with_babeltrace_O: make LIBBABELTRACE=1
make_pure_O: make
make_no_libaudit_O: make NO_LIBAUDIT=1
make_no_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
make_perf_o_O: make perf.o
make_tags_O: make tags
make_no_libnuma_O: make NO_LIBNUMA=1
make_util_pmu_bison_o_O: make util/pmu-bison.o
make_install_prefix_O: make install prefix=/tmp/krava
make_no_libpython_O: make NO_LIBPYTHON=1
make_no_libunwind_O: make NO_LIBUNWIND=1
make_doc_O: make doc
make_minimal_O: make NO_LIBPERL=1 NO_LIBPYTHON=1 NO_NEWT=1 NO_GTK2=1 NO_DEMANGLE=1 NO_LIBELF=1 NO_LIBUNWIND=1 NO_BACKTRACE=1 NO_LIBNUMA=1 NO_LIBAUDIT=1 NO_LIBBIONIC=1 NO_LIBDW_DWARF_UNWIND=1 NO_AUXTRACE=1 NO_LIBBPF=1 NO_LIBCRYPTO=1 NO_SDT=1 NO_JVMTI=1
make_no_gtk2_O: make NO_GTK2=1
make_install_O: make install
make_install_bin_O: make install-bin
make_help_O: make help
make_static_O: make LDFLAGS=-static
make_no_auxtrace_O: make NO_AUXTRACE=1
make_no_backtrace_O: make NO_BACKTRACE=1
make_install_prefix_slash_O: make install prefix=/tmp/krava/
make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
make_no_slang_O: make NO_SLANG=1
make_util_map_o_O: make util/map.o
make_no_libbionic_O: make NO_LIBBIONIC=1
make_no_libbpf_O: make NO_LIBBPF=1
make_clean_all_O: make clean all
OK
make: Leaving directory '/home/acme/git/perf/tools/perf'
$
^ permalink raw reply [flat|nested] 42+ messages in thread
* [GIT PULL 00/31] perf/core improvements and fixes
@ 2018-03-13 12:04 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2018-03-13 12:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, linux-perf-users, Arnaldo Carvalho de Melo,
Adrian Hunter, Alexander Shishkin, Andi Kleen, Clark Williams,
Christian Hansen, David Ahern, Ganapatrao Kulkarni,
Heiko Carstens, Hendrik Brueckner, Jayachandran C, Jiri Olsa,
Joe Mario, John Garry, Kim Phillips, Leo Yan, linuxarm,
linux-arm-kernel
Hi Ingo,
Please consider pulling,
- Arnaldo
Test results at the end of this message, as usual.
The following changes since commit 33801b94741d6c3be9713c10aa627477216c21e2:
perf/core: Fix installing cgroup events on CPU (2018-03-12 15:28:51 +0100)
are available in the Git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-core-for-mingo-4.17-20180313
for you to fetch changes up to 1b442ed71f0b32d07db03efba150d4592875f988:
perf test: Fix exit code for record+probe_libc_inet_pton.sh (2018-03-12 15:25:20 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
- Add support for pmu events vendor subdirectories, move vendor event
files (JSON format) to "arm" and "cavium" subdirectories (John Garry)
- Enable ThunderX2 B0 events in the "cavium" vendor event files (Ganapatrao Kulkarni)
- Show zero counters as well in 'perf report --stat' (Ingo Molnar)
- Record physical addresses in samples in 'perf c2c record', so that
the NUMA node can be displayed for cacheline addresses (Jiri Olsa)
- Fix kernel MMAP name setup when --vmlinux is used (Jiri Olsa)
- Display llvm eBPF compiling command in debug output (Jiri Olsa)
- Add libdw DWARF post unwind support for ARM64 (Jean Pihet, Kim Phillips)
- Unwind with libdw doesn't take symfs into account (Martin Vuille)
- Fix exit code for record+probe_libc_inet_pton.sh 'perf test' entry (Sandipan Das)
- Fix code dump when using transaction events with 'perf stat -T' (Thomas Richter)
- Do not call perf_dafault_config() twice in 'perf record' (Yisheng Xie)
- Fix top.call-graph config variable processing in 'perf top' (Yisheng Xie)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Ganapatrao Kulkarni (1):
perf vendor events arm64: Enable JSON events for ThunderX2 B0
Ingo Molnar (1):
perf report: Show zero counters as well in 'perf report --stat'
Jiri Olsa (11):
perf env: Free memory nodes data
perf tools: Add mem2node object
perf tests: Add mem2node object test
perf c2c record: Record physical addresses in samples
perf c2c report: Make calc_width work with struct c2c_hist_entry
perf c2c report: Call calc_width() only for displayed entries
perf c2c report: Display node for cacheline address
perf c2c report: Add span header over cacheline data
perf c2c report: Add cacheline address count column
perf llvm: Display eBPF compiling command in debug output
perf machine: Fix mmap name setup
John Garry (11):
perf vendor events: Drop incomplete multiple mapfile support
perf vendor events: Fix error code in json_events()
perf vendor events: Drop support for unused topic directories
perf vendor events: Add support for pmu events vendor subdirectory
perf vendor events arm64: Relocate ThunderX2 JSON to cavium subdirectory
perf vendor events arm64: Relocate Cortex A53 JSONs to arm subdirectory
perf vendor events: Add support for arch standard events
perf vendor events arm64: Add armv8-recommended.json
perf vendor events arm64: Fixup ThunderX2 to use recommended events
perf vendor events arm64: fixup A53 to use recommended events
perf vendor events arm64: add HiSilicon hip08 JSON file
Kim Phillips (1):
perf tools arm64: Add libdw DWARF post unwind support for ARM64
Martin Vuille (1):
perf unwind: Unwind with libdw doesn't take symfs into account
Sandipan Das (1):
perf test: Fix exit code for record+probe_libc_inet_pton.sh
Thomas Richter (2):
perf stat: Fix core dump when flag T is used
perf stat: Make function perf_stat_evsel_id_init static
Yisheng Xie (2):
perf record: Avoid duplicate call of perf_default_config()
perf top: Fix top.call-graph config option reading
tools/perf/Documentation/perf-c2c.txt | 2 +-
tools/perf/Makefile.config | 2 +-
tools/perf/arch/arm64/include/arch-tests.h | 12 +
tools/perf/arch/arm64/tests/Build | 2 +
tools/perf/arch/arm64/tests/arch-tests.c | 16 +
tools/perf/arch/arm64/util/Build | 1 +
tools/perf/arch/arm64/util/unwind-libdw.c | 60 +++
tools/perf/builtin-c2c.c | 223 +++++++++-
tools/perf/builtin-record.c | 8 +-
tools/perf/builtin-stat.c | 9 +-
tools/perf/builtin-top.c | 6 +-
tools/perf/pmu-events/Build | 2 +
tools/perf/pmu-events/README | 15 +-
.../arch/arm64/{ => arm}/cortex-a53/branch.json | 14 +-
.../pmu-events/arch/arm64/arm/cortex-a53/bus.json | 8 +
.../arch/arm64/arm/cortex-a53/cache.json | 27 ++
.../arch/arm64/{ => arm}/cortex-a53/memory.json | 14 +-
.../arch/arm64/arm/cortex-a53/other.json | 28 ++
.../arch/arm64/{ => arm}/cortex-a53/pipeline.json | 20 +-
.../pmu-events/arch/arm64/armv8-recommended.json | 452 +++++++++++++++++++++
.../arch/arm64/cavium/thunderx2-imp-def.json | 62 ---
.../arch/arm64/cavium/thunderx2/core-imp-def.json | 32 ++
.../perf/pmu-events/arch/arm64/cortex-a53/bus.json | 22 -
.../pmu-events/arch/arm64/cortex-a53/cache.json | 27 --
.../pmu-events/arch/arm64/cortex-a53/other.json | 32 --
.../arch/arm64/hisilicon/hip08/core-imp-def.json | 122 ++++++
tools/perf/pmu-events/arch/arm64/mapfile.csv | 6 +-
tools/perf/pmu-events/jevents.c | 288 ++++++++++---
tools/perf/tests/Build | 1 +
tools/perf/tests/builtin-test.c | 4 +
tools/perf/tests/mem2node.c | 75 ++++
.../tests/shell/record+probe_libc_inet_pton.sh | 5 +-
tools/perf/tests/tests.h | 1 +
tools/perf/ui/stdio/hist.c | 6 +-
tools/perf/util/Build | 1 +
tools/perf/util/env.c | 4 +
tools/perf/util/llvm-utils.c | 14 +
tools/perf/util/machine.c | 28 +-
tools/perf/util/mem2node.c | 134 ++++++
tools/perf/util/mem2node.h | 19 +
tools/perf/util/stat.c | 2 +-
tools/perf/util/stat.h | 2 -
tools/perf/util/unwind-libdw.c | 2 +-
43 files changed, 1533 insertions(+), 277 deletions(-)
create mode 100644 tools/perf/arch/arm64/include/arch-tests.h
create mode 100644 tools/perf/arch/arm64/tests/arch-tests.c
create mode 100644 tools/perf/arch/arm64/util/unwind-libdw.c
rename tools/perf/pmu-events/arch/arm64/{ => arm}/cortex-a53/branch.json (76%)
create mode 100644 tools/perf/pmu-events/arch/arm64/arm/cortex-a53/bus.json
create mode 100644 tools/perf/pmu-events/arch/arm64/arm/cortex-a53/cache.json
rename tools/perf/pmu-events/arch/arm64/{ => arm}/cortex-a53/memory.json (50%)
create mode 100644 tools/perf/pmu-events/arch/arm64/arm/cortex-a53/other.json
rename tools/perf/pmu-events/arch/arm64/{ => arm}/cortex-a53/pipeline.json (97%)
create mode 100644 tools/perf/pmu-events/arch/arm64/armv8-recommended.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cavium/thunderx2-imp-def.json
create mode 100644 tools/perf/pmu-events/arch/arm64/cavium/thunderx2/core-imp-def.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cortex-a53/bus.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cortex-a53/cache.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cortex-a53/other.json
create mode 100644 tools/perf/pmu-events/arch/arm64/hisilicon/hip08/core-imp-def.json
create mode 100644 tools/perf/tests/mem2node.c
create mode 100644 tools/perf/util/mem2node.c
create mode 100644 tools/perf/util/mem2node.h
Test results:
The first ones are container (docker) based builds of tools/perf with and
without libelf support. Where clang is available, it is also used to build
perf with/without libelf.
The objtool and samples/bpf/ builds are disabled now that I'm switching from
using the sources in a local volume to fetching them from a http server to
build it inside the container, to make it easier to build in a container cluster.
Those will come back later.
Several are cross builds, the ones with -x-ARCH and the android one, and those
may not have all the features built, due to lack of multi-arch devel packages,
available and being used so far on just a few, like
debian:experimental-x-{arm64,mipsel}.
The 'perf test' one will perform a variety of tests exercising
tools/perf/util/, tools/lib/{bpf,traceevent,etc}, as well as run perf commands
with a variety of command line event specifications to then intercept the
sys_perf_event syscall to check that the perf_event_attr fields are set up as
expected, among a variety of other unit tests.
Then there is the 'make -C tools/perf build-test' ones, that build tools/perf/
with a variety of feature sets, exercising the build with an incomplete set of
features as well as with a complete one. It is planned to have it run on each
of the containers mentioned above, using some container orchestration
infrastructure. Get in contact if interested in helping having this in place.
# dm
1 alpine:3.4 : Ok gcc (Alpine 5.3.0) 5.3.0
2 alpine:3.5 : Ok gcc (Alpine 6.2.1) 6.2.1 20160822
3 alpine:3.6 : Ok gcc (Alpine 6.3.0) 6.3.0
4 alpine:3.7 : Ok gcc (Alpine 6.4.0) 6.4.0
5 alpine:edge : Ok gcc (Alpine 6.4.0) 6.4.0
6 amazonlinux:1 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
7 amazonlinux:2 : Ok gcc (GCC) 7.2.1 20170915 (Red Hat 7.2.1-2)
8 android-ndk:r12b-arm : Ok arm-linux-androideabi-gcc (GCC) 4.9.x 20150123 (prerelease)
9 android-ndk:r15c-arm : Ok arm-linux-androideabi-gcc (GCC) 4.9.x 20150123 (prerelease)
10 centos:5 : Ok gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-55)
11 centos:6 : Ok gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-18)
12 centos:7 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-16)
13 debian:7 : Ok gcc (Debian 4.7.2-5) 4.7.2
14 debian:8 : Ok gcc (Debian 4.9.2-10+deb8u1) 4.9.2
15 debian:9 : Ok gcc (Debian 6.3.0-18) 6.3.0 20170516
16 debian:experimental : Ok gcc (Debian 7.2.0-17) 7.2.1 20171205
17 debian:experimental-x-arm64 : Ok aarch64-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
18 debian:experimental-x-mips : Ok mips-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
19 debian:experimental-x-mips64 : Ok mips64-linux-gnuabi64-gcc (Debian 7.2.0-11) 7.2.0
20 debian:experimental-x-mipsel : Ok mipsel-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
21 fedora:20 : Ok gcc (GCC) 4.8.3 20140911 (Red Hat 4.8.3-7)
22 fedora:21 : Ok gcc (GCC) 4.9.2 20150212 (Red Hat 4.9.2-6)
23 fedora:22 : Ok gcc (GCC) 5.3.1 20160406 (Red Hat 5.3.1-6)
24 fedora:23 : Ok gcc (GCC) 5.3.1 20160406 (Red Hat 5.3.1-6)
25 fedora:24 : Ok gcc (GCC) 6.3.1 20161221 (Red Hat 6.3.1-1)
26 fedora:24-x-ARC-uClibc : Ok arc-linux-gcc (ARCompact ISA Linux uClibc toolchain 2017.09-rc2) 7.1.1 20170710
27 fedora:25 : Ok gcc (GCC) 6.4.1 20170727 (Red Hat 6.4.1-1)
28 fedora:26 : Ok gcc (GCC) 7.2.1 20170915 (Red Hat 7.2.1-2)
29 fedora:27 : Ok gcc (GCC) 7.3.1 20180303 (Red Hat 7.3.1-5)
30 fedora:rawhide : Ok gcc (GCC) 7.2.1 20170829 (Red Hat 7.2.1-1)
31 gentoo-stage3-amd64:latest : Ok gcc (Gentoo 6.4.0-r1 p1.3) 6.4.0
32 mageia:5 : Ok gcc (GCC) 4.9.2
33 mageia:6 : Ok gcc (Mageia 5.4.0-5.mga6) 5.4.0
34 opensuse:42.1 : Ok gcc (SUSE Linux) 4.8.5
35 opensuse:42.2 : Ok gcc (SUSE Linux) 4.8.5
36 opensuse:42.3 : Ok gcc (SUSE Linux) 4.8.5
37 opensuse:tumbleweed : Ok gcc (SUSE Linux) 7.3.0
38 oraclelinux:6 : Ok gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-18)
39 oraclelinux:7 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-16)
40 ubuntu:12.04.5 : Ok gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
41 ubuntu:14.04.4 : Ok gcc (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4
42 ubuntu:14.04.4-x-linaro-arm64 : Ok aarch64-linux-gnu-gcc (Linaro GCC 5.4-2017.05) 5.4.1 20170404
43 ubuntu:15.04 : Ok gcc (Ubuntu 4.9.2-10ubuntu13) 4.9.2
44 ubuntu:16.04 : Ok gcc (Ubuntu 5.4.0-6ubuntu1~16.04.5) 5.4.0 20160609
45 ubuntu:16.04-x-arm : Ok arm-linux-gnueabihf-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
46 ubuntu:16.04-x-arm64 : Ok aarch64-linux-gnu-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
47 ubuntu:16.04-x-powerpc : Ok powerpc-linux-gnu-gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
48 ubuntu:16.04-x-powerpc64 : Ok powerpc64-linux-gnu-gcc (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.1) 5.4.0 20160609
49 ubuntu:16.04-x-powerpc64el : Ok powerpc64le-linux-gnu-gcc (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
50 ubuntu:16.04-x-s390 : Ok s390x-linux-gnu-gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
51 ubuntu:16.10 : Ok gcc (Ubuntu 6.2.0-5ubuntu12) 6.2.0 20161005
52 ubuntu:17.04 : Ok gcc (Ubuntu 6.3.0-12ubuntu2) 6.3.0 20170406
53 ubuntu:17.10 : Ok gcc (Ubuntu 7.2.0-8ubuntu3) 7.2.0
54 ubuntu:18.04 : Ok gcc (Ubuntu 7.2.0-16ubuntu1) 7.2.0
# uname -a
Linux jouet 4.16.0-rc4 #1 SMP Mon Mar 5 12:18:05 -03 2018 x86_64 x86_64 x86_64 GNU/Linux
# perf test
1: vmlinux symtab matches kallsyms : Ok
2: Detect openat syscall event : Ok
3: Detect openat syscall event on all cpus : Ok
4: Read samples using the mmap interface : Ok
5: Test data source output : Ok
6: Parse event definition strings : Ok
7: Simple expression parser : Ok
8: PERF_RECORD_* events & perf_sample fields : Ok
9: Parse perf pmu format : Ok
10: DSO data read : Ok
11: DSO data cache : Ok
12: DSO data reopen : Ok
13: Roundtrip evsel->name : Ok
14: Parse sched tracepoints fields : Ok
15: syscalls:sys_enter_openat event fields : Ok
16: Setup struct perf_event_attr : Ok
17: Match and link multiple hists : Ok
18: 'import perf' in python : Ok
19: Breakpoint overflow signal handler : Ok
20: Breakpoint overflow sampling : Ok
21: Number of exit events of a simple workload : Ok
22: Software clock events period values : Ok
23: Object code reading : Ok
24: Sample parsing : Ok
25: Use a dummy software event to keep tracking : Ok
26: Parse with no sample_id_all bit set : Ok
27: Filter hist entries : Ok
28: Lookup mmap thread : Ok
29: Share thread mg : Ok
30: Sort output of hist entries : Ok
31: Cumulate child hist entries : Ok
32: Track with sched_switch : Ok
33: Filter fds with revents mask in a fdarray : Ok
34: Add fd to a fdarray, making it autogrow : Ok
35: kmod_path__parse : Ok
36: Thread map : Ok
37: LLVM search and compile :
37.1: Basic BPF llvm compile : Ok
37.2: kbuild searching : Ok
37.3: Compile source for BPF prologue generation : Ok
37.4: Compile source for BPF relocation : Ok
38: Session topology : Ok
39: BPF filter :
39.1: Basic BPF filtering : Ok
39.2: BPF pinning : Ok
39.3: BPF prologue generation : Ok
39.4: BPF relocation checker : Ok
40: Synthesize thread map : Ok
41: Remove thread map : Ok
42: Synthesize cpu map : Ok
43: Synthesize stat config : Ok
44: Synthesize stat : Ok
45: Synthesize stat round : Ok
46: Synthesize attr update : Ok
47: Event times : Ok
48: Read backward ring buffer : Ok
49: Print cpu map : Ok
50: Probe SDT events : Ok
51: is_printable_array : Ok
52: Print bitmap : Ok
53: perf hooks : Ok
54: builtin clang support : Skip (not compiled in)
55: unit_number__scnprintf : Ok
56: mem2node : Ok
57: x86 rdpmc : Ok
58: Convert perf time to TSC : Ok
59: DWARF unwind : Ok
60: x86 instruction decoder - new instructions : Ok
61: Use vfs_getname probe to get syscall args filenames : Ok
62: Check open filename arg using perf trace + vfs_getname: Ok
63: probe libc's inet_pton & backtrace it with ping : Ok
64: Add vfs_getname probe to get syscall args filenames : Ok
#
$ make -C tools/perf build-test
make: Entering directory '/home/acme/git/perf/tools/perf'
- tarpkg: ./tests/perf-targz-src-pkg .
make_no_libperl_O: make NO_LIBPERL=1
make_no_newt_O: make NO_NEWT=1
make_debug_O: make DEBUG=1
make_with_clangllvm_O: make LIBCLANGLLVM=1
make_no_demangle_O: make NO_DEMANGLE=1
make_no_libelf_O: make NO_LIBELF=1
make_with_babeltrace_O: make LIBBABELTRACE=1
make_pure_O: make
make_no_libaudit_O: make NO_LIBAUDIT=1
make_no_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
make_perf_o_O: make perf.o
make_tags_O: make tags
make_no_libnuma_O: make NO_LIBNUMA=1
make_util_pmu_bison_o_O: make util/pmu-bison.o
make_install_prefix_O: make install prefix=/tmp/krava
make_no_libpython_O: make NO_LIBPYTHON=1
make_no_libunwind_O: make NO_LIBUNWIND=1
make_doc_O: make doc
make_minimal_O: make NO_LIBPERL=1 NO_LIBPYTHON=1 NO_NEWT=1 NO_GTK2=1 NO_DEMANGLE=1 NO_LIBELF=1 NO_LIBUNWIND=1 NO_BACKTRACE=1 NO_LIBNUMA=1 NO_LIBAUDIT=1 NO_LIBBIONIC=1 NO_LIBDW_DWARF_UNWIND=1 NO_AUXTRACE=1 NO_LIBBPF=1 NO_LIBCRYPTO=1 NO_SDT=1 NO_JVMTI=1
make_no_gtk2_O: make NO_GTK2=1
make_install_O: make install
make_install_bin_O: make install-bin
make_help_O: make help
make_static_O: make LDFLAGS=-static
make_no_auxtrace_O: make NO_AUXTRACE=1
make_no_backtrace_O: make NO_BACKTRACE=1
make_install_prefix_slash_O: make install prefix=/tmp/krava/
make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
make_no_slang_O: make NO_SLANG=1
make_util_map_o_O: make util/map.o
make_no_libbionic_O: make NO_LIBBIONIC=1
make_no_libbpf_O: make NO_LIBBPF=1
make_clean_all_O: make clean all
OK
make: Leaving directory '/home/acme/git/perf/tools/perf'
$
^ permalink raw reply [flat|nested] 42+ messages in thread
* [GIT PULL 00/31] perf/core improvements and fixes
@ 2018-03-13 12:04 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2018-03-13 12:04 UTC (permalink / raw)
To: linux-arm-kernel
Hi Ingo,
Please consider pulling,
- Arnaldo
Test results at the end of this message, as usual.
The following changes since commit 33801b94741d6c3be9713c10aa627477216c21e2:
perf/core: Fix installing cgroup events on CPU (2018-03-12 15:28:51 +0100)
are available in the Git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-core-for-mingo-4.17-20180313
for you to fetch changes up to 1b442ed71f0b32d07db03efba150d4592875f988:
perf test: Fix exit code for record+probe_libc_inet_pton.sh (2018-03-12 15:25:20 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
- Add support for pmu events vendor subdirectories, move vendor event
files (JSON format) to "arm" and "cavium" subdirectories (John Garry)
- Enable ThunderX2 B0 events in the "cavium" vendor event files (Ganapatrao Kulkarni)
- Show zero counters as well in 'perf report --stat' (Ingo Molnar)
- Record physical addresses in samples in 'perf c2c record', so that
the NUMA node can be displayed for cacheline addresses (Jiri Olsa)
- Fix kernel MMAP name setup when --vmlinux is used (Jiri Olsa)
- Display llvm eBPF compiling command in debug output (Jiri Olsa)
- Add libdw DWARF post unwind support for ARM64 (Jean Pihet, Kim Phillips)
- Unwind with libdw doesn't take symfs into account (Martin Vuille)
- Fix exit code for record+probe_libc_inet_pton.sh 'perf test' entry (Sandipan Das)
- Fix code dump when using transaction events with 'perf stat -T' (Thomas Richter)
- Do not call perf_dafault_config() twice in 'perf record' (Yisheng Xie)
- Fix top.call-graph config variable processing in 'perf top' (Yisheng Xie)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Ganapatrao Kulkarni (1):
perf vendor events arm64: Enable JSON events for ThunderX2 B0
Ingo Molnar (1):
perf report: Show zero counters as well in 'perf report --stat'
Jiri Olsa (11):
perf env: Free memory nodes data
perf tools: Add mem2node object
perf tests: Add mem2node object test
perf c2c record: Record physical addresses in samples
perf c2c report: Make calc_width work with struct c2c_hist_entry
perf c2c report: Call calc_width() only for displayed entries
perf c2c report: Display node for cacheline address
perf c2c report: Add span header over cacheline data
perf c2c report: Add cacheline address count column
perf llvm: Display eBPF compiling command in debug output
perf machine: Fix mmap name setup
John Garry (11):
perf vendor events: Drop incomplete multiple mapfile support
perf vendor events: Fix error code in json_events()
perf vendor events: Drop support for unused topic directories
perf vendor events: Add support for pmu events vendor subdirectory
perf vendor events arm64: Relocate ThunderX2 JSON to cavium subdirectory
perf vendor events arm64: Relocate Cortex A53 JSONs to arm subdirectory
perf vendor events: Add support for arch standard events
perf vendor events arm64: Add armv8-recommended.json
perf vendor events arm64: Fixup ThunderX2 to use recommended events
perf vendor events arm64: fixup A53 to use recommended events
perf vendor events arm64: add HiSilicon hip08 JSON file
Kim Phillips (1):
perf tools arm64: Add libdw DWARF post unwind support for ARM64
Martin Vuille (1):
perf unwind: Unwind with libdw doesn't take symfs into account
Sandipan Das (1):
perf test: Fix exit code for record+probe_libc_inet_pton.sh
Thomas Richter (2):
perf stat: Fix core dump when flag T is used
perf stat: Make function perf_stat_evsel_id_init static
Yisheng Xie (2):
perf record: Avoid duplicate call of perf_default_config()
perf top: Fix top.call-graph config option reading
tools/perf/Documentation/perf-c2c.txt | 2 +-
tools/perf/Makefile.config | 2 +-
tools/perf/arch/arm64/include/arch-tests.h | 12 +
tools/perf/arch/arm64/tests/Build | 2 +
tools/perf/arch/arm64/tests/arch-tests.c | 16 +
tools/perf/arch/arm64/util/Build | 1 +
tools/perf/arch/arm64/util/unwind-libdw.c | 60 +++
tools/perf/builtin-c2c.c | 223 +++++++++-
tools/perf/builtin-record.c | 8 +-
tools/perf/builtin-stat.c | 9 +-
tools/perf/builtin-top.c | 6 +-
tools/perf/pmu-events/Build | 2 +
tools/perf/pmu-events/README | 15 +-
.../arch/arm64/{ => arm}/cortex-a53/branch.json | 14 +-
.../pmu-events/arch/arm64/arm/cortex-a53/bus.json | 8 +
.../arch/arm64/arm/cortex-a53/cache.json | 27 ++
.../arch/arm64/{ => arm}/cortex-a53/memory.json | 14 +-
.../arch/arm64/arm/cortex-a53/other.json | 28 ++
.../arch/arm64/{ => arm}/cortex-a53/pipeline.json | 20 +-
.../pmu-events/arch/arm64/armv8-recommended.json | 452 +++++++++++++++++++++
.../arch/arm64/cavium/thunderx2-imp-def.json | 62 ---
.../arch/arm64/cavium/thunderx2/core-imp-def.json | 32 ++
.../perf/pmu-events/arch/arm64/cortex-a53/bus.json | 22 -
.../pmu-events/arch/arm64/cortex-a53/cache.json | 27 --
.../pmu-events/arch/arm64/cortex-a53/other.json | 32 --
.../arch/arm64/hisilicon/hip08/core-imp-def.json | 122 ++++++
tools/perf/pmu-events/arch/arm64/mapfile.csv | 6 +-
tools/perf/pmu-events/jevents.c | 288 ++++++++++---
tools/perf/tests/Build | 1 +
tools/perf/tests/builtin-test.c | 4 +
tools/perf/tests/mem2node.c | 75 ++++
.../tests/shell/record+probe_libc_inet_pton.sh | 5 +-
tools/perf/tests/tests.h | 1 +
tools/perf/ui/stdio/hist.c | 6 +-
tools/perf/util/Build | 1 +
tools/perf/util/env.c | 4 +
tools/perf/util/llvm-utils.c | 14 +
tools/perf/util/machine.c | 28 +-
tools/perf/util/mem2node.c | 134 ++++++
tools/perf/util/mem2node.h | 19 +
tools/perf/util/stat.c | 2 +-
tools/perf/util/stat.h | 2 -
tools/perf/util/unwind-libdw.c | 2 +-
43 files changed, 1533 insertions(+), 277 deletions(-)
create mode 100644 tools/perf/arch/arm64/include/arch-tests.h
create mode 100644 tools/perf/arch/arm64/tests/arch-tests.c
create mode 100644 tools/perf/arch/arm64/util/unwind-libdw.c
rename tools/perf/pmu-events/arch/arm64/{ => arm}/cortex-a53/branch.json (76%)
create mode 100644 tools/perf/pmu-events/arch/arm64/arm/cortex-a53/bus.json
create mode 100644 tools/perf/pmu-events/arch/arm64/arm/cortex-a53/cache.json
rename tools/perf/pmu-events/arch/arm64/{ => arm}/cortex-a53/memory.json (50%)
create mode 100644 tools/perf/pmu-events/arch/arm64/arm/cortex-a53/other.json
rename tools/perf/pmu-events/arch/arm64/{ => arm}/cortex-a53/pipeline.json (97%)
create mode 100644 tools/perf/pmu-events/arch/arm64/armv8-recommended.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cavium/thunderx2-imp-def.json
create mode 100644 tools/perf/pmu-events/arch/arm64/cavium/thunderx2/core-imp-def.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cortex-a53/bus.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cortex-a53/cache.json
delete mode 100644 tools/perf/pmu-events/arch/arm64/cortex-a53/other.json
create mode 100644 tools/perf/pmu-events/arch/arm64/hisilicon/hip08/core-imp-def.json
create mode 100644 tools/perf/tests/mem2node.c
create mode 100644 tools/perf/util/mem2node.c
create mode 100644 tools/perf/util/mem2node.h
Test results:
The first ones are container (docker) based builds of tools/perf with and
without libelf support. Where clang is available, it is also used to build
perf with/without libelf.
The objtool and samples/bpf/ builds are disabled now that I'm switching from
using the sources in a local volume to fetching them from a http server to
build it inside the container, to make it easier to build in a container cluster.
Those will come back later.
Several are cross builds, the ones with -x-ARCH and the android one, and those
may not have all the features built, due to lack of multi-arch devel packages,
available and being used so far on just a few, like
debian:experimental-x-{arm64,mipsel}.
The 'perf test' one will perform a variety of tests exercising
tools/perf/util/, tools/lib/{bpf,traceevent,etc}, as well as run perf commands
with a variety of command line event specifications to then intercept the
sys_perf_event syscall to check that the perf_event_attr fields are set up as
expected, among a variety of other unit tests.
Then there is the 'make -C tools/perf build-test' ones, that build tools/perf/
with a variety of feature sets, exercising the build with an incomplete set of
features as well as with a complete one. It is planned to have it run on each
of the containers mentioned above, using some container orchestration
infrastructure. Get in contact if interested in helping having this in place.
# dm
1 alpine:3.4 : Ok gcc (Alpine 5.3.0) 5.3.0
2 alpine:3.5 : Ok gcc (Alpine 6.2.1) 6.2.1 20160822
3 alpine:3.6 : Ok gcc (Alpine 6.3.0) 6.3.0
4 alpine:3.7 : Ok gcc (Alpine 6.4.0) 6.4.0
5 alpine:edge : Ok gcc (Alpine 6.4.0) 6.4.0
6 amazonlinux:1 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-11)
7 amazonlinux:2 : Ok gcc (GCC) 7.2.1 20170915 (Red Hat 7.2.1-2)
8 android-ndk:r12b-arm : Ok arm-linux-androideabi-gcc (GCC) 4.9.x 20150123 (prerelease)
9 android-ndk:r15c-arm : Ok arm-linux-androideabi-gcc (GCC) 4.9.x 20150123 (prerelease)
10 centos:5 : Ok gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-55)
11 centos:6 : Ok gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-18)
12 centos:7 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-16)
13 debian:7 : Ok gcc (Debian 4.7.2-5) 4.7.2
14 debian:8 : Ok gcc (Debian 4.9.2-10+deb8u1) 4.9.2
15 debian:9 : Ok gcc (Debian 6.3.0-18) 6.3.0 20170516
16 debian:experimental : Ok gcc (Debian 7.2.0-17) 7.2.1 20171205
17 debian:experimental-x-arm64 : Ok aarch64-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
18 debian:experimental-x-mips : Ok mips-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
19 debian:experimental-x-mips64 : Ok mips64-linux-gnuabi64-gcc (Debian 7.2.0-11) 7.2.0
20 debian:experimental-x-mipsel : Ok mipsel-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
21 fedora:20 : Ok gcc (GCC) 4.8.3 20140911 (Red Hat 4.8.3-7)
22 fedora:21 : Ok gcc (GCC) 4.9.2 20150212 (Red Hat 4.9.2-6)
23 fedora:22 : Ok gcc (GCC) 5.3.1 20160406 (Red Hat 5.3.1-6)
24 fedora:23 : Ok gcc (GCC) 5.3.1 20160406 (Red Hat 5.3.1-6)
25 fedora:24 : Ok gcc (GCC) 6.3.1 20161221 (Red Hat 6.3.1-1)
26 fedora:24-x-ARC-uClibc : Ok arc-linux-gcc (ARCompact ISA Linux uClibc toolchain 2017.09-rc2) 7.1.1 20170710
27 fedora:25 : Ok gcc (GCC) 6.4.1 20170727 (Red Hat 6.4.1-1)
28 fedora:26 : Ok gcc (GCC) 7.2.1 20170915 (Red Hat 7.2.1-2)
29 fedora:27 : Ok gcc (GCC) 7.3.1 20180303 (Red Hat 7.3.1-5)
30 fedora:rawhide : Ok gcc (GCC) 7.2.1 20170829 (Red Hat 7.2.1-1)
31 gentoo-stage3-amd64:latest : Ok gcc (Gentoo 6.4.0-r1 p1.3) 6.4.0
32 mageia:5 : Ok gcc (GCC) 4.9.2
33 mageia:6 : Ok gcc (Mageia 5.4.0-5.mga6) 5.4.0
34 opensuse:42.1 : Ok gcc (SUSE Linux) 4.8.5
35 opensuse:42.2 : Ok gcc (SUSE Linux) 4.8.5
36 opensuse:42.3 : Ok gcc (SUSE Linux) 4.8.5
37 opensuse:tumbleweed : Ok gcc (SUSE Linux) 7.3.0
38 oraclelinux:6 : Ok gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-18)
39 oraclelinux:7 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-16)
40 ubuntu:12.04.5 : Ok gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
41 ubuntu:14.04.4 : Ok gcc (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4
42 ubuntu:14.04.4-x-linaro-arm64 : Ok aarch64-linux-gnu-gcc (Linaro GCC 5.4-2017.05) 5.4.1 20170404
43 ubuntu:15.04 : Ok gcc (Ubuntu 4.9.2-10ubuntu13) 4.9.2
44 ubuntu:16.04 : Ok gcc (Ubuntu 5.4.0-6ubuntu1~16.04.5) 5.4.0 20160609
45 ubuntu:16.04-x-arm : Ok arm-linux-gnueabihf-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
46 ubuntu:16.04-x-arm64 : Ok aarch64-linux-gnu-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
47 ubuntu:16.04-x-powerpc : Ok powerpc-linux-gnu-gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
48 ubuntu:16.04-x-powerpc64 : Ok powerpc64-linux-gnu-gcc (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.1) 5.4.0 20160609
49 ubuntu:16.04-x-powerpc64el : Ok powerpc64le-linux-gnu-gcc (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
50 ubuntu:16.04-x-s390 : Ok s390x-linux-gnu-gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
51 ubuntu:16.10 : Ok gcc (Ubuntu 6.2.0-5ubuntu12) 6.2.0 20161005
52 ubuntu:17.04 : Ok gcc (Ubuntu 6.3.0-12ubuntu2) 6.3.0 20170406
53 ubuntu:17.10 : Ok gcc (Ubuntu 7.2.0-8ubuntu3) 7.2.0
54 ubuntu:18.04 : Ok gcc (Ubuntu 7.2.0-16ubuntu1) 7.2.0
# uname -a
Linux jouet 4.16.0-rc4 #1 SMP Mon Mar 5 12:18:05 -03 2018 x86_64 x86_64 x86_64 GNU/Linux
# perf test
1: vmlinux symtab matches kallsyms : Ok
2: Detect openat syscall event : Ok
3: Detect openat syscall event on all cpus : Ok
4: Read samples using the mmap interface : Ok
5: Test data source output : Ok
6: Parse event definition strings : Ok
7: Simple expression parser : Ok
8: PERF_RECORD_* events & perf_sample fields : Ok
9: Parse perf pmu format : Ok
10: DSO data read : Ok
11: DSO data cache : Ok
12: DSO data reopen : Ok
13: Roundtrip evsel->name : Ok
14: Parse sched tracepoints fields : Ok
15: syscalls:sys_enter_openat event fields : Ok
16: Setup struct perf_event_attr : Ok
17: Match and link multiple hists : Ok
18: 'import perf' in python : Ok
19: Breakpoint overflow signal handler : Ok
20: Breakpoint overflow sampling : Ok
21: Number of exit events of a simple workload : Ok
22: Software clock events period values : Ok
23: Object code reading : Ok
24: Sample parsing : Ok
25: Use a dummy software event to keep tracking : Ok
26: Parse with no sample_id_all bit set : Ok
27: Filter hist entries : Ok
28: Lookup mmap thread : Ok
29: Share thread mg : Ok
30: Sort output of hist entries : Ok
31: Cumulate child hist entries : Ok
32: Track with sched_switch : Ok
33: Filter fds with revents mask in a fdarray : Ok
34: Add fd to a fdarray, making it autogrow : Ok
35: kmod_path__parse : Ok
36: Thread map : Ok
37: LLVM search and compile :
37.1: Basic BPF llvm compile : Ok
37.2: kbuild searching : Ok
37.3: Compile source for BPF prologue generation : Ok
37.4: Compile source for BPF relocation : Ok
38: Session topology : Ok
39: BPF filter :
39.1: Basic BPF filtering : Ok
39.2: BPF pinning : Ok
39.3: BPF prologue generation : Ok
39.4: BPF relocation checker : Ok
40: Synthesize thread map : Ok
41: Remove thread map : Ok
42: Synthesize cpu map : Ok
43: Synthesize stat config : Ok
44: Synthesize stat : Ok
45: Synthesize stat round : Ok
46: Synthesize attr update : Ok
47: Event times : Ok
48: Read backward ring buffer : Ok
49: Print cpu map : Ok
50: Probe SDT events : Ok
51: is_printable_array : Ok
52: Print bitmap : Ok
53: perf hooks : Ok
54: builtin clang support : Skip (not compiled in)
55: unit_number__scnprintf : Ok
56: mem2node : Ok
57: x86 rdpmc : Ok
58: Convert perf time to TSC : Ok
59: DWARF unwind : Ok
60: x86 instruction decoder - new instructions : Ok
61: Use vfs_getname probe to get syscall args filenames : Ok
62: Check open filename arg using perf trace + vfs_getname: Ok
63: probe libc's inet_pton & backtrace it with ping : Ok
64: Add vfs_getname probe to get syscall args filenames : Ok
#
$ make -C tools/perf build-test
make: Entering directory '/home/acme/git/perf/tools/perf'
- tarpkg: ./tests/perf-targz-src-pkg .
make_no_libperl_O: make NO_LIBPERL=1
make_no_newt_O: make NO_NEWT=1
make_debug_O: make DEBUG=1
make_with_clangllvm_O: make LIBCLANGLLVM=1
make_no_demangle_O: make NO_DEMANGLE=1
make_no_libelf_O: make NO_LIBELF=1
make_with_babeltrace_O: make LIBBABELTRACE=1
make_pure_O: make
make_no_libaudit_O: make NO_LIBAUDIT=1
make_no_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
make_perf_o_O: make perf.o
make_tags_O: make tags
make_no_libnuma_O: make NO_LIBNUMA=1
make_util_pmu_bison_o_O: make util/pmu-bison.o
make_install_prefix_O: make install prefix=/tmp/krava
make_no_libpython_O: make NO_LIBPYTHON=1
make_no_libunwind_O: make NO_LIBUNWIND=1
make_doc_O: make doc
make_minimal_O: make NO_LIBPERL=1 NO_LIBPYTHON=1 NO_NEWT=1 NO_GTK2=1 NO_DEMANGLE=1 NO_LIBELF=1 NO_LIBUNWIND=1 NO_BACKTRACE=1 NO_LIBNUMA=1 NO_LIBAUDIT=1 NO_LIBBIONIC=1 NO_LIBDW_DWARF_UNWIND=1 NO_AUXTRACE=1 NO_LIBBPF=1 NO_LIBCRYPTO=1 NO_SDT=1 NO_JVMTI=1
make_no_gtk2_O: make NO_GTK2=1
make_install_O: make install
make_install_bin_O: make install-bin
make_help_O: make help
make_static_O: make LDFLAGS=-static
make_no_auxtrace_O: make NO_AUXTRACE=1
make_no_backtrace_O: make NO_BACKTRACE=1
make_install_prefix_slash_O: make install prefix=/tmp/krava/
make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
make_no_slang_O: make NO_SLANG=1
make_util_map_o_O: make util/map.o
make_no_libbionic_O: make NO_LIBBIONIC=1
make_no_libbpf_O: make NO_LIBBPF=1
make_clean_all_O: make clean all
OK
make: Leaving directory '/home/acme/git/perf/tools/perf'
$
^ permalink raw reply [flat|nested] 42+ messages in thread
* Re: [GIT PULL 00/31] perf/core improvements and fixes
2016-02-25 1:57 Arnaldo Carvalho de Melo
@ 2016-02-25 7:22 ` Ingo Molnar
0 siblings, 0 replies; 42+ messages in thread
From: Ingo Molnar @ 2016-02-25 7:22 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Andi Kleen, Brendan Gregg, David Ahern, Jiri Olsa,
Li Zefan, Masami Hiramatsu, Namhyung Kim, Pekka Enberg,
Peter Zijlstra, pi3orama, Stephane Eranian, Wang Nan,
Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> The following changes since commit c2b8d8c55c0235e21c563283f634bcfd2ba7bc1e:
>
> Merge tag 'perf-core-for-mingo-2' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2016-02-24 08:20:30 +0100)
>
> are available in the git repository at:
>
> git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-core-for-mingo-20160224
>
> for you to fetch changes up to c92fcfde3486fb4b9e476ee5ad5995a62e401cce:
>
> perf top: Add --hierarchy option (2016-02-24 20:21:15 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements:
>
> User visible:
>
> - Hierarchy histogram mode for 'perf top' and 'perf report', showing multiple
> levels, one per --sort entry: (Namhyung Kim)
>
> On a mostly idle system:
>
> # perf top --hierarchy -s comm,dso
>
> Then expand some levels and use 'P' to take a snapshot:
>
> # cat perf.hist.0
> - 92.32% perf
> 58.20% perf
> 22.29% libc-2.22.so
> 5.97% [kernel]
> 4.18% libelf-0.165.so
> 1.69% [unknown]
> - 4.71% qemu-system-x86
> 3.10% [kernel]
> 1.60% qemu-system-x86_64 (deleted)
> + 2.97% swapper
> #
>
> - Check availability of memory events in 'perf mem': (Jiri Olsa)
>
> On a Intel Broadwell machine:
>
> # perf mem record -e list
> ldlat-loads : available
> ldlat-stores: available
> #
>
> - Decode data_src values (e.g. perf.data files generated by 'perf mem record')
> in 'perf script': (Jiri Olsa)
>
> # perf script
> perf 693 [1] 4.088652: 1 cpu/mem-loads,ldlat=30/P: ffff88007d0b0f40 68100142 L1 hit|SNP None|TLB L1 or L2 hit|LCK No <SNIP>
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> - Print bpf-output events in 'perf script': (Wang Nan).
>
> # perf record -e bpf-output/no-inherit,name=evt/ -e ./test_bpf_output_3.c/map:channel.event=evt/ usleep 1000
> # perf script
> usleep 4882 21384.532523: evt: ffffffff810e97d1 sys_nanosleep ([kernel.kallsyms])
> BPF output: 0000: 52 61 69 73 65 20 61 20 Raise a
> 0008: 42 50 46 20 65 76 65 6e BPF even
> 0010: 74 21 00 00 t!..
> BPF string: "Raise a BPF event!"
> #
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Jiri Olsa (11):
> perf mem record: Check for memory events support
> perf mem: Introduce perf_mem_events__name function
> perf tools: Introduce perf_mem__tlb_scnprintf function
> perf tools: Introduce perf_mem__lvl_scnprintf function
> perf tools: Introduce perf_mem__snp_scnprintf function
> perf tools: Introduce perf_mem__lck_scnprintf function
> perf tools: Change perf_mem__tlb_scnprintf to return nb of displayed bytes
> perf tools: Change perf_mem__lvl_scnprintf to return nb of displayed bytes
> perf tools: Change perf_mem__snp_scnprintf to return nb of displayed bytes
> perf tools: Change perf_mem__lck_scnprintf to return nb of displayed bytes
> perf script: Display data_src values
>
> Namhyung Kim (18):
> perf tools: Add helper functions for some sort keys
> perf hists: Basic support of hierarchical report view
> perf hists: Resort hist entries with hierarchy
> perf hists: Add helper functions for hierarchy mode
> perf hists: Introduce hist_entry__filter()
> perf hists: Support filtering in hierarchy mode
> perf hists: Resort after filtering hierarchy
> perf hists: Count number of sort keys
> perf ui/stdio: Implement hierarchy output mode
> perf ui/stdio: Align column header for hierarchy output
> perf hists browser: Count number of hierarchy entries
> perf hists browser: Support collapsing/expanding whole entries in hierarchy
> perf hists browser: Implement hierarchy output
> perf hists browser: Align column header in hierarchy mode
> perf ui/gtk: Implement hierarchy output mode
> perf report: Add --hierarchy option
> perf hists: Support decaying in hierarchy mode
> perf top: Add --hierarchy option
>
> Wang Nan (2):
> perf tools: Make binary data printer code in trace_event public available
> perf script: Print bpf-output events in 'perf script'
>
> tools/perf/Documentation/perf-report.txt | 3 +
> tools/perf/Documentation/perf-top.txt | 3 +
> tools/perf/Documentation/tips.txt | 1 +
> tools/perf/builtin-mem.c | 22 +-
> tools/perf/builtin-report.c | 17 ++
> tools/perf/builtin-script.c | 113 ++++++-
> tools/perf/builtin-top.c | 15 +
> tools/perf/ui/browsers/hists.c | 504 ++++++++++++++++++++++++++++---
> tools/perf/ui/gtk/hists.c | 163 +++++++++-
> tools/perf/ui/hist.c | 3 +
> tools/perf/ui/stdio/hist.c | 184 ++++++++++-
> tools/perf/util/ctype.c | 9 +
> tools/perf/util/debug.c | 75 +++--
> tools/perf/util/hist.c | 461 ++++++++++++++++++++++++++--
> tools/perf/util/hist.h | 24 ++
> tools/perf/util/mem-events.c | 210 ++++++++++++-
> tools/perf/util/mem-events.h | 13 +
> tools/perf/util/sort.c | 285 +++++++++--------
> tools/perf/util/sort.h | 14 +-
> tools/perf/util/symbol.h | 3 +-
> tools/perf/util/util.c | 37 +++
> tools/perf/util/util.h | 22 ++
> 22 files changed, 1940 insertions(+), 241 deletions(-)
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 42+ messages in thread
* [GIT PULL 00/31] perf/core improvements and fixes
@ 2016-02-25 1:57 Arnaldo Carvalho de Melo
2016-02-25 7:22 ` Ingo Molnar
0 siblings, 1 reply; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2016-02-25 1:57 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Andi Kleen,
Brendan Gregg, David Ahern, Jiri Olsa, Li Zefan,
Masami Hiramatsu, Namhyung Kim, Pekka Enberg, Peter Zijlstra,
pi3orama, Stephane Eranian, Wang Nan, Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit c2b8d8c55c0235e21c563283f634bcfd2ba7bc1e:
Merge tag 'perf-core-for-mingo-2' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2016-02-24 08:20:30 +0100)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-core-for-mingo-20160224
for you to fetch changes up to c92fcfde3486fb4b9e476ee5ad5995a62e401cce:
perf top: Add --hierarchy option (2016-02-24 20:21:15 -0300)
----------------------------------------------------------------
perf/core improvements:
User visible:
- Hierarchy histogram mode for 'perf top' and 'perf report', showing multiple
levels, one per --sort entry: (Namhyung Kim)
On a mostly idle system:
# perf top --hierarchy -s comm,dso
Then expand some levels and use 'P' to take a snapshot:
# cat perf.hist.0
- 92.32% perf
58.20% perf
22.29% libc-2.22.so
5.97% [kernel]
4.18% libelf-0.165.so
1.69% [unknown]
- 4.71% qemu-system-x86
3.10% [kernel]
1.60% qemu-system-x86_64 (deleted)
+ 2.97% swapper
#
- Check availability of memory events in 'perf mem': (Jiri Olsa)
On a Intel Broadwell machine:
# perf mem record -e list
ldlat-loads : available
ldlat-stores: available
#
- Decode data_src values (e.g. perf.data files generated by 'perf mem record')
in 'perf script': (Jiri Olsa)
# perf script
perf 693 [1] 4.088652: 1 cpu/mem-loads,ldlat=30/P: ffff88007d0b0f40 68100142 L1 hit|SNP None|TLB L1 or L2 hit|LCK No <SNIP>
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- Print bpf-output events in 'perf script': (Wang Nan).
# perf record -e bpf-output/no-inherit,name=evt/ -e ./test_bpf_output_3.c/map:channel.event=evt/ usleep 1000
# perf script
usleep 4882 21384.532523: evt: ffffffff810e97d1 sys_nanosleep ([kernel.kallsyms])
BPF output: 0000: 52 61 69 73 65 20 61 20 Raise a
0008: 42 50 46 20 65 76 65 6e BPF even
0010: 74 21 00 00 t!..
BPF string: "Raise a BPF event!"
#
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Jiri Olsa (11):
perf mem record: Check for memory events support
perf mem: Introduce perf_mem_events__name function
perf tools: Introduce perf_mem__tlb_scnprintf function
perf tools: Introduce perf_mem__lvl_scnprintf function
perf tools: Introduce perf_mem__snp_scnprintf function
perf tools: Introduce perf_mem__lck_scnprintf function
perf tools: Change perf_mem__tlb_scnprintf to return nb of displayed bytes
perf tools: Change perf_mem__lvl_scnprintf to return nb of displayed bytes
perf tools: Change perf_mem__snp_scnprintf to return nb of displayed bytes
perf tools: Change perf_mem__lck_scnprintf to return nb of displayed bytes
perf script: Display data_src values
Namhyung Kim (18):
perf tools: Add helper functions for some sort keys
perf hists: Basic support of hierarchical report view
perf hists: Resort hist entries with hierarchy
perf hists: Add helper functions for hierarchy mode
perf hists: Introduce hist_entry__filter()
perf hists: Support filtering in hierarchy mode
perf hists: Resort after filtering hierarchy
perf hists: Count number of sort keys
perf ui/stdio: Implement hierarchy output mode
perf ui/stdio: Align column header for hierarchy output
perf hists browser: Count number of hierarchy entries
perf hists browser: Support collapsing/expanding whole entries in hierarchy
perf hists browser: Implement hierarchy output
perf hists browser: Align column header in hierarchy mode
perf ui/gtk: Implement hierarchy output mode
perf report: Add --hierarchy option
perf hists: Support decaying in hierarchy mode
perf top: Add --hierarchy option
Wang Nan (2):
perf tools: Make binary data printer code in trace_event public available
perf script: Print bpf-output events in 'perf script'
tools/perf/Documentation/perf-report.txt | 3 +
tools/perf/Documentation/perf-top.txt | 3 +
tools/perf/Documentation/tips.txt | 1 +
tools/perf/builtin-mem.c | 22 +-
tools/perf/builtin-report.c | 17 ++
tools/perf/builtin-script.c | 113 ++++++-
tools/perf/builtin-top.c | 15 +
tools/perf/ui/browsers/hists.c | 504 ++++++++++++++++++++++++++++---
tools/perf/ui/gtk/hists.c | 163 +++++++++-
tools/perf/ui/hist.c | 3 +
tools/perf/ui/stdio/hist.c | 184 ++++++++++-
tools/perf/util/ctype.c | 9 +
tools/perf/util/debug.c | 75 +++--
tools/perf/util/hist.c | 461 ++++++++++++++++++++++++++--
tools/perf/util/hist.h | 24 ++
tools/perf/util/mem-events.c | 210 ++++++++++++-
tools/perf/util/mem-events.h | 13 +
tools/perf/util/sort.c | 285 +++++++++--------
tools/perf/util/sort.h | 14 +-
tools/perf/util/symbol.h | 3 +-
tools/perf/util/util.c | 37 +++
tools/perf/util/util.h | 22 ++
22 files changed, 1940 insertions(+), 241 deletions(-)
^ permalink raw reply [flat|nested] 42+ messages in thread
* Re: [GIT PULL 00/31] perf/core improvements and fixes
2015-09-04 16:44 Arnaldo Carvalho de Melo
@ 2015-09-08 14:24 ` Ingo Molnar
0 siblings, 0 replies; 42+ messages in thread
From: Ingo Molnar @ 2015-09-08 14:24 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Adrian Hunter, Alexei Starovoitov, Andi Kleen,
Andy Lutomirski, Borislav Petkov, Brendan Gregg, Daniel Borkmann,
Dave Hansen, David Ahern, Denys Vlasenko, Frederic Weisbecker,
He Kuang, H. Peter Anvin, Jiri Olsa, Kaixu Xia, Kan Liang,
Mark Rutland, Masami Hiramatsu, Matt Fleming, Namhyung Kim,
Paul Mackerras, Peter Zijlstra, pi3orama, Qiaowei Ren,
Raphael Beamonte, Stephane Eranian, Steven Rostedt,
Thomas Gleixner, Wang Nan, Zefan Li, Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> The following changes since commit 5b923564ccf43f92969c9e0fd199c8c5db657039:
>
> Merge tag 'perf-urgent-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/urgent (2015-09-02 09:22:53 +0200)
>
> are available in the git repository at:
>
> git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-core-for-mingo
>
> for you to fetch changes up to cf2f33a4e54096f90652cca3511fd6a456ea5abe:
>
> perf trace: Add read/write to the file group (2015-09-04 13:22:06 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> User visible:
>
> - Use PERF_RECORD_SWITCH when available in intel-pt, instead of
> "sched:sched_switch" events, enabling an unprivileged user to trace
> multi-threaded or multi-process workloads (Adrian Hunter)
>
> - Always use non inlined file name for 'srcfile' sort key (Andi Kleen)
>
> - Quieten failed to read counter message, helps in systems without
> backend-stalled-cycles (Andi Kleen)
>
> Infrastructure:
>
> - Add a 'perf test' entry for decoding of new x86 instructions (Adrian Hunter)
>
> - Add new instructions (sha, clflushopt, clwb, pcommit, rdpkru, wrpkru, xsavec,
> xsaves, xrstors) to the x86 instruction decoder (Adrian Hunter)
>
> - Add a build test to warn when source code drifts happen for the
> instruction decoder files in the kernel and in tools/perf (Adrian Hunter)
>
> - Copy linux/filter.h to tools/include (He Kuang)
>
> - Support function __get_dynamic_array_len in libtraceevent (He Kuanguuu)
>
> - Tracing path finding/mounting/error reporting refactorings (Jiri Olsa)
>
> - Store CPU socket and core IDs in perf.data (Kan Liang)
>
> - Reorganize add/del probe insertion routines in 'perf probe' (Namhyung Kim, Wang Nan)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Adrian Hunter (8):
> perf tools: Display build warning if x86 instruction decoder differs from kernel
> perf tools: Add a test for decoding of new x86 instructions
> x86/insn: perf tools: Pedantically tweak opcode map for MPX instructions
> x86/insn: perf tools: Add new SHA instructions
> x86/insn: perf tools: Add new memory instructions
> x86/insn: perf tools: Add new memory protection keys instructions
> x86/insn: perf tools: Add new xsave instructions
> perf intel-pt: Add support for PERF_RECORD_SWITCH
>
> Andi Kleen (2):
> perf tools: Always use non inlined file name for 'srcfile' sort key
> perf stat: Quieten failed to read counter message
>
> Arnaldo Carvalho de Melo (1):
> perf trace: Add read/write to the file group
>
> He Kuang (2):
> perf tools: Copy linux/filter.h to tools/include
> tools lib traceevent: Support function __get_dynamic_array_len
>
> Jiri Olsa (10):
> perf tools: Remove mountpoint arg from perf_debugfs_mount
> perf tools: Move tracing_path stuff under same namespace
> tools lib api fs: Move tracing_path interface into api/fs/tracing_path.c
> tools lib api fs: Move debugfs__strerror_open into tracing_path.c object
> tools lib api fs: Add STR and PATH_MAX macros to fs object
> tools lib api fs: Move SYSFS_MAGIC PROC_SUPER_MAGIC into fs.c
> tools lib api fs: Add debugfs into fs.c object
> tools lib api fs: Add tracefs into fs.c object
> tools lib api fs: Add FSTYPE__mount() method
> tools lib api fs: Add FSTYPE__configured() method
>
> Kan Liang (3):
> perf cpumap: Factor out functions to get core_id and socket_id
> perf tools: Store the cpu socket and core ids in the perf.data header
> perf session: Don't call dump_sample() when evsel is NULL
>
> Namhyung Kim (4):
> perf probe: Split add_perf_probe_events()
> perf probe: Move print logic into cmd_probe()
> perf probe: Split del_perf_probe_events()
> perf probe: Print deleted events in cmd_probe()
>
> Wang Nan (1):
> perf probe: Link trace_probe_event into perf_probe_event
>
> arch/x86/lib/x86-opcode-map.txt | 24 +-
> tools/include/linux/filter.h | 231 ++++++
> tools/lib/api/fs/Build | 1 +
> tools/lib/api/fs/debugfs.c | 52 --
> tools/lib/api/fs/fs.c | 117 ++-
> tools/lib/api/fs/fs.h | 26 +-
> tools/lib/api/fs/tracing_path.c | 137 ++++
> tools/lib/api/fs/tracing_path.h | 16 +
> tools/lib/traceevent/event-parse.c | 56 +-
> tools/lib/traceevent/event-parse.h | 1 +
> tools/perf/MANIFEST | 1 +
> tools/perf/arch/x86/util/intel-pt.c | 55 +-
> tools/perf/builtin-probe.c | 110 ++-
> tools/perf/builtin-stat.c | 2 +-
> tools/perf/builtin-trace.c | 5 +-
> tools/perf/perf.c | 12 +-
> tools/perf/tests/Build | 3 +
> tools/perf/tests/builtin-test.c | 8 +
> tools/perf/tests/gen-insn-x86-dat.awk | 75 ++
> tools/perf/tests/gen-insn-x86-dat.sh | 43 +
> tools/perf/tests/insn-x86-dat-32.c | 658 ++++++++++++++++
> tools/perf/tests/insn-x86-dat-64.c | 768 ++++++++++++++++++
> tools/perf/tests/insn-x86-dat-src.c | 877 +++++++++++++++++++++
> tools/perf/tests/insn-x86.c | 184 +++++
> tools/perf/tests/tests.h | 1 +
> tools/perf/trace/strace/groups/file | 2 +
> tools/perf/util/cpumap.c | 51 +-
> tools/perf/util/cpumap.h | 2 +
> tools/perf/util/header.c | 94 ++-
> tools/perf/util/header.h | 6 +
> tools/perf/util/intel-pt-decoder/Build | 13 +-
> .../perf/util/intel-pt-decoder/x86-opcode-map.txt | 24 +-
> tools/perf/util/intel-pt.c | 129 ++-
> tools/perf/util/parse-events.c | 2 +-
> tools/perf/util/probe-event.c | 97 +--
> tools/perf/util/probe-event.h | 9 +
> tools/perf/util/probe-file.c | 41 +-
> tools/perf/util/probe-file.h | 4 +
> .../perf/util/scripting-engines/trace-event-perl.c | 1 +
> .../util/scripting-engines/trace-event-python.c | 1 +
> tools/perf/util/session.c | 3 +-
> tools/perf/util/sort.c | 4 +-
> tools/perf/util/srcline.c | 29 +-
> tools/perf/util/trace-event-info.c | 2 +-
> tools/perf/util/trace-event.c | 1 +
> tools/perf/util/util.c | 70 --
> tools/perf/util/util.h | 8 +-
> 47 files changed, 3762 insertions(+), 294 deletions(-)
> create mode 100644 tools/include/linux/filter.h
> create mode 100644 tools/lib/api/fs/tracing_path.c
> create mode 100644 tools/lib/api/fs/tracing_path.h
> create mode 100644 tools/perf/tests/gen-insn-x86-dat.awk
> create mode 100755 tools/perf/tests/gen-insn-x86-dat.sh
> create mode 100644 tools/perf/tests/insn-x86-dat-32.c
> create mode 100644 tools/perf/tests/insn-x86-dat-64.c
> create mode 100644 tools/perf/tests/insn-x86-dat-src.c
> create mode 100644 tools/perf/tests/insn-x86.c
Pulled into tip:perf/core, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 42+ messages in thread
* [GIT PULL 00/31] perf/core improvements and fixes
@ 2015-09-04 16:44 Arnaldo Carvalho de Melo
2015-09-08 14:24 ` Ingo Molnar
0 siblings, 1 reply; 42+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-09-04 16:44 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Alexei Starovoitov, Andi Kleen, Andy Lutomirski, Borislav Petkov,
Brendan Gregg, Daniel Borkmann, Dave Hansen, David Ahern,
Denys Vlasenko, Frederic Weisbecker, He Kuang, H. Peter Anvin,
Jiri Olsa, Kaixu Xia, Kan Liang, Mark Rutland, Masami Hiramatsu,
Matt Fleming, Namhyung Kim, Paul Mackerras, Peter Zijlstra,
pi3orama, Qiaowei Ren, Raphael Beamonte, Stephane Eranian,
Steven Rostedt, Thomas Gleixner, Wang Nan, Zefan Li,
Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit 5b923564ccf43f92969c9e0fd199c8c5db657039:
Merge tag 'perf-urgent-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/urgent (2015-09-02 09:22:53 +0200)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-core-for-mingo
for you to fetch changes up to cf2f33a4e54096f90652cca3511fd6a456ea5abe:
perf trace: Add read/write to the file group (2015-09-04 13:22:06 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
User visible:
- Use PERF_RECORD_SWITCH when available in intel-pt, instead of
"sched:sched_switch" events, enabling an unprivileged user to trace
multi-threaded or multi-process workloads (Adrian Hunter)
- Always use non inlined file name for 'srcfile' sort key (Andi Kleen)
- Quieten failed to read counter message, helps in systems without
backend-stalled-cycles (Andi Kleen)
Infrastructure:
- Add a 'perf test' entry for decoding of new x86 instructions (Adrian Hunter)
- Add new instructions (sha, clflushopt, clwb, pcommit, rdpkru, wrpkru, xsavec,
xsaves, xrstors) to the x86 instruction decoder (Adrian Hunter)
- Add a build test to warn when source code drifts happen for the
instruction decoder files in the kernel and in tools/perf (Adrian Hunter)
- Copy linux/filter.h to tools/include (He Kuang)
- Support function __get_dynamic_array_len in libtraceevent (He Kuanguuu)
- Tracing path finding/mounting/error reporting refactorings (Jiri Olsa)
- Store CPU socket and core IDs in perf.data (Kan Liang)
- Reorganize add/del probe insertion routines in 'perf probe' (Namhyung Kim, Wang Nan)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Adrian Hunter (8):
perf tools: Display build warning if x86 instruction decoder differs from kernel
perf tools: Add a test for decoding of new x86 instructions
x86/insn: perf tools: Pedantically tweak opcode map for MPX instructions
x86/insn: perf tools: Add new SHA instructions
x86/insn: perf tools: Add new memory instructions
x86/insn: perf tools: Add new memory protection keys instructions
x86/insn: perf tools: Add new xsave instructions
perf intel-pt: Add support for PERF_RECORD_SWITCH
Andi Kleen (2):
perf tools: Always use non inlined file name for 'srcfile' sort key
perf stat: Quieten failed to read counter message
Arnaldo Carvalho de Melo (1):
perf trace: Add read/write to the file group
He Kuang (2):
perf tools: Copy linux/filter.h to tools/include
tools lib traceevent: Support function __get_dynamic_array_len
Jiri Olsa (10):
perf tools: Remove mountpoint arg from perf_debugfs_mount
perf tools: Move tracing_path stuff under same namespace
tools lib api fs: Move tracing_path interface into api/fs/tracing_path.c
tools lib api fs: Move debugfs__strerror_open into tracing_path.c object
tools lib api fs: Add STR and PATH_MAX macros to fs object
tools lib api fs: Move SYSFS_MAGIC PROC_SUPER_MAGIC into fs.c
tools lib api fs: Add debugfs into fs.c object
tools lib api fs: Add tracefs into fs.c object
tools lib api fs: Add FSTYPE__mount() method
tools lib api fs: Add FSTYPE__configured() method
Kan Liang (3):
perf cpumap: Factor out functions to get core_id and socket_id
perf tools: Store the cpu socket and core ids in the perf.data header
perf session: Don't call dump_sample() when evsel is NULL
Namhyung Kim (4):
perf probe: Split add_perf_probe_events()
perf probe: Move print logic into cmd_probe()
perf probe: Split del_perf_probe_events()
perf probe: Print deleted events in cmd_probe()
Wang Nan (1):
perf probe: Link trace_probe_event into perf_probe_event
arch/x86/lib/x86-opcode-map.txt | 24 +-
tools/include/linux/filter.h | 231 ++++++
tools/lib/api/fs/Build | 1 +
tools/lib/api/fs/debugfs.c | 52 --
tools/lib/api/fs/fs.c | 117 ++-
tools/lib/api/fs/fs.h | 26 +-
tools/lib/api/fs/tracing_path.c | 137 ++++
tools/lib/api/fs/tracing_path.h | 16 +
tools/lib/traceevent/event-parse.c | 56 +-
tools/lib/traceevent/event-parse.h | 1 +
tools/perf/MANIFEST | 1 +
tools/perf/arch/x86/util/intel-pt.c | 55 +-
tools/perf/builtin-probe.c | 110 ++-
tools/perf/builtin-stat.c | 2 +-
tools/perf/builtin-trace.c | 5 +-
tools/perf/perf.c | 12 +-
tools/perf/tests/Build | 3 +
tools/perf/tests/builtin-test.c | 8 +
tools/perf/tests/gen-insn-x86-dat.awk | 75 ++
tools/perf/tests/gen-insn-x86-dat.sh | 43 +
tools/perf/tests/insn-x86-dat-32.c | 658 ++++++++++++++++
tools/perf/tests/insn-x86-dat-64.c | 768 ++++++++++++++++++
tools/perf/tests/insn-x86-dat-src.c | 877 +++++++++++++++++++++
tools/perf/tests/insn-x86.c | 184 +++++
tools/perf/tests/tests.h | 1 +
tools/perf/trace/strace/groups/file | 2 +
tools/perf/util/cpumap.c | 51 +-
tools/perf/util/cpumap.h | 2 +
tools/perf/util/header.c | 94 ++-
tools/perf/util/header.h | 6 +
tools/perf/util/intel-pt-decoder/Build | 13 +-
.../perf/util/intel-pt-decoder/x86-opcode-map.txt | 24 +-
tools/perf/util/intel-pt.c | 129 ++-
tools/perf/util/parse-events.c | 2 +-
tools/perf/util/probe-event.c | 97 +--
tools/perf/util/probe-event.h | 9 +
tools/perf/util/probe-file.c | 41 +-
tools/perf/util/probe-file.h | 4 +
.../perf/util/scripting-engines/trace-event-perl.c | 1 +
.../util/scripting-engines/trace-event-python.c | 1 +
tools/perf/util/session.c | 3 +-
tools/perf/util/sort.c | 4 +-
tools/perf/util/srcline.c | 29 +-
tools/perf/util/trace-event-info.c | 2 +-
tools/perf/util/trace-event.c | 1 +
tools/perf/util/util.c | 70 --
tools/perf/util/util.h | 8 +-
47 files changed, 3762 insertions(+), 294 deletions(-)
create mode 100644 tools/include/linux/filter.h
create mode 100644 tools/lib/api/fs/tracing_path.c
create mode 100644 tools/lib/api/fs/tracing_path.h
create mode 100644 tools/perf/tests/gen-insn-x86-dat.awk
create mode 100755 tools/perf/tests/gen-insn-x86-dat.sh
create mode 100644 tools/perf/tests/insn-x86-dat-32.c
create mode 100644 tools/perf/tests/insn-x86-dat-64.c
create mode 100644 tools/perf/tests/insn-x86-dat-src.c
create mode 100644 tools/perf/tests/insn-x86.c
^ permalink raw reply [flat|nested] 42+ messages in thread
end of thread, other threads:[~2018-03-13 12:05 UTC | newest]
Thread overview: 42+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-19 17:04 [GIT PULL 00/31] perf/core improvements and fixes Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 01/31] perf hists browser: Simplify symbol annotation menu setup Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 02/31] perf hists browser: Fix up some branch alignment Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 03/31] perf hists: Remove hist_entry->used, not used anymore Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 04/31] perf hists browser: Allow annotating entries in callchains Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 05/31] perf tools: Fix building error for arm64 Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 06/31] perf build: Disable default check for libbabeltrace Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 07/31] perf build: Move features build output under features directory Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 08/31] perf build: Fix pthread-attr-setaffinity-np include in test-all Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 09/31] perf build: Get rid of LIB_INCLUDE variable Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 10/31] perf build: Rename CORE_FEATURE_TESTS to FEATURE_TESTS Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 11/31] perf build: Get rid of VF_FEATURE_TESTS Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 12/31] perf build: Rename display_lib into feature_display Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 13/31] perf build: Rename display_vf to feature_verbose Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 14/31] perf build: Rename PERF-FEATURES into FEATURE-DUMP Arnaldo Carvalho de Melo
2015-03-22 10:19 ` Ingo Molnar
2015-03-23 10:57 ` Jiri Olsa
2015-03-23 14:13 ` Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 15/31] perf build: Rename feature_print_var_code to print_var_code Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 17/31] perf tools: Fix the bash completion for listing options of perf subcommand Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 18/31] perf tools: Fix the bash completion for listing subsubcommands " Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 19/31] perf tools: Provide the right bash completion for listing options of perf subcommand subsubcommand Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 20/31] perf tools: Fix the bash completion for listing events of perf subcommand record|stat|top -e Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 21/31] perf tools: Fix the bash completion to support listing events for --event Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 22/31] perf tools: Fix the bash completion for listing subcommands of perf Arnaldo Carvalho de Melo
2015-03-19 17:04 ` [PATCH 23/31] perf tools: Add the bash completion for listing subsubcommands of perf data Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 24/31] perf tools: Add the bash completion for listing subsubcommands of perf help Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 25/31] perf tools: Add the bash completion for listing subsubcommands of perf script Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 26/31] perf tools: Add the bash completion for listing subsubcommands of perf test Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 27/31] perf tools: Add the bash completion for listing subsubcommands of perf timechart Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 28/31] perf tools: Add the bash completion for listing subsubcommands of perf trace Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 29/31] perf tools: Avoid confusion with preloaded bash function for perf bash completion Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 30/31] perf callchain: Separate eh/debug frame offset cache Arnaldo Carvalho de Melo
2015-03-19 17:05 ` [PATCH 31/31] perf report: Don't allow empty argument for '-t' Arnaldo Carvalho de Melo
2015-03-22 9:55 ` [GIT PULL 00/31] perf/core improvements and fixes Ingo Molnar
2015-09-04 16:44 Arnaldo Carvalho de Melo
2015-09-08 14:24 ` Ingo Molnar
2016-02-25 1:57 Arnaldo Carvalho de Melo
2016-02-25 7:22 ` Ingo Molnar
2018-03-13 12:04 Arnaldo Carvalho de Melo
2018-03-13 12:04 ` Arnaldo Carvalho de Melo
2018-03-13 12:04 ` 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.