* [GIT PULL 00/18] perf/core improvements and fixes
@ 2014-12-11 21:25 Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 01/18] perf bench: Prepare memcpy for merge Arnaldo Carvalho de Melo
` (18 more replies)
0 siblings, 19 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Alexander Yarygin, Andi Kleen, Arjun Sreedharan, Borislav Petkov,
Christian Borntraeger, Corey Ashford, David Ahern, Don Zickus,
Frederic Weisbecker, Jiri Olsa, Kan Liang, Kim Phillips,
Matt Mullins, Mike Galbraith, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Rabin Vincent, Stephane Eranian, Steven Rostedt,
Tom Huynh, Yann E. MORIN, Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit cfa0bd52d0ba9b852f76c7b3f1055edd5e5c7846:
Merge tag 'perf-core-for-mingo-2' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2014-12-08 07:45:45 +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 e09b18d4907992d3d615b215c1abf585721b2810:
perf trace: Provide a better explanation when mmap fails (2014-12-11 18:04:10 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
User visible:
- Mark events as (x86 only) in help output for 'perf kvm stat live" (Alexander Yarygin)
- Provide a better explanation when mmap fails in 'trace' (Arnaldo Carvalho de Melo)
- Add --buildid-dir option to set cache directory, i.e. use:
$ perf --buildid-dir /path/to/dir tool --tool-options
(Jiri Olsa)
- Fix memcpy/memset 'perf bench' output (Rabin Vicent)
- Fix 'perf test' attr tests size values to cope with machine state on
interrupt ABI changes (Jiri Olsa)
- Fixup callchain type parameter handling error message (Kan Liang)
Infrastructure/cleanups:
- calloc/xcalloc: Fix argument order (Arjun Sreedharan)
- Move filename__read_int from tools/perf/ to tools/lib, add sysctl__read_int
there and use it in place of ad-hoc copies (Arnaldo Carvalho de Melo)
- Use single strcmp call instead of two (Jiri Olsa)
- Remove extra debugdir variables in 'perf buildid-cache' (Jiri Olsa)
- Fix -a segfault related to kcore handling in 'perf buildid-cache' (Jiri Olsa)
- Move cpumode resolve code to add_callchain_ip (Kan Liang)
- Merge memset into memcpy 'perf bench' (Rabin Vincent)
- Change print format from %lu to %PRIu64 in the hists browser (Tom Huynh)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Alexander Yarygin (1):
perf kvm stat live: Mark events as (x86 only) in help output
Arjun Sreedharan (1):
calloc/xcalloc: Fix argument order
Arnaldo Carvalho de Melo (5):
tools lib fs: Adopt filename__read_int from tools/perf/
tools lib fs: Add sysctl__read_int helper
perf tools: Use sysctl__read_int instead of ad-hoc copies
perf evlist: Introduce strerror_mmap method
perf trace: Provide a better explanation when mmap fails
Jiri Olsa (5):
perf tools: Use single strcmp call instead of two
perf buildid-cache: Remove extra debugdir variables
perf buildid cache: Fix -a segfault related to kcore handling
perf tools: Add --buildid-dir option to set cache directory
perf tests: Fix attr tests size values to cope with machine state on interrupt ABI changes
Kan Liang (2):
perf callchain: Fixup parameter handling error message
perf callchain: Move cpumode resolve code to add_callchain_ip
Rabin Vincent (3):
perf bench: Prepare memcpy for merge
perf bench: Merge memset into memcpy
perf bench: Fix memcpy/memset output
Tom Huynh (1):
perf hists browser: Change print format from %lu to %PRIu64
scripts/kconfig/mconf.c | 4 +-
tools/lib/api/fs/fs.c | 34 +++++
tools/lib/api/fs/fs.h | 3 +
tools/perf/Documentation/perf.txt | 4 +
tools/perf/Makefile.perf | 1 -
tools/perf/bench/mem-memcpy.c | 286 ++++++++++++++++++++++++----------
tools/perf/bench/mem-memset.c | 304 -------------------------------------
tools/perf/builtin-buildid-cache.c | 13 +-
tools/perf/builtin-kvm.c | 3 +-
tools/perf/builtin-trace.c | 12 +-
tools/perf/perf.c | 14 +-
tools/perf/tests/attr/base-record | 2 +-
tools/perf/tests/attr/base-stat | 2 +-
tools/perf/ui/browsers/hists.c | 2 +-
tools/perf/ui/hist.c | 4 +-
tools/perf/util/build-id.c | 9 +-
tools/perf/util/callchain.c | 2 +-
tools/perf/util/config.c | 10 +-
tools/perf/util/evlist.c | 23 +++
tools/perf/util/evlist.h | 1 +
tools/perf/util/machine.c | 72 +++++----
tools/perf/util/record.c | 11 +-
tools/perf/util/util.c | 26 +---
tools/perf/util/util.h | 3 +-
tools/thermal/tmon/sysfs.c | 6 +-
25 files changed, 350 insertions(+), 501 deletions(-)
delete mode 100644 tools/perf/bench/mem-memset.c
^ permalink raw reply [flat|nested] 57+ messages in thread
* [PATCH 01/18] perf bench: Prepare memcpy for merge
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 02/18] perf bench: Merge memset into memcpy Arnaldo Carvalho de Melo
` (17 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Rabin Vincent, Ingo Molnar, Paul Mackerras,
Peter Zijlstra, Rabin Vincent, Arnaldo Carvalho de Melo
From: Rabin Vincent <rabin.vincent@axis.com>
The memset benchmark is largely copy-pasted from the memcpy benchmark.
Prepare the memcpy file for merge with memset by extracting out a
generic function.
Signed-off-by: Rabin Vincent <rabin.vincent@axis.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Rabin Vincent <rabinv@axis.com>
Link: http://lkml.kernel.org/r/1417535441-3965-1-git-send-email-rabin.vincent@axis.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/bench/mem-memcpy.c | 182 ++++++++++++++++++++++++------------------
1 file changed, 104 insertions(+), 78 deletions(-)
diff --git a/tools/perf/bench/mem-memcpy.c b/tools/perf/bench/mem-memcpy.c
index 2465141b554b..4a4493a7a1f8 100644
--- a/tools/perf/bench/mem-memcpy.c
+++ b/tools/perf/bench/mem-memcpy.c
@@ -52,16 +52,18 @@ typedef void *(*memcpy_t)(void *, const void *, size_t);
struct routine {
const char *name;
const char *desc;
- memcpy_t fn;
+ union {
+ memcpy_t memcpy;
+ } fn;
};
-struct routine routines[] = {
- { "default",
- "Default memcpy() provided by glibc",
- memcpy },
+struct routine memcpy_routines[] = {
+ { .name = "default",
+ .desc = "Default memcpy() provided by glibc",
+ .fn.memcpy = memcpy },
#ifdef HAVE_ARCH_X86_64_SUPPORT
-#define MEMCPY_FN(fn, name, desc) { name, desc, fn },
+#define MEMCPY_FN(_fn, _name, _desc) {.name = _name, .desc = _desc, .fn.memcpy = _fn},
#include "mem-memcpy-x86-64-asm-def.h"
#undef MEMCPY_FN
@@ -69,7 +71,7 @@ struct routine routines[] = {
{ NULL,
NULL,
- NULL }
+ {NULL} }
};
static const char * const bench_mem_memcpy_usage[] = {
@@ -110,63 +112,6 @@ static double timeval2double(struct timeval *ts)
(double)ts->tv_usec / (double)1000000;
}
-static void alloc_mem(void **dst, void **src, size_t length)
-{
- *dst = zalloc(length);
- if (!*dst)
- die("memory allocation failed - maybe length is too large?\n");
-
- *src = zalloc(length);
- if (!*src)
- die("memory allocation failed - maybe length is too large?\n");
- /* Make sure to always replace the zero pages even if MMAP_THRESH is crossed */
- memset(*src, 0, length);
-}
-
-static u64 do_memcpy_cycle(memcpy_t fn, size_t len, bool prefault)
-{
- u64 cycle_start = 0ULL, cycle_end = 0ULL;
- void *src = NULL, *dst = NULL;
- int i;
-
- alloc_mem(&src, &dst, len);
-
- if (prefault)
- fn(dst, src, len);
-
- cycle_start = get_cycle();
- for (i = 0; i < iterations; ++i)
- fn(dst, src, len);
- cycle_end = get_cycle();
-
- free(src);
- free(dst);
- return cycle_end - cycle_start;
-}
-
-static double do_memcpy_gettimeofday(memcpy_t fn, size_t len, bool prefault)
-{
- struct timeval tv_start, tv_end, tv_diff;
- void *src = NULL, *dst = NULL;
- int i;
-
- alloc_mem(&src, &dst, len);
-
- if (prefault)
- fn(dst, src, len);
-
- BUG_ON(gettimeofday(&tv_start, NULL));
- for (i = 0; i < iterations; ++i)
- fn(dst, src, len);
- BUG_ON(gettimeofday(&tv_end, NULL));
-
- timersub(&tv_end, &tv_start, &tv_diff);
-
- free(src);
- free(dst);
- return (double)((double)len / timeval2double(&tv_diff));
-}
-
#define pf (no_prefault ? 0 : 1)
#define print_bps(x) do { \
@@ -180,8 +125,16 @@ static double do_memcpy_gettimeofday(memcpy_t fn, size_t len, bool prefault)
printf(" %14lf GB/Sec", x / K / K / K); \
} while (0)
-int bench_mem_memcpy(int argc, const char **argv,
- const char *prefix __maybe_unused)
+struct bench_mem_info {
+ const struct routine *routines;
+ u64 (*do_cycle)(const struct routine *r, size_t len, bool prefault);
+ double (*do_gettimeofday)(const struct routine *r, size_t len, bool prefault);
+ const char *const *usage;
+};
+
+static int bench_mem_common(int argc, const char **argv,
+ const char *prefix __maybe_unused,
+ struct bench_mem_info *info)
{
int i;
size_t len;
@@ -189,7 +142,7 @@ int bench_mem_memcpy(int argc, const char **argv,
u64 result_cycle[2];
argc = parse_options(argc, argv, options,
- bench_mem_memcpy_usage, 0);
+ info->usage, 0);
if (no_prefault && only_prefault) {
fprintf(stderr, "Invalid options: -o and -n are mutually exclusive\n");
@@ -213,16 +166,16 @@ int bench_mem_memcpy(int argc, const char **argv,
if (only_prefault && no_prefault)
only_prefault = no_prefault = false;
- for (i = 0; routines[i].name; i++) {
- if (!strcmp(routines[i].name, routine))
+ for (i = 0; info->routines[i].name; i++) {
+ if (!strcmp(info->routines[i].name, routine))
break;
}
- if (!routines[i].name) {
+ if (!info->routines[i].name) {
printf("Unknown routine:%s\n", routine);
printf("Available routines...\n");
- for (i = 0; routines[i].name; i++) {
+ for (i = 0; info->routines[i].name; i++) {
printf("\t%s ... %s\n",
- routines[i].name, routines[i].desc);
+ info->routines[i].name, info->routines[i].desc);
}
return 1;
}
@@ -234,25 +187,25 @@ int bench_mem_memcpy(int argc, const char **argv,
/* show both of results */
if (use_cycle) {
result_cycle[0] =
- do_memcpy_cycle(routines[i].fn, len, false);
+ info->do_cycle(&info->routines[i], len, false);
result_cycle[1] =
- do_memcpy_cycle(routines[i].fn, len, true);
+ info->do_cycle(&info->routines[i], len, true);
} else {
result_bps[0] =
- do_memcpy_gettimeofday(routines[i].fn,
+ info->do_gettimeofday(&info->routines[i],
len, false);
result_bps[1] =
- do_memcpy_gettimeofday(routines[i].fn,
+ info->do_gettimeofday(&info->routines[i],
len, true);
}
} else {
if (use_cycle) {
result_cycle[pf] =
- do_memcpy_cycle(routines[i].fn,
+ info->do_cycle(&info->routines[i],
len, only_prefault);
} else {
result_bps[pf] =
- do_memcpy_gettimeofday(routines[i].fn,
+ info->do_gettimeofday(&info->routines[i],
len, only_prefault);
}
}
@@ -310,3 +263,76 @@ int bench_mem_memcpy(int argc, const char **argv,
return 0;
}
+
+static void memcpy_alloc_mem(void **dst, void **src, size_t length)
+{
+ *dst = zalloc(length);
+ if (!*dst)
+ die("memory allocation failed - maybe length is too large?\n");
+
+ *src = zalloc(length);
+ if (!*src)
+ die("memory allocation failed - maybe length is too large?\n");
+ /* Make sure to always replace the zero pages even if MMAP_THRESH is crossed */
+ memset(*src, 0, length);
+}
+
+static u64 do_memcpy_cycle(const struct routine *r, size_t len, bool prefault)
+{
+ u64 cycle_start = 0ULL, cycle_end = 0ULL;
+ void *src = NULL, *dst = NULL;
+ memcpy_t fn = r->fn.memcpy;
+ int i;
+
+ memcpy_alloc_mem(&src, &dst, len);
+
+ if (prefault)
+ fn(dst, src, len);
+
+ cycle_start = get_cycle();
+ for (i = 0; i < iterations; ++i)
+ fn(dst, src, len);
+ cycle_end = get_cycle();
+
+ free(src);
+ free(dst);
+ return cycle_end - cycle_start;
+}
+
+static double do_memcpy_gettimeofday(const struct routine *r, size_t len,
+ bool prefault)
+{
+ struct timeval tv_start, tv_end, tv_diff;
+ memcpy_t fn = r->fn.memcpy;
+ void *src = NULL, *dst = NULL;
+ int i;
+
+ memcpy_alloc_mem(&src, &dst, len);
+
+ if (prefault)
+ fn(dst, src, len);
+
+ BUG_ON(gettimeofday(&tv_start, NULL));
+ for (i = 0; i < iterations; ++i)
+ fn(dst, src, len);
+ BUG_ON(gettimeofday(&tv_end, NULL));
+
+ timersub(&tv_end, &tv_start, &tv_diff);
+
+ free(src);
+ free(dst);
+ return (double)((double)len / timeval2double(&tv_diff));
+}
+
+int bench_mem_memcpy(int argc, const char **argv,
+ const char *prefix __maybe_unused)
+{
+ struct bench_mem_info info = {
+ .routines = memcpy_routines,
+ .do_cycle = do_memcpy_cycle,
+ .do_gettimeofday = do_memcpy_gettimeofday,
+ .usage = bench_mem_memcpy_usage,
+ };
+
+ return bench_mem_common(argc, argv, prefix, &info);
+}
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 02/18] perf bench: Merge memset into memcpy
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 01/18] perf bench: Prepare memcpy for merge Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 03/18] perf bench: Fix memcpy/memset output Arnaldo Carvalho de Melo
` (16 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Rabin Vincent, Ingo Molnar, Paul Mackerras,
Peter Zijlstra, Rabin Vincent, Arnaldo Carvalho de Melo
From: Rabin Vincent <rabin.vincent@axis.com>
The memset benchmark is largely copy-pasted from the memcpy benchmark.
Merge the two now that memcpy is made more generic.
Signed-off-by: Rabin Vincent <rabin.vincent@axis.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Rabin Vincent <rabinv@axis.com>
Link: http://lkml.kernel.org/r/1417535441-3965-2-git-send-email-rabin.vincent@axis.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/Makefile.perf | 1 -
tools/perf/bench/mem-memcpy.c | 90 +++++++++++++
tools/perf/bench/mem-memset.c | 304 ------------------------------------------
3 files changed, 90 insertions(+), 305 deletions(-)
delete mode 100644 tools/perf/bench/mem-memset.c
diff --git a/tools/perf/Makefile.perf b/tools/perf/Makefile.perf
index 478efa9b2364..763e68fb5767 100644
--- a/tools/perf/Makefile.perf
+++ b/tools/perf/Makefile.perf
@@ -458,7 +458,6 @@ BUILTIN_OBJS += $(OUTPUT)bench/mem-memcpy-x86-64-asm.o
BUILTIN_OBJS += $(OUTPUT)bench/mem-memset-x86-64-asm.o
endif
BUILTIN_OBJS += $(OUTPUT)bench/mem-memcpy.o
-BUILTIN_OBJS += $(OUTPUT)bench/mem-memset.o
BUILTIN_OBJS += $(OUTPUT)bench/futex-hash.o
BUILTIN_OBJS += $(OUTPUT)bench/futex-wake.o
BUILTIN_OBJS += $(OUTPUT)bench/futex-requeue.o
diff --git a/tools/perf/bench/mem-memcpy.c b/tools/perf/bench/mem-memcpy.c
index 4a4493a7a1f8..e18be70c8a47 100644
--- a/tools/perf/bench/mem-memcpy.c
+++ b/tools/perf/bench/mem-memcpy.c
@@ -13,6 +13,7 @@
#include "../util/cloexec.h"
#include "bench.h"
#include "mem-memcpy-arch.h"
+#include "mem-memset-arch.h"
#include <stdio.h>
#include <stdlib.h>
@@ -48,12 +49,14 @@ static const struct option options[] = {
};
typedef void *(*memcpy_t)(void *, const void *, size_t);
+typedef void *(*memset_t)(void *, int, size_t);
struct routine {
const char *name;
const char *desc;
union {
memcpy_t memcpy;
+ memset_t memset;
} fn;
};
@@ -336,3 +339,90 @@ int bench_mem_memcpy(int argc, const char **argv,
return bench_mem_common(argc, argv, prefix, &info);
}
+
+static void memset_alloc_mem(void **dst, size_t length)
+{
+ *dst = zalloc(length);
+ if (!*dst)
+ die("memory allocation failed - maybe length is too large?\n");
+}
+
+static u64 do_memset_cycle(const struct routine *r, size_t len, bool prefault)
+{
+ u64 cycle_start = 0ULL, cycle_end = 0ULL;
+ memset_t fn = r->fn.memset;
+ void *dst = NULL;
+ int i;
+
+ memset_alloc_mem(&dst, len);
+
+ if (prefault)
+ fn(dst, -1, len);
+
+ cycle_start = get_cycle();
+ for (i = 0; i < iterations; ++i)
+ fn(dst, i, len);
+ cycle_end = get_cycle();
+
+ free(dst);
+ return cycle_end - cycle_start;
+}
+
+static double do_memset_gettimeofday(const struct routine *r, size_t len,
+ bool prefault)
+{
+ struct timeval tv_start, tv_end, tv_diff;
+ memset_t fn = r->fn.memset;
+ void *dst = NULL;
+ int i;
+
+ memset_alloc_mem(&dst, len);
+
+ if (prefault)
+ fn(dst, -1, len);
+
+ BUG_ON(gettimeofday(&tv_start, NULL));
+ for (i = 0; i < iterations; ++i)
+ fn(dst, i, len);
+ BUG_ON(gettimeofday(&tv_end, NULL));
+
+ timersub(&tv_end, &tv_start, &tv_diff);
+
+ free(dst);
+ return (double)((double)len / timeval2double(&tv_diff));
+}
+
+static const char * const bench_mem_memset_usage[] = {
+ "perf bench mem memset <options>",
+ NULL
+};
+
+static const struct routine memset_routines[] = {
+ { .name ="default",
+ .desc = "Default memset() provided by glibc",
+ .fn.memset = memset },
+#ifdef HAVE_ARCH_X86_64_SUPPORT
+
+#define MEMSET_FN(_fn, _name, _desc) { .name = _name, .desc = _desc, .fn.memset = _fn },
+#include "mem-memset-x86-64-asm-def.h"
+#undef MEMSET_FN
+
+#endif
+
+ { .name = NULL,
+ .desc = NULL,
+ .fn.memset = NULL }
+};
+
+int bench_mem_memset(int argc, const char **argv,
+ const char *prefix __maybe_unused)
+{
+ struct bench_mem_info info = {
+ .routines = memset_routines,
+ .do_cycle = do_memset_cycle,
+ .do_gettimeofday = do_memset_gettimeofday,
+ .usage = bench_mem_memset_usage,
+ };
+
+ return bench_mem_common(argc, argv, prefix, &info);
+}
diff --git a/tools/perf/bench/mem-memset.c b/tools/perf/bench/mem-memset.c
deleted file mode 100644
index 75fc3e65fb2a..000000000000
--- a/tools/perf/bench/mem-memset.c
+++ /dev/null
@@ -1,304 +0,0 @@
-/*
- * mem-memset.c
- *
- * memset: Simple memory set in various ways
- *
- * Trivial clone of mem-memcpy.c.
- */
-
-#include "../perf.h"
-#include "../util/util.h"
-#include "../util/parse-options.h"
-#include "../util/header.h"
-#include "../util/cloexec.h"
-#include "bench.h"
-#include "mem-memset-arch.h"
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <sys/time.h>
-#include <errno.h>
-
-#define K 1024
-
-static const char *length_str = "1MB";
-static const char *routine = "default";
-static int iterations = 1;
-static bool use_cycle;
-static int cycle_fd;
-static bool only_prefault;
-static bool no_prefault;
-
-static const struct option options[] = {
- OPT_STRING('l', "length", &length_str, "1MB",
- "Specify length of memory to set. "
- "Available units: B, KB, MB, GB and TB (upper and lower)"),
- OPT_STRING('r', "routine", &routine, "default",
- "Specify routine to set"),
- OPT_INTEGER('i', "iterations", &iterations,
- "repeat memset() invocation this number of times"),
- OPT_BOOLEAN('c', "cycle", &use_cycle,
- "Use cycles event instead of gettimeofday() for measuring"),
- OPT_BOOLEAN('o', "only-prefault", &only_prefault,
- "Show only the result with page faults before memset()"),
- OPT_BOOLEAN('n', "no-prefault", &no_prefault,
- "Show only the result without page faults before memset()"),
- OPT_END()
-};
-
-typedef void *(*memset_t)(void *, int, size_t);
-
-struct routine {
- const char *name;
- const char *desc;
- memset_t fn;
-};
-
-static const struct routine routines[] = {
- { "default",
- "Default memset() provided by glibc",
- memset },
-#ifdef HAVE_ARCH_X86_64_SUPPORT
-
-#define MEMSET_FN(fn, name, desc) { name, desc, fn },
-#include "mem-memset-x86-64-asm-def.h"
-#undef MEMSET_FN
-
-#endif
-
- { NULL,
- NULL,
- NULL }
-};
-
-static const char * const bench_mem_memset_usage[] = {
- "perf bench mem memset <options>",
- NULL
-};
-
-static struct perf_event_attr cycle_attr = {
- .type = PERF_TYPE_HARDWARE,
- .config = PERF_COUNT_HW_CPU_CYCLES
-};
-
-static void init_cycle(void)
-{
- cycle_fd = sys_perf_event_open(&cycle_attr, getpid(), -1, -1,
- perf_event_open_cloexec_flag());
-
- if (cycle_fd < 0 && errno == ENOSYS)
- die("No CONFIG_PERF_EVENTS=y kernel support configured?\n");
- else
- BUG_ON(cycle_fd < 0);
-}
-
-static u64 get_cycle(void)
-{
- int ret;
- u64 clk;
-
- ret = read(cycle_fd, &clk, sizeof(u64));
- BUG_ON(ret != sizeof(u64));
-
- return clk;
-}
-
-static double timeval2double(struct timeval *ts)
-{
- return (double)ts->tv_sec +
- (double)ts->tv_usec / (double)1000000;
-}
-
-static void alloc_mem(void **dst, size_t length)
-{
- *dst = zalloc(length);
- if (!*dst)
- die("memory allocation failed - maybe length is too large?\n");
-}
-
-static u64 do_memset_cycle(memset_t fn, size_t len, bool prefault)
-{
- u64 cycle_start = 0ULL, cycle_end = 0ULL;
- void *dst = NULL;
- int i;
-
- alloc_mem(&dst, len);
-
- if (prefault)
- fn(dst, -1, len);
-
- cycle_start = get_cycle();
- for (i = 0; i < iterations; ++i)
- fn(dst, i, len);
- cycle_end = get_cycle();
-
- free(dst);
- return cycle_end - cycle_start;
-}
-
-static double do_memset_gettimeofday(memset_t fn, size_t len, bool prefault)
-{
- struct timeval tv_start, tv_end, tv_diff;
- void *dst = NULL;
- int i;
-
- alloc_mem(&dst, len);
-
- if (prefault)
- fn(dst, -1, len);
-
- BUG_ON(gettimeofday(&tv_start, NULL));
- for (i = 0; i < iterations; ++i)
- fn(dst, i, len);
- BUG_ON(gettimeofday(&tv_end, NULL));
-
- timersub(&tv_end, &tv_start, &tv_diff);
-
- free(dst);
- return (double)((double)len / timeval2double(&tv_diff));
-}
-
-#define pf (no_prefault ? 0 : 1)
-
-#define print_bps(x) do { \
- if (x < K) \
- printf(" %14lf B/Sec", x); \
- else if (x < K * K) \
- printf(" %14lfd KB/Sec", x / K); \
- else if (x < K * K * K) \
- printf(" %14lf MB/Sec", x / K / K); \
- else \
- printf(" %14lf GB/Sec", x / K / K / K); \
- } while (0)
-
-int bench_mem_memset(int argc, const char **argv,
- const char *prefix __maybe_unused)
-{
- int i;
- size_t len;
- double result_bps[2];
- u64 result_cycle[2];
-
- argc = parse_options(argc, argv, options,
- bench_mem_memset_usage, 0);
-
- if (no_prefault && only_prefault) {
- fprintf(stderr, "Invalid options: -o and -n are mutually exclusive\n");
- return 1;
- }
-
- if (use_cycle)
- init_cycle();
-
- len = (size_t)perf_atoll((char *)length_str);
-
- result_cycle[0] = result_cycle[1] = 0ULL;
- result_bps[0] = result_bps[1] = 0.0;
-
- if ((s64)len <= 0) {
- fprintf(stderr, "Invalid length:%s\n", length_str);
- return 1;
- }
-
- /* same to without specifying either of prefault and no-prefault */
- if (only_prefault && no_prefault)
- only_prefault = no_prefault = false;
-
- for (i = 0; routines[i].name; i++) {
- if (!strcmp(routines[i].name, routine))
- break;
- }
- if (!routines[i].name) {
- printf("Unknown routine:%s\n", routine);
- printf("Available routines...\n");
- for (i = 0; routines[i].name; i++) {
- printf("\t%s ... %s\n",
- routines[i].name, routines[i].desc);
- }
- return 1;
- }
-
- if (bench_format == BENCH_FORMAT_DEFAULT)
- printf("# Copying %s Bytes ...\n\n", length_str);
-
- if (!only_prefault && !no_prefault) {
- /* show both of results */
- if (use_cycle) {
- result_cycle[0] =
- do_memset_cycle(routines[i].fn, len, false);
- result_cycle[1] =
- do_memset_cycle(routines[i].fn, len, true);
- } else {
- result_bps[0] =
- do_memset_gettimeofday(routines[i].fn,
- len, false);
- result_bps[1] =
- do_memset_gettimeofday(routines[i].fn,
- len, true);
- }
- } else {
- if (use_cycle) {
- result_cycle[pf] =
- do_memset_cycle(routines[i].fn,
- len, only_prefault);
- } else {
- result_bps[pf] =
- do_memset_gettimeofday(routines[i].fn,
- len, only_prefault);
- }
- }
-
- switch (bench_format) {
- case BENCH_FORMAT_DEFAULT:
- if (!only_prefault && !no_prefault) {
- if (use_cycle) {
- printf(" %14lf Cycle/Byte\n",
- (double)result_cycle[0]
- / (double)len);
- printf(" %14lf Cycle/Byte (with prefault)\n ",
- (double)result_cycle[1]
- / (double)len);
- } else {
- print_bps(result_bps[0]);
- printf("\n");
- print_bps(result_bps[1]);
- printf(" (with prefault)\n");
- }
- } else {
- if (use_cycle) {
- printf(" %14lf Cycle/Byte",
- (double)result_cycle[pf]
- / (double)len);
- } else
- print_bps(result_bps[pf]);
-
- printf("%s\n", only_prefault ? " (with prefault)" : "");
- }
- break;
- case BENCH_FORMAT_SIMPLE:
- if (!only_prefault && !no_prefault) {
- if (use_cycle) {
- printf("%lf %lf\n",
- (double)result_cycle[0] / (double)len,
- (double)result_cycle[1] / (double)len);
- } else {
- printf("%lf %lf\n",
- result_bps[0], result_bps[1]);
- }
- } else {
- if (use_cycle) {
- printf("%lf\n", (double)result_cycle[pf]
- / (double)len);
- } else
- printf("%lf\n", result_bps[pf]);
- }
- break;
- default:
- /* reaching this means there's some disaster: */
- die("unknown format: %d\n", bench_format);
- break;
- }
-
- return 0;
-}
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 03/18] perf bench: Fix memcpy/memset output
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 01/18] perf bench: Prepare memcpy for merge Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 02/18] perf bench: Merge memset into memcpy Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 04/18] perf hists browser: Change print format from %lu to %PRIu64 Arnaldo Carvalho de Melo
` (15 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Rabin Vincent, Ingo Molnar, Paul Mackerras,
Peter Zijlstra, Rabin Vincent, Rabin Vincent,
Arnaldo Carvalho de Melo
From: Rabin Vincent <rabin.vincent@axis.com>
The memcpy and memset benchmarks return bogus results when iterations >
0 because the iterations value is not taken into account when
calculating the final result:
$ perf bench mem memset --only-prefault --length 1GB --iterations 1
# Running 'mem/memset' benchmark:
# Copying 1GB Bytes ...
20.798669 GB/Sec (with prefault)
$ perf bench mem memset --only-prefault --length 1GB --iterations 10
# Running 'mem/memset' benchmark:
# Copying 1GB Bytes ...
2.086576 GB/Sec (with prefault)
$ perf bench mem memset --only-prefault --length 1GB --iterations 100
# Running 'mem/memset' benchmark:
# Copying 1GB Bytes ...
212.840917 MB/Sec (with prefault)
Fix this.
Signed-off-by: Rabin Vincent <rabin.vincent@axis.com>
Acked-by: Ingo Molnar <mingo@kernel.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Rabin Vincent <rabin@rab.in>
Cc: Rabin Vincent <rabinv@axis.com>
Link: http://lkml.kernel.org/r/1417535441-3965-3-git-send-email-rabin.vincent@axis.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/bench/mem-memcpy.c | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/tools/perf/bench/mem-memcpy.c b/tools/perf/bench/mem-memcpy.c
index e18be70c8a47..6c14afe8c1b1 100644
--- a/tools/perf/bench/mem-memcpy.c
+++ b/tools/perf/bench/mem-memcpy.c
@@ -141,6 +141,7 @@ static int bench_mem_common(int argc, const char **argv,
{
int i;
size_t len;
+ double totallen;
double result_bps[2];
u64 result_cycle[2];
@@ -156,6 +157,7 @@ static int bench_mem_common(int argc, const char **argv,
init_cycle();
len = (size_t)perf_atoll((char *)length_str);
+ totallen = (double)len * iterations;
result_cycle[0] = result_cycle[1] = 0ULL;
result_bps[0] = result_bps[1] = 0.0;
@@ -219,10 +221,10 @@ static int bench_mem_common(int argc, const char **argv,
if (use_cycle) {
printf(" %14lf Cycle/Byte\n",
(double)result_cycle[0]
- / (double)len);
+ / totallen);
printf(" %14lf Cycle/Byte (with prefault)\n",
(double)result_cycle[1]
- / (double)len);
+ / totallen);
} else {
print_bps(result_bps[0]);
printf("\n");
@@ -233,7 +235,7 @@ static int bench_mem_common(int argc, const char **argv,
if (use_cycle) {
printf(" %14lf Cycle/Byte",
(double)result_cycle[pf]
- / (double)len);
+ / totallen);
} else
print_bps(result_bps[pf]);
@@ -244,8 +246,8 @@ static int bench_mem_common(int argc, const char **argv,
if (!only_prefault && !no_prefault) {
if (use_cycle) {
printf("%lf %lf\n",
- (double)result_cycle[0] / (double)len,
- (double)result_cycle[1] / (double)len);
+ (double)result_cycle[0] / totallen,
+ (double)result_cycle[1] / totallen);
} else {
printf("%lf %lf\n",
result_bps[0], result_bps[1]);
@@ -253,7 +255,7 @@ static int bench_mem_common(int argc, const char **argv,
} else {
if (use_cycle) {
printf("%lf\n", (double)result_cycle[pf]
- / (double)len);
+ / totallen);
} else
printf("%lf\n", result_bps[pf]);
}
@@ -324,7 +326,7 @@ static double do_memcpy_gettimeofday(const struct routine *r, size_t len,
free(src);
free(dst);
- return (double)((double)len / timeval2double(&tv_diff));
+ return (double)(((double)len * iterations) / timeval2double(&tv_diff));
}
int bench_mem_memcpy(int argc, const char **argv,
@@ -389,7 +391,7 @@ static double do_memset_gettimeofday(const struct routine *r, size_t len,
timersub(&tv_end, &tv_start, &tv_diff);
free(dst);
- return (double)((double)len / timeval2double(&tv_diff));
+ return (double)(((double)len * iterations) / timeval2double(&tv_diff));
}
static const char * const bench_mem_memset_usage[] = {
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 04/18] perf hists browser: Change print format from %lu to %PRIu64
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (2 preceding siblings ...)
2014-12-11 21:25 ` [PATCH 03/18] perf bench: Fix memcpy/memset output Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 05/18] perf tools: Use single strcmp call instead of two Arnaldo Carvalho de Melo
` (14 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Tom Huynh, Ingo Molnar, Jiri Olsa, Kim Phillips,
Matt Mullins, Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Arnaldo Carvalho de Melo
From: Tom Huynh <tom.huynh@freescale.com>
The nr_events variable in tools/perf/ui/browsers/hists.c is of type u64,
so the print format (%lu) causes 'perf report' to show 0 event count
when running with 32-bit userspace without redirection.
This patch fixes that problem by printing nr_events as PRIu64.
Signed-off-by: Tom Huynh <tom.huynh@freescale.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Kim Phillips <kim.phillips@freescale.com>
Cc: Matt Mullins <mmullins@mmlx.us>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1417541842-9747-1-git-send-email-tom.huynh@freescale.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/ui/browsers/hists.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
index 502daff76ceb..e6bb04b5b09b 100644
--- a/tools/perf/ui/browsers/hists.c
+++ b/tools/perf/ui/browsers/hists.c
@@ -1252,7 +1252,7 @@ static int hists__browser_title(struct hists *hists,
nr_samples = convert_unit(nr_samples, &unit);
printed = scnprintf(bf, size,
- "Samples: %lu%c of event '%s', Event count (approx.): %lu",
+ "Samples: %lu%c of event '%s', Event count (approx.): %" PRIu64,
nr_samples, unit, ev_name, nr_events);
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 05/18] perf tools: Use single strcmp call instead of two
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (3 preceding siblings ...)
2014-12-11 21:25 ` [PATCH 04/18] perf hists browser: Change print format from %lu to %PRIu64 Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 06/18] perf buildid-cache: Remove extra debugdir variables Arnaldo Carvalho de Melo
` (13 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Frederic Weisbecker, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Stephane Eranian, Steven Rostedt,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
There's no need to use 2 strcmp calls, one is enough.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Link: http://lkml.kernel.org/r/1417460789-13874-2-git-send-email-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/util/config.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/perf/util/config.c b/tools/perf/util/config.c
index 57ff826f150b..c802236b2bfe 100644
--- a/tools/perf/util/config.c
+++ b/tools/perf/util/config.c
@@ -522,7 +522,7 @@ static int buildid_dir_command_config(const char *var, const char *value,
const char *v;
/* same dir for all commands */
- if (!prefixcmp(var, "buildid.") && !strcmp(var + 8, "dir")) {
+ if (!strcmp(var, "buildid.dir")) {
v = perf_config_dirname(var, value);
if (!v)
return -1;
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 06/18] perf buildid-cache: Remove extra debugdir variables
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (4 preceding siblings ...)
2014-12-11 21:25 ` [PATCH 05/18] perf tools: Use single strcmp call instead of two Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 07/18] perf buildid cache: Fix -a segfault related to kcore handling Arnaldo Carvalho de Melo
` (12 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Frederic Weisbecker, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Stephane Eranian, Steven Rostedt,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
There's no need to copy over the buildid_dir into separate variable with
no change.
This is leftover from commit:
45de34bbe3e1 perf buildid: add perfconfig option to specify buildid cache dir
that added global buildid_dir variable that holds cache directory, but
did not cleanup the debugdir copies.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Link: http://lkml.kernel.org/r/1417460789-13874-3-git-send-email-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-buildid-cache.c | 11 ++++-------
tools/perf/util/build-id.c | 9 +++------
2 files changed, 7 insertions(+), 13 deletions(-)
diff --git a/tools/perf/builtin-buildid-cache.c b/tools/perf/builtin-buildid-cache.c
index 70385756da63..29f24c071bc6 100644
--- a/tools/perf/builtin-buildid-cache.c
+++ b/tools/perf/builtin-buildid-cache.c
@@ -285,7 +285,6 @@ int cmd_buildid_cache(int argc, const char **argv,
struct str_node *pos;
int ret = 0;
bool force = false;
- char debugdir[PATH_MAX];
char const *add_name_list_str = NULL,
*remove_name_list_str = NULL,
*missing_filename = NULL,
@@ -335,13 +334,11 @@ int cmd_buildid_cache(int argc, const char **argv,
setup_pager();
- snprintf(debugdir, sizeof(debugdir), "%s", buildid_dir);
-
if (add_name_list_str) {
list = strlist__new(true, add_name_list_str);
if (list) {
strlist__for_each(pos, list)
- if (build_id_cache__add_file(pos->s, debugdir)) {
+ if (build_id_cache__add_file(pos->s, buildid_dir)) {
if (errno == EEXIST) {
pr_debug("%s already in the cache\n",
pos->s);
@@ -359,7 +356,7 @@ int cmd_buildid_cache(int argc, const char **argv,
list = strlist__new(true, remove_name_list_str);
if (list) {
strlist__for_each(pos, list)
- if (build_id_cache__remove_file(pos->s, debugdir)) {
+ if (build_id_cache__remove_file(pos->s, buildid_dir)) {
if (errno == ENOENT) {
pr_debug("%s wasn't in the cache\n",
pos->s);
@@ -380,7 +377,7 @@ int cmd_buildid_cache(int argc, const char **argv,
list = strlist__new(true, update_name_list_str);
if (list) {
strlist__for_each(pos, list)
- if (build_id_cache__update_file(pos->s, debugdir)) {
+ if (build_id_cache__update_file(pos->s, buildid_dir)) {
if (errno == ENOENT) {
pr_debug("%s wasn't in the cache\n",
pos->s);
@@ -395,7 +392,7 @@ int cmd_buildid_cache(int argc, const char **argv,
}
if (kcore_filename &&
- build_id_cache__add_kcore(kcore_filename, debugdir, force))
+ build_id_cache__add_kcore(kcore_filename, buildid_dir, force))
pr_warning("Couldn't add %s\n", kcore_filename);
out:
diff --git a/tools/perf/util/build-id.c b/tools/perf/util/build-id.c
index e8d79e5bfaf7..0c72680a977f 100644
--- a/tools/perf/util/build-id.c
+++ b/tools/perf/util/build-id.c
@@ -410,21 +410,18 @@ int perf_session__cache_build_ids(struct perf_session *session)
{
struct rb_node *nd;
int ret;
- char debugdir[PATH_MAX];
if (no_buildid_cache)
return 0;
- snprintf(debugdir, sizeof(debugdir), "%s", buildid_dir);
-
- if (mkdir(debugdir, 0755) != 0 && errno != EEXIST)
+ if (mkdir(buildid_dir, 0755) != 0 && errno != EEXIST)
return -1;
- ret = machine__cache_build_ids(&session->machines.host, debugdir);
+ ret = machine__cache_build_ids(&session->machines.host, buildid_dir);
for (nd = rb_first(&session->machines.guests); nd; nd = rb_next(nd)) {
struct machine *pos = rb_entry(nd, struct machine, rb_node);
- ret |= machine__cache_build_ids(pos, debugdir);
+ ret |= machine__cache_build_ids(pos, buildid_dir);
}
return ret ? -1 : 0;
}
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 07/18] perf buildid cache: Fix -a segfault related to kcore handling
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (5 preceding siblings ...)
2014-12-11 21:25 ` [PATCH 06/18] perf buildid-cache: Remove extra debugdir variables Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 08/18] perf tools: Add --buildid-dir option to set cache directory Arnaldo Carvalho de Melo
` (11 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Adrian Hunter, Corey Ashford,
David Ahern, Frederic Weisbecker, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Stephane Eranian, Steven Rostedt,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
The kcore_filename is uninitialized and trash value could trigger
build_id_cache__add_kcore function ending up with segfault.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Link: http://lkml.kernel.org/r/1417460789-13874-7-git-send-email-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-buildid-cache.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/perf/builtin-buildid-cache.c b/tools/perf/builtin-buildid-cache.c
index 29f24c071bc6..77d5cae54c6a 100644
--- a/tools/perf/builtin-buildid-cache.c
+++ b/tools/perf/builtin-buildid-cache.c
@@ -289,7 +289,7 @@ int cmd_buildid_cache(int argc, const char **argv,
*remove_name_list_str = NULL,
*missing_filename = NULL,
*update_name_list_str = NULL,
- *kcore_filename;
+ *kcore_filename = NULL;
char sbuf[STRERR_BUFSIZE];
struct perf_data_file file = {
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 08/18] perf tools: Add --buildid-dir option to set cache directory
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (6 preceding siblings ...)
2014-12-11 21:25 ` [PATCH 07/18] perf buildid cache: Fix -a segfault related to kcore handling Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 09/18] perf callchain: Fixup parameter handling error message Arnaldo Carvalho de Melo
` (10 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Corey Ashford, David Ahern,
Frederic Weisbecker, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Stephane Eranian, Steven Rostedt,
Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@kernel.org>
Adding --buildid-dir to be able to set specific cache directory. It's
going to be handy for buildid tests coming in shortly.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Link: http://lkml.kernel.org/r/1417460789-13874-4-git-send-email-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/Documentation/perf.txt | 4 ++++
tools/perf/perf.c | 14 ++++++++++++--
tools/perf/util/config.c | 8 +++++---
tools/perf/util/util.h | 2 +-
4 files changed, 22 insertions(+), 6 deletions(-)
diff --git a/tools/perf/Documentation/perf.txt b/tools/perf/Documentation/perf.txt
index d240bb2e5b22..1e8e400b4493 100644
--- a/tools/perf/Documentation/perf.txt
+++ b/tools/perf/Documentation/perf.txt
@@ -18,6 +18,10 @@ OPTIONS
--debug verbose # sets verbose = 1
--debug verbose=2 # sets verbose = 2
+--buildid-dir::
+ Setup buildid cache directory. It has higher priority than
+ buildid.dir config file option.
+
DESCRIPTION
-----------
Performance counters for Linux are a new kernel-based subsystem
diff --git a/tools/perf/perf.c b/tools/perf/perf.c
index 452a8474d29d..3700a7faca6c 100644
--- a/tools/perf/perf.c
+++ b/tools/perf/perf.c
@@ -200,6 +200,16 @@ static int handle_options(const char ***argv, int *argc, int *envchanged)
*envchanged = 1;
(*argv)++;
(*argc)--;
+ } else if (!strcmp(cmd, "--buildid-dir")) {
+ if (*argc < 2) {
+ fprintf(stderr, "No directory given for --buildid-dir.\n");
+ usage(perf_usage_string);
+ }
+ set_buildid_dir((*argv)[1]);
+ if (envchanged)
+ *envchanged = 1;
+ (*argv)++;
+ (*argc)--;
} else if (!prefixcmp(cmd, CMD_DEBUGFS_DIR)) {
perf_debugfs_set_path(cmd + strlen(CMD_DEBUGFS_DIR));
fprintf(stderr, "dir: %s\n", debugfs_mountpoint);
@@ -499,7 +509,7 @@ int main(int argc, const char **argv)
}
if (!prefixcmp(cmd, "trace")) {
#ifdef HAVE_LIBAUDIT_SUPPORT
- set_buildid_dir();
+ set_buildid_dir(NULL);
setup_path();
argv[0] = "trace";
return cmd_trace(argc, argv, NULL);
@@ -514,7 +524,7 @@ int main(int argc, const char **argv)
argc--;
handle_options(&argv, &argc, NULL);
commit_pager_choice();
- set_buildid_dir();
+ set_buildid_dir(NULL);
if (argc > 0) {
if (!prefixcmp(argv[0], "--"))
diff --git a/tools/perf/util/config.c b/tools/perf/util/config.c
index c802236b2bfe..e18f653cd7db 100644
--- a/tools/perf/util/config.c
+++ b/tools/perf/util/config.c
@@ -539,12 +539,14 @@ static void check_buildid_dir_config(void)
perf_config(buildid_dir_command_config, &c);
}
-void set_buildid_dir(void)
+void set_buildid_dir(const char *dir)
{
- buildid_dir[0] = '\0';
+ if (dir)
+ scnprintf(buildid_dir, MAXPATHLEN-1, "%s", dir);
/* try config file */
- check_buildid_dir_config();
+ if (buildid_dir[0] == '\0')
+ check_buildid_dir_config();
/* default to $HOME/.debug */
if (buildid_dir[0] == '\0') {
diff --git a/tools/perf/util/util.h b/tools/perf/util/util.h
index 419bee030f83..abc445ee4f60 100644
--- a/tools/perf/util/util.h
+++ b/tools/perf/util/util.h
@@ -153,7 +153,7 @@ extern void warning(const char *err, ...) __attribute__((format (printf, 1, 2)))
extern void set_die_routine(void (*routine)(const char *err, va_list params) NORETURN);
extern int prefixcmp(const char *str, const char *prefix);
-extern void set_buildid_dir(void);
+extern void set_buildid_dir(const char *dir);
static inline const char *skip_prefix(const char *str, const char *prefix)
{
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 09/18] perf callchain: Fixup parameter handling error message
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (7 preceding siblings ...)
2014-12-11 21:25 ` [PATCH 08/18] perf tools: Add --buildid-dir option to set cache directory Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 10/18] perf callchain: Move cpumode resolve code to add_callchain_ip Arnaldo Carvalho de Melo
` (9 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Kan Liang, Andi Kleen, Ingo Molnar, Jiri Olsa,
Namhyung Kim, Paul Mackerras, Peter Zijlstra, Stephane Eranian,
Arnaldo Carvalho de Melo
From: Kan Liang <kan.liang@intel.com>
Fix up parse_callchain_record_opt error message for 'fp', in the past using '-g
fp' was a valid alternative to '--call-graph fp', which is not the case since:
commit 09b0fd45ff63413df94cbd832a765076b201edbb
Author: Jiri Olsa <jolsa@redhat.com>
Date: Sat Oct 26 16:25:33 2013 +0200
perf record: Split -g and --call-graph
I.e. -g means "use the configured unwind data collection method" which has as
default 'fp', while --call-graph requires passing the method to use.
Signed-off-by: Kan Liang <kan.liang@intel.com>
Acked-by: Jiri Olsa <jolsa@redhat.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/r/1417532814-26208-2-git-send-email-kan.liang@intel.com
[ split this from a larger patch related to LBR based unwinding ]
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/util/callchain.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/perf/util/callchain.c b/tools/perf/util/callchain.c
index cf524a35cc84..64b377e591e4 100644
--- a/tools/perf/util/callchain.c
+++ b/tools/perf/util/callchain.c
@@ -77,7 +77,7 @@ int parse_callchain_record_opt(const char *arg)
ret = 0;
} else
pr_err("callchain: No more arguments "
- "needed for -g fp\n");
+ "needed for --call-graph fp\n");
break;
#ifdef HAVE_DWARF_UNWIND_SUPPORT
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 10/18] perf callchain: Move cpumode resolve code to add_callchain_ip
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (8 preceding siblings ...)
2014-12-11 21:25 ` [PATCH 09/18] perf callchain: Fixup parameter handling error message Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 11/18] calloc/xcalloc: Fix argument order Arnaldo Carvalho de Melo
` (8 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Kan Liang, Andi Kleen, Ingo Molnar, Jiri Olsa,
Namhyung Kim, Paul Mackerras, Peter Zijlstra, Stephane Eranian,
Arnaldo Carvalho de Melo
From: Kan Liang <kan.liang@intel.com>
Using flag to distinguish between branch_history and normal callchain.
Move the cpumode to add_callchain_ip function.
No change in behavior.
Signed-off-by: Kan Liang <kan.liang@intel.com>
Acked-by: Jiri Olsa <jolsa@redhat.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/r/1417532814-26208-3-git-send-email-kan.liang@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/util/machine.c | 72 +++++++++++++++++++++++------------------------
1 file changed, 35 insertions(+), 37 deletions(-)
diff --git a/tools/perf/util/machine.c b/tools/perf/util/machine.c
index 15dd0a9691ce..94de3e48b490 100644
--- a/tools/perf/util/machine.c
+++ b/tools/perf/util/machine.c
@@ -1385,19 +1385,46 @@ struct mem_info *sample__resolve_mem(struct perf_sample *sample,
static int add_callchain_ip(struct thread *thread,
struct symbol **parent,
struct addr_location *root_al,
- int cpumode,
+ bool branch_history,
u64 ip)
{
struct addr_location al;
al.filtered = 0;
al.sym = NULL;
- if (cpumode == -1)
+ if (branch_history)
thread__find_cpumode_addr_location(thread, MAP__FUNCTION,
ip, &al);
- else
+ else {
+ u8 cpumode = PERF_RECORD_MISC_USER;
+
+ if (ip >= PERF_CONTEXT_MAX) {
+ switch (ip) {
+ case PERF_CONTEXT_HV:
+ cpumode = PERF_RECORD_MISC_HYPERVISOR;
+ break;
+ case PERF_CONTEXT_KERNEL:
+ cpumode = PERF_RECORD_MISC_KERNEL;
+ break;
+ case PERF_CONTEXT_USER:
+ cpumode = PERF_RECORD_MISC_USER;
+ break;
+ default:
+ pr_debug("invalid callchain context: "
+ "%"PRId64"\n", (s64) ip);
+ /*
+ * It seems the callchain is corrupted.
+ * Discard all.
+ */
+ callchain_cursor_reset(&callchain_cursor);
+ return 1;
+ }
+ return 0;
+ }
thread__find_addr_location(thread, cpumode, MAP__FUNCTION,
ip, &al);
+ }
+
if (al.sym != NULL) {
if (sort__has_parent && !*parent &&
symbol__match_regex(al.sym, &parent_regex))
@@ -1480,11 +1507,8 @@ static int thread__resolve_callchain_sample(struct thread *thread,
struct addr_location *root_al,
int max_stack)
{
- u8 cpumode = PERF_RECORD_MISC_USER;
int chain_nr = min(max_stack, (int)chain->nr);
- int i;
- int j;
- int err;
+ int i, j, err;
int skip_idx = -1;
int first_call = 0;
@@ -1542,10 +1566,10 @@ static int thread__resolve_callchain_sample(struct thread *thread,
for (i = 0; i < nr; i++) {
err = add_callchain_ip(thread, parent, root_al,
- -1, be[i].to);
+ true, be[i].to);
if (!err)
err = add_callchain_ip(thread, parent, root_al,
- -1, be[i].from);
+ true, be[i].from);
if (err == -EINVAL)
break;
if (err)
@@ -1574,36 +1598,10 @@ check_calls:
#endif
ip = chain->ips[j];
- if (ip >= PERF_CONTEXT_MAX) {
- switch (ip) {
- case PERF_CONTEXT_HV:
- cpumode = PERF_RECORD_MISC_HYPERVISOR;
- break;
- case PERF_CONTEXT_KERNEL:
- cpumode = PERF_RECORD_MISC_KERNEL;
- break;
- case PERF_CONTEXT_USER:
- cpumode = PERF_RECORD_MISC_USER;
- break;
- default:
- pr_debug("invalid callchain context: "
- "%"PRId64"\n", (s64) ip);
- /*
- * It seems the callchain is corrupted.
- * Discard all.
- */
- callchain_cursor_reset(&callchain_cursor);
- return 0;
- }
- continue;
- }
+ err = add_callchain_ip(thread, parent, root_al, false, ip);
- err = add_callchain_ip(thread, parent, root_al,
- cpumode, ip);
- if (err == -EINVAL)
- break;
if (err)
- return err;
+ return (err < 0) ? err : 0;
}
return 0;
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 11/18] calloc/xcalloc: Fix argument order
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (9 preceding siblings ...)
2014-12-11 21:25 ` [PATCH 10/18] perf callchain: Move cpumode resolve code to add_callchain_ip Arnaldo Carvalho de Melo
@ 2014-12-11 21:25 ` Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 12/18] perf tests: Fix attr tests size values to cope with machine state on interrupt ABI changes Arnaldo Carvalho de Melo
` (7 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:25 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arjun Sreedharan, Yann E. MORIN, Ingo Molnar,
Paul Mackerras, Peter Zijlstra, Arnaldo Carvalho de Melo
From: Arjun Sreedharan <arjun024@gmail.com>
The calloc() and xcalloc() functions takes @nmemb first and then @size. Fix all w/
pattern "calloc\s*(\s*sizeof".
Signed-off-by: Arjun Sreedharan <arjun024@gmail.com>
Cc: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1417866043-1877-1-git-send-email-arjun024@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
scripts/kconfig/mconf.c | 4 ++--
tools/perf/ui/hist.c | 4 ++--
tools/thermal/tmon/sysfs.c | 6 +++---
3 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/scripts/kconfig/mconf.c b/scripts/kconfig/mconf.c
index 14cea7463a62..4dd37552abc2 100644
--- a/scripts/kconfig/mconf.c
+++ b/scripts/kconfig/mconf.c
@@ -330,10 +330,10 @@ static void set_subtitle(void)
list_for_each_entry(sp, &trail, entries) {
if (sp->text) {
if (pos) {
- pos->next = xcalloc(sizeof(*pos), 1);
+ pos->next = xcalloc(1, sizeof(*pos));
pos = pos->next;
} else {
- subtitles = pos = xcalloc(sizeof(*pos), 1);
+ subtitles = pos = xcalloc(1, sizeof(*pos));
}
pos->text = sp->text;
}
diff --git a/tools/perf/ui/hist.c b/tools/perf/ui/hist.c
index 2af18376b077..dc0d095f318c 100644
--- a/tools/perf/ui/hist.c
+++ b/tools/perf/ui/hist.c
@@ -162,8 +162,8 @@ static int __hpp__sort(struct hist_entry *a, struct hist_entry *b,
return ret;
nr_members = evsel->nr_members;
- fields_a = calloc(sizeof(*fields_a), nr_members);
- fields_b = calloc(sizeof(*fields_b), nr_members);
+ fields_a = calloc(nr_members, sizeof(*fields_a));
+ fields_b = calloc(nr_members, sizeof(*fields_b));
if (!fields_a || !fields_b)
goto out;
diff --git a/tools/thermal/tmon/sysfs.c b/tools/thermal/tmon/sysfs.c
index dfe454855cd2..1c12536f2081 100644
--- a/tools/thermal/tmon/sysfs.c
+++ b/tools/thermal/tmon/sysfs.c
@@ -446,7 +446,7 @@ int probe_thermal_sysfs(void)
return -1;
}
- ptdata.tzi = calloc(sizeof(struct tz_info), ptdata.max_tz_instance+1);
+ ptdata.tzi = calloc(ptdata.max_tz_instance+1, sizeof(struct tz_info));
if (!ptdata.tzi) {
fprintf(stderr, "Err: allocate tz_info\n");
return -1;
@@ -454,8 +454,8 @@ int probe_thermal_sysfs(void)
/* we still show thermal zone information if there is no cdev */
if (ptdata.nr_cooling_dev) {
- ptdata.cdi = calloc(sizeof(struct cdev_info),
- ptdata.max_cdev_instance + 1);
+ ptdata.cdi = calloc(ptdata.max_cdev_instance + 1,
+ sizeof(struct cdev_info));
if (!ptdata.cdi) {
free(ptdata.tzi);
fprintf(stderr, "Err: allocate cdev_info\n");
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 12/18] perf tests: Fix attr tests size values to cope with machine state on interrupt ABI changes
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (10 preceding siblings ...)
2014-12-11 21:25 ` [PATCH 11/18] calloc/xcalloc: Fix argument order Arnaldo Carvalho de Melo
@ 2014-12-11 21:26 ` Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 13/18] perf kvm stat live: Mark events as (x86 only) in help output Arnaldo Carvalho de Melo
` (6 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:26 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Jiri Olsa, Andi Kleen, Peter Zijlstra,
Stephane Eranian, Arnaldo Carvalho de Melo
From: Jiri Olsa <jolsa@redhat.com>
Following change adjusted 'struct perf_event_attr', but let
the attr test's sizes untouched:
60e2364e60e8 perf: Add ability to sample machine state on interrupt
[jolsa@krava perf]$ ./perf test attr -vv
--- start ---
test child forked, pid 9719
running './tests/attr/test-stat-group1'
'PERF_TEST_ATTR=/tmp/tmp4drvul ./perf stat -o /tmp/tmp4drvul/perf.data -e '{cycles,instructions}' kill >/dev/null 2>&1' ret 1
expected size=96, got 104
FAILED './tests/attr/test-stat-group1' - match failure
Adjusting test size values for attr test.
Reported-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Jiri Olsa <jolsa@redhat.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/r/20141209135301.GC6784@krava.brq.redhat.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/tests/attr/base-record | 2 +-
tools/perf/tests/attr/base-stat | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/tools/perf/tests/attr/base-record b/tools/perf/tests/attr/base-record
index f710b92ccff6..d3095dafed36 100644
--- a/tools/perf/tests/attr/base-record
+++ b/tools/perf/tests/attr/base-record
@@ -5,7 +5,7 @@ group_fd=-1
flags=0|8
cpu=*
type=0|1
-size=96
+size=104
config=0
sample_period=4000
sample_type=263
diff --git a/tools/perf/tests/attr/base-stat b/tools/perf/tests/attr/base-stat
index dc3ada2470c0..872ed7e24c7c 100644
--- a/tools/perf/tests/attr/base-stat
+++ b/tools/perf/tests/attr/base-stat
@@ -5,7 +5,7 @@ group_fd=-1
flags=0|8
cpu=*
type=0
-size=96
+size=104
config=0
sample_period=0
sample_type=0
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 13/18] perf kvm stat live: Mark events as (x86 only) in help output
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (11 preceding siblings ...)
2014-12-11 21:26 ` [PATCH 12/18] perf tests: Fix attr tests size values to cope with machine state on interrupt ABI changes Arnaldo Carvalho de Melo
@ 2014-12-11 21:26 ` Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 14/18] tools lib fs: Adopt filename__read_int from tools/perf/ Arnaldo Carvalho de Melo
` (5 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:26 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Alexander Yarygin, Christian Borntraeger,
Jiri Olsa, Arnaldo Carvalho de Melo
From: Alexander Yarygin <yarygin@linux.vnet.ibm.com>
The mmio and ioport events are useful only on x86.
Signed-off-by: Alexander Yarygin <yarygin@linux.vnet.ibm.com>
Acked-by: David Ahern <dsahern@gmail.com>
Cc: Christian Borntraeger <borntraeger@de.ibm.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Link: http://lkml.kernel.org/r/1418218090-20718-1-git-send-email-borntraeger@de.ibm.com
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-kvm.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/tools/perf/builtin-kvm.c b/tools/perf/builtin-kvm.c
index 3c0f3d4fb021..0894a817f67e 100644
--- a/tools/perf/builtin-kvm.c
+++ b/tools/perf/builtin-kvm.c
@@ -1293,7 +1293,8 @@ static int kvm_events_live(struct perf_kvm_stat *kvm,
OPT_UINTEGER('d', "display", &kvm->display_time,
"time in seconds between display updates"),
OPT_STRING(0, "event", &kvm->report_event, "report event",
- "event for reporting: vmexit, mmio, ioport"),
+ "event for reporting: "
+ "vmexit, mmio (x86 only), ioport (x86 only)"),
OPT_INTEGER(0, "vcpu", &kvm->trace_vcpu,
"vcpu id to report"),
OPT_STRING('k', "key", &kvm->sort_key, "sort-key",
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 14/18] tools lib fs: Adopt filename__read_int from tools/perf/
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (12 preceding siblings ...)
2014-12-11 21:26 ` [PATCH 13/18] perf kvm stat live: Mark events as (x86 only) in help output Arnaldo Carvalho de Melo
@ 2014-12-11 21:26 ` Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 15/18] tools lib fs: Add sysctl__read_int helper Arnaldo Carvalho de Melo
` (4 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:26 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, Mike Galbraith, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Stephane Eranian
From: Arnaldo Carvalho de Melo <acme@redhat.com>
Will be useful for new helpers to read sysctl values.
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: Mike Galbraith <efault@gmx.de>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/lib/api/fs/fs.c | 21 +++++++++++++++++++++
tools/lib/api/fs/fs.h | 2 ++
tools/perf/util/util.c | 17 -----------------
tools/perf/util/util.h | 1 -
4 files changed, 23 insertions(+), 18 deletions(-)
diff --git a/tools/lib/api/fs/fs.c b/tools/lib/api/fs/fs.c
index c1b49c36a951..b8d0df8878d1 100644
--- a/tools/lib/api/fs/fs.c
+++ b/tools/lib/api/fs/fs.c
@@ -7,6 +7,10 @@
#include <stdlib.h>
#include <string.h>
#include <sys/vfs.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <fcntl.h>
+#include <unistd.h>
#include "debugfs.h"
#include "fs.h"
@@ -163,3 +167,20 @@ const char *name##__mountpoint(void) \
FS__MOUNTPOINT(sysfs, FS__SYSFS);
FS__MOUNTPOINT(procfs, FS__PROCFS);
+
+int filename__read_int(const char *filename, int *value)
+{
+ char line[64];
+ int fd = open(filename, O_RDONLY), err = -1;
+
+ if (fd < 0)
+ return -1;
+
+ if (read(fd, line, sizeof(line)) > 0) {
+ *value = atoi(line);
+ err = 0;
+ }
+
+ close(fd);
+ return err;
+}
diff --git a/tools/lib/api/fs/fs.h b/tools/lib/api/fs/fs.h
index cb7049551f33..4d0aef6e7163 100644
--- a/tools/lib/api/fs/fs.h
+++ b/tools/lib/api/fs/fs.h
@@ -11,4 +11,6 @@
const char *sysfs__mountpoint(void);
const char *procfs__mountpoint(void);
+
+int filename__read_int(const char *filename, int *value);
#endif /* __API_FS__ */
diff --git a/tools/perf/util/util.c b/tools/perf/util/util.c
index d5eab3f3323f..41125e5b011e 100644
--- a/tools/perf/util/util.c
+++ b/tools/perf/util/util.c
@@ -442,23 +442,6 @@ unsigned long parse_tag_value(const char *str, struct parse_tag *tags)
return (unsigned long) -1;
}
-int filename__read_int(const char *filename, int *value)
-{
- char line[64];
- int fd = open(filename, O_RDONLY), err = -1;
-
- if (fd < 0)
- return -1;
-
- if (read(fd, line, sizeof(line)) > 0) {
- *value = atoi(line);
- err = 0;
- }
-
- close(fd);
- return err;
-}
-
int filename__read_str(const char *filename, char **buf, size_t *sizep)
{
size_t size = 0, alloc_size = 0;
diff --git a/tools/perf/util/util.h b/tools/perf/util/util.h
index abc445ee4f60..008b361b1758 100644
--- a/tools/perf/util/util.h
+++ b/tools/perf/util/util.h
@@ -343,7 +343,6 @@ char *get_srcline(struct dso *dso, unsigned long addr, struct symbol *sym,
bool show_sym);
void free_srcline(char *srcline);
-int filename__read_int(const char *filename, int *value);
int filename__read_str(const char *filename, char **buf, size_t *sizep);
int perf_event_paranoid(void);
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 15/18] tools lib fs: Add sysctl__read_int helper
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (13 preceding siblings ...)
2014-12-11 21:26 ` [PATCH 14/18] tools lib fs: Adopt filename__read_int from tools/perf/ Arnaldo Carvalho de Melo
@ 2014-12-11 21:26 ` Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 16/18] perf tools: Use sysctl__read_int instead of ad-hoc copies Arnaldo Carvalho de Melo
` (3 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:26 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, Mike Galbraith, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Stephane Eranian
From: Arnaldo Carvalho de Melo <acme@redhat.com>
Will come in handy for tools, see next patches.
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: Mike Galbraith <efault@gmx.de>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-nay9j62ztxpytt4ew1tkl4op@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/lib/api/fs/fs.c | 13 +++++++++++++
tools/lib/api/fs/fs.h | 1 +
2 files changed, 14 insertions(+)
diff --git a/tools/lib/api/fs/fs.c b/tools/lib/api/fs/fs.c
index b8d0df8878d1..65d9be3f9887 100644
--- a/tools/lib/api/fs/fs.c
+++ b/tools/lib/api/fs/fs.c
@@ -184,3 +184,16 @@ int filename__read_int(const char *filename, int *value)
close(fd);
return err;
}
+
+int sysctl__read_int(const char *sysctl, int *value)
+{
+ char path[PATH_MAX];
+ const char *procfs = procfs__mountpoint();
+
+ if (!procfs)
+ return -1;
+
+ snprintf(path, sizeof(path), "%s/sys/%s", procfs, sysctl);
+
+ return filename__read_int(path, value);
+}
diff --git a/tools/lib/api/fs/fs.h b/tools/lib/api/fs/fs.h
index 4d0aef6e7163..6caa2bbc6cec 100644
--- a/tools/lib/api/fs/fs.h
+++ b/tools/lib/api/fs/fs.h
@@ -13,4 +13,5 @@ const char *sysfs__mountpoint(void);
const char *procfs__mountpoint(void);
int filename__read_int(const char *filename, int *value);
+int sysctl__read_int(const char *sysctl, int *value);
#endif /* __API_FS__ */
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 16/18] perf tools: Use sysctl__read_int instead of ad-hoc copies
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (14 preceding siblings ...)
2014-12-11 21:26 ` [PATCH 15/18] tools lib fs: Add sysctl__read_int helper Arnaldo Carvalho de Melo
@ 2014-12-11 21:26 ` Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 17/18] perf evlist: Introduce strerror_mmap method Arnaldo Carvalho de Melo
` (2 subsequent siblings)
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:26 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, Mike Galbraith, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Stephane Eranian
From: Arnaldo Carvalho de Melo <acme@redhat.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: Mike Galbraith <efault@gmx.de>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-pt2u7a3b50oddggecx7rwq2n@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/util/record.c | 11 +----------
tools/perf/util/util.c | 9 +--------
2 files changed, 2 insertions(+), 18 deletions(-)
diff --git a/tools/perf/util/record.c b/tools/perf/util/record.c
index cf69325b985f..8acd0df88b5c 100644
--- a/tools/perf/util/record.c
+++ b/tools/perf/util/record.c
@@ -137,16 +137,7 @@ void perf_evlist__config(struct perf_evlist *evlist, struct record_opts *opts)
static int get_max_rate(unsigned int *rate)
{
- char path[PATH_MAX];
- const char *procfs = procfs__mountpoint();
-
- if (!procfs)
- return -1;
-
- snprintf(path, PATH_MAX,
- "%s/sys/kernel/perf_event_max_sample_rate", procfs);
-
- return filename__read_int(path, (int *) rate);
+ return sysctl__read_int("kernel/perf_event_max_sample_rate", (int *)rate);
}
static int record_opts__config_freq(struct record_opts *opts)
diff --git a/tools/perf/util/util.c b/tools/perf/util/util.c
index 41125e5b011e..b86744f29eef 100644
--- a/tools/perf/util/util.c
+++ b/tools/perf/util/util.c
@@ -506,16 +506,9 @@ const char *get_filename_for_perf_kvm(void)
int perf_event_paranoid(void)
{
- char path[PATH_MAX];
- const char *procfs = procfs__mountpoint();
int value;
- if (!procfs)
- return INT_MAX;
-
- scnprintf(path, PATH_MAX, "%s/sys/kernel/perf_event_paranoid", procfs);
-
- if (filename__read_int(path, &value))
+ if (sysctl__read_int("kernel/perf_event_paranoid", &value))
return INT_MAX;
return value;
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 17/18] perf evlist: Introduce strerror_mmap method
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (15 preceding siblings ...)
2014-12-11 21:26 ` [PATCH 16/18] perf tools: Use sysctl__read_int instead of ad-hoc copies Arnaldo Carvalho de Melo
@ 2014-12-11 21:26 ` Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 18/18] perf trace: Provide a better explanation when mmap fails Arnaldo Carvalho de Melo
2014-12-12 8:10 ` [GIT PULL 00/18] perf/core improvements and fixes Ingo Molnar
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:26 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, Mike Galbraith, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Stephane Eranian
From: Arnaldo Carvalho de Melo <acme@redhat.com>
To pretty print hints about perf_evlist__mmap errors. Will be used in
'trace' in the next patch.
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: Mike Galbraith <efault@gmx.de>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-2g3gczfwyz0xt3we0s15mqqt@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/util/evlist.c | 23 +++++++++++++++++++++++
tools/perf/util/evlist.h | 1 +
2 files changed, 24 insertions(+)
diff --git a/tools/perf/util/evlist.c b/tools/perf/util/evlist.c
index cfbe2b99b9aa..bb5dfc5d1e75 100644
--- a/tools/perf/util/evlist.c
+++ b/tools/perf/util/evlist.c
@@ -8,6 +8,7 @@
*/
#include "util.h"
#include <api/fs/debugfs.h>
+#include <api/fs/fs.h>
#include <poll.h>
#include "cpumap.h"
#include "thread_map.h"
@@ -1483,6 +1484,28 @@ int perf_evlist__strerror_open(struct perf_evlist *evlist __maybe_unused,
return 0;
}
+int perf_evlist__strerror_mmap(struct perf_evlist *evlist, int err, char *buf, size_t size)
+{
+ char sbuf[STRERR_BUFSIZE], *emsg = strerror_r(err, sbuf, sizeof(sbuf));
+ int value;
+
+ switch (err) {
+ case EPERM:
+ sysctl__read_int("kernel/perf_event_mlock_kb", &value);
+ scnprintf(buf, size, "Error:\t%s.\n"
+ "Hint:\tCheck /proc/sys/kernel/perf_event_mlock_kb (%d kB) setting.\n"
+ "Hint:\tTried using %zd kB.\n"
+ "Hint:\tTry using a bigger -m/--mmap-pages value.",
+ emsg, value, evlist->mmap_len / 1024);
+ break;
+ default:
+ scnprintf(buf, size, "%s", emsg);
+ break;
+ }
+
+ return 0;
+}
+
void perf_evlist__to_front(struct perf_evlist *evlist,
struct perf_evsel *move_evsel)
{
diff --git a/tools/perf/util/evlist.h b/tools/perf/util/evlist.h
index 649b0c597283..0ba93f67ab94 100644
--- a/tools/perf/util/evlist.h
+++ b/tools/perf/util/evlist.h
@@ -185,6 +185,7 @@ size_t perf_evlist__fprintf(struct perf_evlist *evlist, FILE *fp);
int perf_evlist__strerror_tp(struct perf_evlist *evlist, int err, char *buf, size_t size);
int perf_evlist__strerror_open(struct perf_evlist *evlist, int err, char *buf, size_t size);
+int perf_evlist__strerror_mmap(struct perf_evlist *evlist, int err, char *buf, size_t size);
static inline unsigned int perf_mmap__read_head(struct perf_mmap *mm)
{
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* [PATCH 18/18] perf trace: Provide a better explanation when mmap fails
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (16 preceding siblings ...)
2014-12-11 21:26 ` [PATCH 17/18] perf evlist: Introduce strerror_mmap method Arnaldo Carvalho de Melo
@ 2014-12-11 21:26 ` Arnaldo Carvalho de Melo
2014-12-12 8:10 ` [GIT PULL 00/18] perf/core improvements and fixes Ingo Molnar
18 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-11 21:26 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, Mike Galbraith, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Stephane Eranian
From: Arnaldo Carvalho de Melo <acme@redhat.com>
If we ask for a mmap lenght than the max configured via the relevant
sysctl, provide a better warning, instead of just expanding the EPERM
returned:
[acme@ssdandy ~]$ trace -m 256 -e nanosleep sleep 2
Error: Operation not permitted.
Hint: Check /proc/sys/kernel/perf_event_mlock_kb (516 kB) setting.
Hint: Tried using 1028 kB.
Hint: Try using a bigger -m/--mmap-pages value.
[acme@ssdandy ~]$ trace -m 128 -e nanosleep sleep 2
2001.280 (2000.403 ms): nanosleep(rqtp: 0x7fff89a8a7f0) = 0
[acme@ssdandy ~]$
An upcoming patch will autotune the request for non-root users when -m
is not used.
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: Mike Galbraith <efault@gmx.de>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-cdvxfz2gycetbkopm9sna1qp@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/builtin-trace.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
index 83a4835c8118..327541e43c7f 100644
--- a/tools/perf/builtin-trace.c
+++ b/tools/perf/builtin-trace.c
@@ -2045,7 +2045,6 @@ static int trace__run(struct trace *trace, int argc, const char **argv)
unsigned long before;
const bool forks = argc > 0;
bool draining = false;
- char sbuf[STRERR_BUFSIZE];
trace->live = true;
@@ -2106,11 +2105,8 @@ static int trace__run(struct trace *trace, int argc, const char **argv)
goto out_error_open;
err = perf_evlist__mmap(evlist, trace->opts.mmap_pages, false);
- if (err < 0) {
- fprintf(trace->output, "Couldn't mmap the events: %s\n",
- strerror_r(errno, sbuf, sizeof(sbuf)));
- goto out_delete_evlist;
- }
+ if (err < 0)
+ goto out_error_mmap;
perf_evlist__enable(evlist);
@@ -2210,6 +2206,10 @@ out_error_tp:
perf_evlist__strerror_tp(evlist, errno, errbuf, sizeof(errbuf));
goto out_error;
+out_error_mmap:
+ perf_evlist__strerror_mmap(evlist, errno, errbuf, sizeof(errbuf));
+ goto out_error;
+
out_error_open:
perf_evlist__strerror_open(evlist, errno, errbuf, sizeof(errbuf));
--
1.9.3
^ permalink raw reply related [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
` (17 preceding siblings ...)
2014-12-11 21:26 ` [PATCH 18/18] perf trace: Provide a better explanation when mmap fails Arnaldo Carvalho de Melo
@ 2014-12-12 8:10 ` Ingo Molnar
18 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2014-12-12 8:10 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Adrian Hunter, Alexander Yarygin, Andi Kleen,
Arjun Sreedharan, Borislav Petkov, Christian Borntraeger,
Corey Ashford, David Ahern, Don Zickus, Frederic Weisbecker,
Jiri Olsa, Kan Liang, Kim Phillips, Matt Mullins, Mike Galbraith,
Namhyung Kim, Paul Mackerras, Peter Zijlstra, Rabin Vincent,
Stephane Eranian, Steven Rostedt, Tom Huynh, Yann E. MORIN,
Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> The following changes since commit cfa0bd52d0ba9b852f76c7b3f1055edd5e5c7846:
>
> Merge tag 'perf-core-for-mingo-2' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2014-12-08 07:45:45 +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 e09b18d4907992d3d615b215c1abf585721b2810:
>
> perf trace: Provide a better explanation when mmap fails (2014-12-11 18:04:10 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> User visible:
>
> - Mark events as (x86 only) in help output for 'perf kvm stat live" (Alexander Yarygin)
>
> - Provide a better explanation when mmap fails in 'trace' (Arnaldo Carvalho de Melo)
>
> - Add --buildid-dir option to set cache directory, i.e. use:
>
> $ perf --buildid-dir /path/to/dir tool --tool-options
>
> (Jiri Olsa)
>
> - Fix memcpy/memset 'perf bench' output (Rabin Vicent)
>
> - Fix 'perf test' attr tests size values to cope with machine state on
> interrupt ABI changes (Jiri Olsa)
>
> - Fixup callchain type parameter handling error message (Kan Liang)
>
> Infrastructure/cleanups:
>
> - calloc/xcalloc: Fix argument order (Arjun Sreedharan)
>
> - Move filename__read_int from tools/perf/ to tools/lib, add sysctl__read_int
> there and use it in place of ad-hoc copies (Arnaldo Carvalho de Melo)
>
> - Use single strcmp call instead of two (Jiri Olsa)
>
> - Remove extra debugdir variables in 'perf buildid-cache' (Jiri Olsa)
>
> - Fix -a segfault related to kcore handling in 'perf buildid-cache' (Jiri Olsa)
>
> - Move cpumode resolve code to add_callchain_ip (Kan Liang)
>
> - Merge memset into memcpy 'perf bench' (Rabin Vincent)
>
> - Change print format from %lu to %PRIu64 in the hists browser (Tom Huynh)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Alexander Yarygin (1):
> perf kvm stat live: Mark events as (x86 only) in help output
>
> Arjun Sreedharan (1):
> calloc/xcalloc: Fix argument order
>
> Arnaldo Carvalho de Melo (5):
> tools lib fs: Adopt filename__read_int from tools/perf/
> tools lib fs: Add sysctl__read_int helper
> perf tools: Use sysctl__read_int instead of ad-hoc copies
> perf evlist: Introduce strerror_mmap method
> perf trace: Provide a better explanation when mmap fails
>
> Jiri Olsa (5):
> perf tools: Use single strcmp call instead of two
> perf buildid-cache: Remove extra debugdir variables
> perf buildid cache: Fix -a segfault related to kcore handling
> perf tools: Add --buildid-dir option to set cache directory
> perf tests: Fix attr tests size values to cope with machine state on interrupt ABI changes
>
> Kan Liang (2):
> perf callchain: Fixup parameter handling error message
> perf callchain: Move cpumode resolve code to add_callchain_ip
>
> Rabin Vincent (3):
> perf bench: Prepare memcpy for merge
> perf bench: Merge memset into memcpy
> perf bench: Fix memcpy/memset output
>
> Tom Huynh (1):
> perf hists browser: Change print format from %lu to %PRIu64
>
> scripts/kconfig/mconf.c | 4 +-
> tools/lib/api/fs/fs.c | 34 +++++
> tools/lib/api/fs/fs.h | 3 +
> tools/perf/Documentation/perf.txt | 4 +
> tools/perf/Makefile.perf | 1 -
> tools/perf/bench/mem-memcpy.c | 286 ++++++++++++++++++++++++----------
> tools/perf/bench/mem-memset.c | 304 -------------------------------------
> tools/perf/builtin-buildid-cache.c | 13 +-
> tools/perf/builtin-kvm.c | 3 +-
> tools/perf/builtin-trace.c | 12 +-
> tools/perf/perf.c | 14 +-
> tools/perf/tests/attr/base-record | 2 +-
> tools/perf/tests/attr/base-stat | 2 +-
> tools/perf/ui/browsers/hists.c | 2 +-
> tools/perf/ui/hist.c | 4 +-
> tools/perf/util/build-id.c | 9 +-
> tools/perf/util/callchain.c | 2 +-
> tools/perf/util/config.c | 10 +-
> tools/perf/util/evlist.c | 23 +++
> tools/perf/util/evlist.h | 1 +
> tools/perf/util/machine.c | 72 +++++----
> tools/perf/util/record.c | 11 +-
> tools/perf/util/util.c | 26 +---
> tools/perf/util/util.h | 3 +-
> tools/thermal/tmon/sysfs.c | 6 +-
> 25 files changed, 350 insertions(+), 501 deletions(-)
> delete mode 100644 tools/perf/bench/mem-memset.c
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2018-05-19 10:54 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2018-05-19 10:54 UTC (permalink / raw)
To: Ingo Molnar
Cc: Clark Williams, linux-kernel, linux-perf-users,
Arnaldo Carvalho de Melo, Adrian Hunter, Alexander Shishkin,
Andi Kleen, Andy Lutomirski, Dave Hansen, David Ahern,
H . Peter Anvin, Jin Yao, Jiri Olsa, Joerg Roedel, Kan Liang,
Namhyung Kim, Naveen N . Rao, Peter Zijlstra, Ravi Bangoria,
Sandipan Das, Taeung Song, Thomas Gleixner, Wang Nan, x86,
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 5aafae8d097e2161ee5c6a12ad532100f8885d2b:
Merge tag 'perf-core-for-mingo-4.18-20180516' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2018-05-16 17:56:43 +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-4.18-20180519
for you to fetch changes up to 19422a9f2a3be7f3a046285ffae4cbb571aa853a:
perf tools: Fix kernel_start for PTI on x86 (2018-05-19 06:42:51 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
- Record min/max LBR cycles (>= skylake) and add 'perf annotate' TUI
hotkey to show it (c) (Jin Yao)
- Fix machine->kernel_start for PTI on x86 (Adrian Hunter)
- Make machine->env->arch always available, e.g. in 'perf top', not
just when reading that info from perf.data files (Adrian Hunter)
- Reduce the number of files read at 'perf' start, leaving information such as
cacheline size, tracefs mount point determination, max_stack, etc, to be
lazily read as tools needs then (Arnaldo Carvalho de Melo)
- Fixup BPF include and examples install messages (Arnaldo Carvalho de Melo)
- Fixup callchain addresses and symbol offsets in 'perf script', to help
correlating with objdump output (Sandipan Das)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Adrian Hunter (2):
perf machine: Add machine__is() to identify machine arch
perf tools: Fix kernel_start for PTI on x86
Arnaldo Carvalho de Melo (12):
perf config: Call perf_config__init() lazily
tools lib api: The tracing_mnt variable doesn't need to be global
tools lib api: Unexport 'tracing_path' variable
tools lib api fs tracing_path: Introduce get/put_events_file() helpers
perf tools: Reuse the path to the tracepoint /events/ directory
perf parse-events: Use get/put_events_file()
tools lib api fs tracing_path: Introduce opendir() method
tools lib api fs tracing_path: Make tracing_events_path private
tools include compiler-gcc: Add __pure attribute helper
perf tools: Read the cache line size lazily
perf tools: No need to unconditionally read the max_stack sysctls
perf bpf: Fixup include and examples install messages
Jin Yao (2):
perf annotate: Record the min/max cycles
perf annotate: Create hotkey 'c' to show min/max cycles
Sandipan Das (2):
perf script: Show virtual addresses instead of offsets
perf script: Show symbol offsets by default
tools/include/linux/compiler-gcc.h | 3 +
tools/lib/api/fs/tracing_path.c | 40 +++++++++---
tools/lib/api/fs/tracing_path.h | 9 ++-
tools/perf/Makefile.perf | 2 +
tools/perf/builtin-script.c | 26 ++++----
tools/perf/builtin-top.c | 2 +-
tools/perf/builtin-trace.c | 2 +-
tools/perf/perf.c | 24 +------
tools/perf/tests/parse-events.c | 9 +--
.../tests/shell/record+probe_libc_inet_pton.sh | 12 ++--
tools/perf/ui/browsers/annotate.c | 8 +++
tools/perf/util/annotate.c | 51 ++++++++++++---
tools/perf/util/annotate.h | 11 +++-
tools/perf/util/config.c | 16 ++---
tools/perf/util/config.h | 1 -
tools/perf/util/env.c | 18 ++++++
tools/perf/util/env.h | 2 +
tools/perf/util/evsel.c | 2 +-
tools/perf/util/machine.c | 18 +++++-
tools/perf/util/machine.h | 2 +
tools/perf/util/parse-events.c | 73 +++++++++++++---------
tools/perf/util/probe-file.c | 3 +-
tools/perf/util/sort.c | 4 +-
tools/perf/util/sort.h | 4 +-
tools/perf/util/trace-event-info.c | 11 ++--
tools/perf/util/trace-event.c | 8 ++-
tools/perf/util/util.c | 34 +++++++++-
tools/perf/util/util.h | 4 +-
28 files changed, 279 insertions(+), 120 deletions(-)
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, and building with LIBCLANGLLVM=1
(built-in clang) with gcc and clang when clang and its devel libraries
are installed.
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-28)
7 amazonlinux:2 : Ok gcc (GCC) 7.3.1 20180303 (Red Hat 7.3.1-5)
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+deb9u1) 6.3.0 20170516
16 debian:experimental : Ok gcc (Debian 7.3.0-19) 7.3.0
17 debian:experimental-x-arm64 : Ok aarch64-linux-gnu-gcc (Debian 7.3.0-19) 7.3.0
18 debian:experimental-x-mips : Ok mips-linux-gnu-gcc (Debian 7.3.0-19) 7.3.0
19 debian:experimental-x-mips64 : Ok mips64-linux-gnuabi64-gcc (Debian 7.3.0-18) 7.3.0
20 debian:experimental-x-mipsel : Ok mipsel-linux-gnu-gcc (Debian 7.3.0-19) 7.3.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.3.1 20180130 (Red Hat 7.3.1-2)
29 fedora:27 : Ok gcc (GCC) 7.3.1 20180303 (Red Hat 7.3.1-5)
30 fedora:28 : Ok gcc (GCC) 8.1.1 20180502 (Red Hat 8.1.1-1)
31 fedora:rawhide : Ok gcc (GCC) 8.0.1 20180324 (Red Hat 8.0.1-0.20)
32 gentoo-stage3-amd64:latest : Ok gcc (Gentoo 6.4.0-r1 p1.3) 6.4.0
33 mageia:5 : Ok gcc (GCC) 4.9.2
34 mageia:6 : Ok gcc (Mageia 5.5.0-1.mga6) 5.5.0
35 opensuse:42.1 : Ok gcc (SUSE Linux) 4.8.5
36 opensuse:42.2 : Ok gcc (SUSE Linux) 4.8.5
37 opensuse:42.3 : Ok gcc (SUSE Linux) 4.8.5
38 opensuse:tumbleweed : Ok gcc (SUSE Linux) 7.3.1 20180323 [gcc-7-branch revision 258812]
39 oraclelinux:6 : Ok gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-18.0.7)
40 oraclelinux:7 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-28.0.1)
41 ubuntu:12.04.5 : Ok gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
42 ubuntu:14.04.4 : Ok gcc (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4
43 ubuntu:14.04.4-x-linaro-arm64 : Ok aarch64-linux-gnu-gcc (Linaro GCC 5.5-2017.10) 5.5.0
44 ubuntu:16.04 : Ok gcc (Ubuntu 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
45 ubuntu:16.04-x-arm : Ok arm-linux-gnueabihf-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
46 ubuntu:16.04-x-arm64 : Ok aarch64-linux-gnu-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
47 ubuntu:16.04-x-powerpc : Ok powerpc-linux-gnu-gcc (Ubuntu 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
48 ubuntu:16.04-x-powerpc64 : Ok powerpc64-linux-gnu-gcc (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
49 ubuntu:16.04-x-powerpc64el : Ok powerpc64le-linux-gnu-gcc (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
50 ubuntu:16.04-x-s390 : Ok s390x-linux-gnu-gcc (Ubuntu 5.4.0-6ubuntu1~16.04.9) 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.2) 7.2.0
54 ubuntu:18.04 : Ok gcc (Ubuntu 7.3.0-16ubuntu3) 7.3.0
#
# uname -a
Linux seventh 4.17.0-rc5-00069-g3acf4e395260 #2 SMP Fri May 18 12:13:59 -03 2018 x86_64 x86_64 x86_64 GNU/Linux
# perf --version
perf version 4.17.rc5.g19422a9
# 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: Breakpoint accounting : Ok
22: Number of exit events of a simple workload : Ok
23: Software clock events period values : Ok
24: Object code reading : Ok
25: Sample parsing : Ok
26: Use a dummy software event to keep tracking : Ok
27: Parse with no sample_id_all bit set : Ok
28: Filter hist entries : Ok
29: Lookup mmap thread : Ok
30: Share thread mg : Ok
31: Sort output of hist entries : Ok
32: Cumulate child hist entries : Ok
33: Track with sched_switch : Ok
34: Filter fds with revents mask in a fdarray : Ok
35: Add fd to a fdarray, making it autogrow : Ok
36: kmod_path__parse : Ok
37: Thread map : Ok
38: LLVM search and compile :
38.1: Basic BPF llvm compile : Ok
38.2: kbuild searching : Ok
38.3: Compile source for BPF prologue generation : Ok
38.4: Compile source for BPF relocation : Ok
39: Session topology : Ok
40: BPF filter :
40.1: Basic BPF filtering : Ok
40.2: BPF pinning : Ok
40.3: BPF prologue generation : Ok
40.4: BPF relocation checker : Ok
41: Synthesize thread map : Ok
42: Remove thread map : Ok
43: Synthesize cpu map : Ok
44: Synthesize stat config : Ok
45: Synthesize stat : Ok
46: Synthesize stat round : Ok
47: Synthesize attr update : Ok
48: Event times : Ok
49: Read backward ring buffer : Ok
50: Print cpu map : Ok
51: Probe SDT events : Ok
52: is_printable_array : Ok
53: Print bitmap : Ok
54: perf hooks : Ok
55: builtin clang support : Skip (not compiled in)
56: unit_number__scnprintf : Ok
57: mem2node : Ok
58: x86 rdpmc : Ok
59: Convert perf time to TSC : Ok
60: DWARF unwind : Ok
61: x86 instruction decoder - new instructions : Ok
62: Use vfs_getname probe to get syscall args filenames : Ok
63: Check open filename arg using perf trace + vfs_getname: Ok
64: probe libc's inet_pton & backtrace it with ping : Ok
65: 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_debug_O: make DEBUG=1
make_no_backtrace_O: make NO_BACKTRACE=1
make_with_babeltrace_O: make LIBBABELTRACE=1
make_no_libaudit_O: make NO_LIBAUDIT=1
make_no_libnuma_O: make NO_LIBNUMA=1
make_with_clangllvm_O: make LIBCLANGLLVM=1
make_static_O: make LDFLAGS=-static
make_no_libperl_O: make NO_LIBPERL=1
make_util_map_o_O: make util/map.o
make_no_libelf_O: make NO_LIBELF=1
make_no_slang_O: make NO_SLANG=1
make_install_prefix_slash_O: make install prefix=/tmp/krava/
make_no_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
make_help_O: make help
make_no_libbionic_O: make NO_LIBBIONIC=1
make_no_libunwind_O: make NO_LIBUNWIND=1
make_no_newt_O: make NO_NEWT=1
make_no_demangle_O: make NO_DEMANGLE=1
make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
make_perf_o_O: make perf.o
make_install_O: make install
make_util_pmu_bison_o_O: make util/pmu-bison.o
make_tags_O: make tags
make_install_prefix_O: make install prefix=/tmp/krava
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_clean_all_O: make clean all
make_no_gtk2_O: make NO_GTK2=1
make_no_auxtrace_O: make NO_AUXTRACE=1
make_no_libpython_O: make NO_LIBPYTHON=1
make_no_libbpf_O: make NO_LIBBPF=1
make_install_bin_O: make install-bin
make_doc_O: make doc
make_pure_O: make
OK
make: Leaving directory '/home/acme/git/perf/tools/perf'
$
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2018-05-19 10:54 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2018-05-19 10:54 UTC (permalink / raw)
To: Ingo Molnar
Cc: Clark Williams, linux-kernel, linux-perf-users,
Arnaldo Carvalho de Melo, Adrian Hunter, Alexander Shishkin,
Andi Kleen, Andy Lutomirski, Dave Hansen, David Ahern,
H . Peter Anvin, Jin Yao, Jiri Olsa, Joerg Roedel, Kan Liang,
Namhyung Kim, Naveen N . Rao, Peter Zijlstra, Ravi Bangoria,
Sandipan Das
Hi Ingo,
Please consider pulling,
- Arnaldo
Test results at the end of this message, as usual.
The following changes since commit 5aafae8d097e2161ee5c6a12ad532100f8885d2b:
Merge tag 'perf-core-for-mingo-4.18-20180516' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2018-05-16 17:56:43 +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-4.18-20180519
for you to fetch changes up to 19422a9f2a3be7f3a046285ffae4cbb571aa853a:
perf tools: Fix kernel_start for PTI on x86 (2018-05-19 06:42:51 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
- Record min/max LBR cycles (>= skylake) and add 'perf annotate' TUI
hotkey to show it (c) (Jin Yao)
- Fix machine->kernel_start for PTI on x86 (Adrian Hunter)
- Make machine->env->arch always available, e.g. in 'perf top', not
just when reading that info from perf.data files (Adrian Hunter)
- Reduce the number of files read at 'perf' start, leaving information such as
cacheline size, tracefs mount point determination, max_stack, etc, to be
lazily read as tools needs then (Arnaldo Carvalho de Melo)
- Fixup BPF include and examples install messages (Arnaldo Carvalho de Melo)
- Fixup callchain addresses and symbol offsets in 'perf script', to help
correlating with objdump output (Sandipan Das)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Adrian Hunter (2):
perf machine: Add machine__is() to identify machine arch
perf tools: Fix kernel_start for PTI on x86
Arnaldo Carvalho de Melo (12):
perf config: Call perf_config__init() lazily
tools lib api: The tracing_mnt variable doesn't need to be global
tools lib api: Unexport 'tracing_path' variable
tools lib api fs tracing_path: Introduce get/put_events_file() helpers
perf tools: Reuse the path to the tracepoint /events/ directory
perf parse-events: Use get/put_events_file()
tools lib api fs tracing_path: Introduce opendir() method
tools lib api fs tracing_path: Make tracing_events_path private
tools include compiler-gcc: Add __pure attribute helper
perf tools: Read the cache line size lazily
perf tools: No need to unconditionally read the max_stack sysctls
perf bpf: Fixup include and examples install messages
Jin Yao (2):
perf annotate: Record the min/max cycles
perf annotate: Create hotkey 'c' to show min/max cycles
Sandipan Das (2):
perf script: Show virtual addresses instead of offsets
perf script: Show symbol offsets by default
tools/include/linux/compiler-gcc.h | 3 +
tools/lib/api/fs/tracing_path.c | 40 +++++++++---
tools/lib/api/fs/tracing_path.h | 9 ++-
tools/perf/Makefile.perf | 2 +
tools/perf/builtin-script.c | 26 ++++----
tools/perf/builtin-top.c | 2 +-
tools/perf/builtin-trace.c | 2 +-
tools/perf/perf.c | 24 +------
tools/perf/tests/parse-events.c | 9 +--
.../tests/shell/record+probe_libc_inet_pton.sh | 12 ++--
tools/perf/ui/browsers/annotate.c | 8 +++
tools/perf/util/annotate.c | 51 ++++++++++++---
tools/perf/util/annotate.h | 11 +++-
tools/perf/util/config.c | 16 ++---
tools/perf/util/config.h | 1 -
tools/perf/util/env.c | 18 ++++++
tools/perf/util/env.h | 2 +
tools/perf/util/evsel.c | 2 +-
tools/perf/util/machine.c | 18 +++++-
tools/perf/util/machine.h | 2 +
tools/perf/util/parse-events.c | 73 +++++++++++++---------
tools/perf/util/probe-file.c | 3 +-
tools/perf/util/sort.c | 4 +-
tools/perf/util/sort.h | 4 +-
tools/perf/util/trace-event-info.c | 11 ++--
tools/perf/util/trace-event.c | 8 ++-
tools/perf/util/util.c | 34 +++++++++-
tools/perf/util/util.h | 4 +-
28 files changed, 279 insertions(+), 120 deletions(-)
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, and building with LIBCLANGLLVM=1
(built-in clang) with gcc and clang when clang and its devel libraries
are installed.
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-28)
7 amazonlinux:2 : Ok gcc (GCC) 7.3.1 20180303 (Red Hat 7.3.1-5)
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+deb9u1) 6.3.0 20170516
16 debian:experimental : Ok gcc (Debian 7.3.0-19) 7.3.0
17 debian:experimental-x-arm64 : Ok aarch64-linux-gnu-gcc (Debian 7.3.0-19) 7.3.0
18 debian:experimental-x-mips : Ok mips-linux-gnu-gcc (Debian 7.3.0-19) 7.3.0
19 debian:experimental-x-mips64 : Ok mips64-linux-gnuabi64-gcc (Debian 7.3.0-18) 7.3.0
20 debian:experimental-x-mipsel : Ok mipsel-linux-gnu-gcc (Debian 7.3.0-19) 7.3.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.3.1 20180130 (Red Hat 7.3.1-2)
29 fedora:27 : Ok gcc (GCC) 7.3.1 20180303 (Red Hat 7.3.1-5)
30 fedora:28 : Ok gcc (GCC) 8.1.1 20180502 (Red Hat 8.1.1-1)
31 fedora:rawhide : Ok gcc (GCC) 8.0.1 20180324 (Red Hat 8.0.1-0.20)
32 gentoo-stage3-amd64:latest : Ok gcc (Gentoo 6.4.0-r1 p1.3) 6.4.0
33 mageia:5 : Ok gcc (GCC) 4.9.2
34 mageia:6 : Ok gcc (Mageia 5.5.0-1.mga6) 5.5.0
35 opensuse:42.1 : Ok gcc (SUSE Linux) 4.8.5
36 opensuse:42.2 : Ok gcc (SUSE Linux) 4.8.5
37 opensuse:42.3 : Ok gcc (SUSE Linux) 4.8.5
38 opensuse:tumbleweed : Ok gcc (SUSE Linux) 7.3.1 20180323 [gcc-7-branch revision 258812]
39 oraclelinux:6 : Ok gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-18.0.7)
40 oraclelinux:7 : Ok gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-28.0.1)
41 ubuntu:12.04.5 : Ok gcc (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
42 ubuntu:14.04.4 : Ok gcc (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4
43 ubuntu:14.04.4-x-linaro-arm64 : Ok aarch64-linux-gnu-gcc (Linaro GCC 5.5-2017.10) 5.5.0
44 ubuntu:16.04 : Ok gcc (Ubuntu 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
45 ubuntu:16.04-x-arm : Ok arm-linux-gnueabihf-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
46 ubuntu:16.04-x-arm64 : Ok aarch64-linux-gnu-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
47 ubuntu:16.04-x-powerpc : Ok powerpc-linux-gnu-gcc (Ubuntu 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
48 ubuntu:16.04-x-powerpc64 : Ok powerpc64-linux-gnu-gcc (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
49 ubuntu:16.04-x-powerpc64el : Ok powerpc64le-linux-gnu-gcc (Ubuntu/IBM 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609
50 ubuntu:16.04-x-s390 : Ok s390x-linux-gnu-gcc (Ubuntu 5.4.0-6ubuntu1~16.04.9) 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.2) 7.2.0
54 ubuntu:18.04 : Ok gcc (Ubuntu 7.3.0-16ubuntu3) 7.3.0
#
# uname -a
Linux seventh 4.17.0-rc5-00069-g3acf4e395260 #2 SMP Fri May 18 12:13:59 -03 2018 x86_64 x86_64 x86_64 GNU/Linux
# perf --version
perf version 4.17.rc5.g19422a9
# 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: Breakpoint accounting : Ok
22: Number of exit events of a simple workload : Ok
23: Software clock events period values : Ok
24: Object code reading : Ok
25: Sample parsing : Ok
26: Use a dummy software event to keep tracking : Ok
27: Parse with no sample_id_all bit set : Ok
28: Filter hist entries : Ok
29: Lookup mmap thread : Ok
30: Share thread mg : Ok
31: Sort output of hist entries : Ok
32: Cumulate child hist entries : Ok
33: Track with sched_switch : Ok
34: Filter fds with revents mask in a fdarray : Ok
35: Add fd to a fdarray, making it autogrow : Ok
36: kmod_path__parse : Ok
37: Thread map : Ok
38: LLVM search and compile :
38.1: Basic BPF llvm compile : Ok
38.2: kbuild searching : Ok
38.3: Compile source for BPF prologue generation : Ok
38.4: Compile source for BPF relocation : Ok
39: Session topology : Ok
40: BPF filter :
40.1: Basic BPF filtering : Ok
40.2: BPF pinning : Ok
40.3: BPF prologue generation : Ok
40.4: BPF relocation checker : Ok
41: Synthesize thread map : Ok
42: Remove thread map : Ok
43: Synthesize cpu map : Ok
44: Synthesize stat config : Ok
45: Synthesize stat : Ok
46: Synthesize stat round : Ok
47: Synthesize attr update : Ok
48: Event times : Ok
49: Read backward ring buffer : Ok
50: Print cpu map : Ok
51: Probe SDT events : Ok
52: is_printable_array : Ok
53: Print bitmap : Ok
54: perf hooks : Ok
55: builtin clang support : Skip (not compiled in)
56: unit_number__scnprintf : Ok
57: mem2node : Ok
58: x86 rdpmc : Ok
59: Convert perf time to TSC : Ok
60: DWARF unwind : Ok
61: x86 instruction decoder - new instructions : Ok
62: Use vfs_getname probe to get syscall args filenames : Ok
63: Check open filename arg using perf trace + vfs_getname: Ok
64: probe libc's inet_pton & backtrace it with ping : Ok
65: 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_debug_O: make DEBUG=1
make_no_backtrace_O: make NO_BACKTRACE=1
make_with_babeltrace_O: make LIBBABELTRACE=1
make_no_libaudit_O: make NO_LIBAUDIT=1
make_no_libnuma_O: make NO_LIBNUMA=1
make_with_clangllvm_O: make LIBCLANGLLVM=1
make_static_O: make LDFLAGS=-static
make_no_libperl_O: make NO_LIBPERL=1
make_util_map_o_O: make util/map.o
make_no_libelf_O: make NO_LIBELF=1
make_no_slang_O: make NO_SLANG=1
make_install_prefix_slash_O: make install prefix=/tmp/krava/
make_no_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
make_help_O: make help
make_no_libbionic_O: make NO_LIBBIONIC=1
make_no_libunwind_O: make NO_LIBUNWIND=1
make_no_newt_O: make NO_NEWT=1
make_no_demangle_O: make NO_DEMANGLE=1
make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
make_perf_o_O: make perf.o
make_install_O: make install
make_util_pmu_bison_o_O: make util/pmu-bison.o
make_tags_O: make tags
make_install_prefix_O: make install prefix=/tmp/krava
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_clean_all_O: make clean all
make_no_gtk2_O: make NO_GTK2=1
make_no_auxtrace_O: make NO_AUXTRACE=1
make_no_libpython_O: make NO_LIBPYTHON=1
make_no_libbpf_O: make NO_LIBBPF=1
make_install_bin_O: make install-bin
make_doc_O: make doc
make_pure_O: make
OK
make: Leaving directory '/home/acme/git/perf/tools/perf'
$
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2018-05-19 10:54 ` Arnaldo Carvalho de Melo
@ 2018-05-19 11:33 ` Ingo Molnar
-1 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2018-05-19 11:33 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: Clark Williams, linux-kernel, linux-perf-users, Adrian Hunter,
Alexander Shishkin, Andi Kleen, Andy Lutomirski, Dave Hansen,
David Ahern, H . Peter Anvin, Jin Yao, Jiri Olsa, Joerg Roedel,
Kan Liang, Namhyung Kim, Naveen N . Rao, Peter Zijlstra,
Ravi Bangoria, Sandipan Das, Taeung Song, Thomas Gleixner,
Wang Nan, x86, Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> Test results at the end of this message, as usual.
>
> The following changes since commit 5aafae8d097e2161ee5c6a12ad532100f8885d2b:
>
> Merge tag 'perf-core-for-mingo-4.18-20180516' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2018-05-16 17:56:43 +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-4.18-20180519
>
> for you to fetch changes up to 19422a9f2a3be7f3a046285ffae4cbb571aa853a:
>
> perf tools: Fix kernel_start for PTI on x86 (2018-05-19 06:42:51 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> - Record min/max LBR cycles (>= skylake) and add 'perf annotate' TUI
> hotkey to show it (c) (Jin Yao)
>
> - Fix machine->kernel_start for PTI on x86 (Adrian Hunter)
>
> - Make machine->env->arch always available, e.g. in 'perf top', not
> just when reading that info from perf.data files (Adrian Hunter)
>
> - Reduce the number of files read at 'perf' start, leaving information such as
> cacheline size, tracefs mount point determination, max_stack, etc, to be
> lazily read as tools needs then (Arnaldo Carvalho de Melo)
>
> - Fixup BPF include and examples install messages (Arnaldo Carvalho de Melo)
>
> - Fixup callchain addresses and symbol offsets in 'perf script', to help
> correlating with objdump output (Sandipan Das)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Adrian Hunter (2):
> perf machine: Add machine__is() to identify machine arch
> perf tools: Fix kernel_start for PTI on x86
>
> Arnaldo Carvalho de Melo (12):
> perf config: Call perf_config__init() lazily
> tools lib api: The tracing_mnt variable doesn't need to be global
> tools lib api: Unexport 'tracing_path' variable
> tools lib api fs tracing_path: Introduce get/put_events_file() helpers
> perf tools: Reuse the path to the tracepoint /events/ directory
> perf parse-events: Use get/put_events_file()
> tools lib api fs tracing_path: Introduce opendir() method
> tools lib api fs tracing_path: Make tracing_events_path private
> tools include compiler-gcc: Add __pure attribute helper
> perf tools: Read the cache line size lazily
> perf tools: No need to unconditionally read the max_stack sysctls
> perf bpf: Fixup include and examples install messages
>
> Jin Yao (2):
> perf annotate: Record the min/max cycles
> perf annotate: Create hotkey 'c' to show min/max cycles
>
> Sandipan Das (2):
> perf script: Show virtual addresses instead of offsets
> perf script: Show symbol offsets by default
>
> tools/include/linux/compiler-gcc.h | 3 +
> tools/lib/api/fs/tracing_path.c | 40 +++++++++---
> tools/lib/api/fs/tracing_path.h | 9 ++-
> tools/perf/Makefile.perf | 2 +
> tools/perf/builtin-script.c | 26 ++++----
> tools/perf/builtin-top.c | 2 +-
> tools/perf/builtin-trace.c | 2 +-
> tools/perf/perf.c | 24 +------
> tools/perf/tests/parse-events.c | 9 +--
> .../tests/shell/record+probe_libc_inet_pton.sh | 12 ++--
> tools/perf/ui/browsers/annotate.c | 8 +++
> tools/perf/util/annotate.c | 51 ++++++++++++---
> tools/perf/util/annotate.h | 11 +++-
> tools/perf/util/config.c | 16 ++---
> tools/perf/util/config.h | 1 -
> tools/perf/util/env.c | 18 ++++++
> tools/perf/util/env.h | 2 +
> tools/perf/util/evsel.c | 2 +-
> tools/perf/util/machine.c | 18 +++++-
> tools/perf/util/machine.h | 2 +
> tools/perf/util/parse-events.c | 73 +++++++++++++---------
> tools/perf/util/probe-file.c | 3 +-
> tools/perf/util/sort.c | 4 +-
> tools/perf/util/sort.h | 4 +-
> tools/perf/util/trace-event-info.c | 11 ++--
> tools/perf/util/trace-event.c | 8 ++-
> tools/perf/util/util.c | 34 +++++++++-
> tools/perf/util/util.h | 4 +-
> 28 files changed, 279 insertions(+), 120 deletions(-)
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
@ 2018-05-19 11:33 ` Ingo Molnar
0 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2018-05-19 11:33 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: Clark Williams, linux-kernel, linux-perf-users, Adrian Hunter,
Alexander Shishkin, Andi Kleen, Andy Lutomirski, Dave Hansen,
David Ahern, H . Peter Anvin, Jin Yao, Jiri Olsa, Joerg Roedel,
Kan Liang, Namhyung Kim, Naveen N . Rao, Peter Zijlstra,
Ravi Bangoria, Sandipan Das, Taeung Song
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> Test results at the end of this message, as usual.
>
> The following changes since commit 5aafae8d097e2161ee5c6a12ad532100f8885d2b:
>
> Merge tag 'perf-core-for-mingo-4.18-20180516' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2018-05-16 17:56:43 +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-4.18-20180519
>
> for you to fetch changes up to 19422a9f2a3be7f3a046285ffae4cbb571aa853a:
>
> perf tools: Fix kernel_start for PTI on x86 (2018-05-19 06:42:51 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> - Record min/max LBR cycles (>= skylake) and add 'perf annotate' TUI
> hotkey to show it (c) (Jin Yao)
>
> - Fix machine->kernel_start for PTI on x86 (Adrian Hunter)
>
> - Make machine->env->arch always available, e.g. in 'perf top', not
> just when reading that info from perf.data files (Adrian Hunter)
>
> - Reduce the number of files read at 'perf' start, leaving information such as
> cacheline size, tracefs mount point determination, max_stack, etc, to be
> lazily read as tools needs then (Arnaldo Carvalho de Melo)
>
> - Fixup BPF include and examples install messages (Arnaldo Carvalho de Melo)
>
> - Fixup callchain addresses and symbol offsets in 'perf script', to help
> correlating with objdump output (Sandipan Das)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Adrian Hunter (2):
> perf machine: Add machine__is() to identify machine arch
> perf tools: Fix kernel_start for PTI on x86
>
> Arnaldo Carvalho de Melo (12):
> perf config: Call perf_config__init() lazily
> tools lib api: The tracing_mnt variable doesn't need to be global
> tools lib api: Unexport 'tracing_path' variable
> tools lib api fs tracing_path: Introduce get/put_events_file() helpers
> perf tools: Reuse the path to the tracepoint /events/ directory
> perf parse-events: Use get/put_events_file()
> tools lib api fs tracing_path: Introduce opendir() method
> tools lib api fs tracing_path: Make tracing_events_path private
> tools include compiler-gcc: Add __pure attribute helper
> perf tools: Read the cache line size lazily
> perf tools: No need to unconditionally read the max_stack sysctls
> perf bpf: Fixup include and examples install messages
>
> Jin Yao (2):
> perf annotate: Record the min/max cycles
> perf annotate: Create hotkey 'c' to show min/max cycles
>
> Sandipan Das (2):
> perf script: Show virtual addresses instead of offsets
> perf script: Show symbol offsets by default
>
> tools/include/linux/compiler-gcc.h | 3 +
> tools/lib/api/fs/tracing_path.c | 40 +++++++++---
> tools/lib/api/fs/tracing_path.h | 9 ++-
> tools/perf/Makefile.perf | 2 +
> tools/perf/builtin-script.c | 26 ++++----
> tools/perf/builtin-top.c | 2 +-
> tools/perf/builtin-trace.c | 2 +-
> tools/perf/perf.c | 24 +------
> tools/perf/tests/parse-events.c | 9 +--
> .../tests/shell/record+probe_libc_inet_pton.sh | 12 ++--
> tools/perf/ui/browsers/annotate.c | 8 +++
> tools/perf/util/annotate.c | 51 ++++++++++++---
> tools/perf/util/annotate.h | 11 +++-
> tools/perf/util/config.c | 16 ++---
> tools/perf/util/config.h | 1 -
> tools/perf/util/env.c | 18 ++++++
> tools/perf/util/env.h | 2 +
> tools/perf/util/evsel.c | 2 +-
> tools/perf/util/machine.c | 18 +++++-
> tools/perf/util/machine.h | 2 +
> tools/perf/util/parse-events.c | 73 +++++++++++++---------
> tools/perf/util/probe-file.c | 3 +-
> tools/perf/util/sort.c | 4 +-
> tools/perf/util/sort.h | 4 +-
> tools/perf/util/trace-event-info.c | 11 ++--
> tools/perf/util/trace-event.c | 8 ++-
> tools/perf/util/util.c | 34 +++++++++-
> tools/perf/util/util.h | 4 +-
> 28 files changed, 279 insertions(+), 120 deletions(-)
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2017-08-29 19:42 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2017-08-29 19:42 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, linux-perf-users, Arnaldo Carvalho de Melo,
Adrian Hunter, Alexander Shishkin, Alexis Berlemont, Andi Kleen,
Andy Lutomirski, Arnd Bergmann, Borislav Petkov, Dave Hansen,
David Ahern, David Carrillo-Cisneros, David Tolnay, Hanjun Guo,
Hemant Kumar, Jack Henschel, Janakarajan Natarajan, Jiri Olsa,
Joe Mario, Li Bin, Mark Rutland, Masami Hiramatsu, Milian Wolff,
Namhyung Kim, Paul Turner, Peter Zijlstra, Stephane Eranian,
Wang Nan, zhangmengting, 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 b00233b5306512a09e339d69ef5e390a77f2d302:
perf/x86: Export some PMU attributes in caps/ directory (2017-08-25 11:04:20 +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-4.14-20170829
for you to fetch changes up to b2f7605076d6cdd68162c42c34caadafbbe4c69f:
perf symbols: Fix plt entry calculation for ARM and AARCH64 (2017-08-29 11:41:27 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
- Fix remote HITM detection for Skylake in 'perf c2c' (Jiri Olsa)
- Fixes for the handling of PERF_RECORD_READ records (Jiri Olsa)
- Fix kprobes blackist symbol lookup in 'perf probe' (Li Bin)
- The PLT header and entry sizes are not the same in !x86, fix it for ARM and
AARCH64 (Li Bin)
- Beautify pkey_{alloc,free,mprotect} arguments in 'perf trace' (Arnaldo Carvalho de Melo)
- Fix CC, AR, LD external definition, allow flex and bison to be
externally defined and other related Makefile fixes (David Carrillo-Cisneros)
- Sync cpu features kernel ABI headers with tooling headers (Arnaldo Carvalho de Melo)
- Fix path to PMU formats in 'perf stat' documentation (Jack Henschel)
- Fix static build with newer toolchains (Jiri Olsa)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Arnaldo Carvalho de Melo (2):
tools headers: Sync cpu features kernel ABI headers with tooling headers
perf trace beauty: Beautify pkey_{alloc,free,mprotect} arguments
David Carrillo-Cisneros (5):
tools build tests: Don't hardcode gcc name
perf tools: Allow external definition of flex and bison binary names
tools lib: Allow external definition of CC, AR and LD
perf tools: Robustify detection of clang binary
perf tools: Pass full path of FEATURES_DUMP
Jack Henschel (1):
perf stat: Fix path to PMU formats in documentation
Jiri Olsa (8):
perf tools: Fix static build with newer toolchains
perf c2c: Fix remote HITM detection for Skylake
perf record: Set read_format for inherit_stat
perf report: Add dump_read function
perf values: Fix thread index bug
perf values: Fix allocation check
perf values: Zero value buffers
perf report: Group stat values on global event id
Li Bin (2):
perf probe: Fix kprobe blacklist checking condition
perf symbols: Fix plt entry calculation for ARM and AARCH64
tools/arch/x86/include/asm/cpufeatures.h | 5 +--
tools/arch/x86/include/asm/disabled-features.h | 4 +-
tools/build/tests/ex/Makefile | 2 +-
tools/lib/api/Makefile | 8 ++--
tools/lib/subcmd/Makefile | 2 +-
tools/perf/Documentation/perf-stat.txt | 4 +-
tools/perf/Makefile.config | 4 +-
tools/perf/Makefile.perf | 26 ++++++++---
tools/perf/builtin-report.c | 6 +--
tools/perf/builtin-trace.c | 8 ++++
tools/perf/trace/beauty/Build | 1 +
tools/perf/trace/beauty/beauty.h | 3 ++
tools/perf/trace/beauty/pkey_alloc.c | 50 ++++++++++++++++++++++
.../perf/trace/beauty/pkey_alloc_access_rights.sh | 10 +++++
tools/perf/util/evsel.c | 7 ++-
tools/perf/util/intel-pt-decoder/Build | 2 +-
tools/perf/util/mem-events.c | 11 ++++-
tools/perf/util/probe-event.c | 2 +-
tools/perf/util/session.c | 25 +++++++++++
tools/perf/util/symbol-elf.c | 27 +++++++++---
tools/perf/util/values.c | 17 +++++---
tools/scripts/Makefile.include | 4 +-
22 files changed, 185 insertions(+), 43 deletions(-)
create mode 100644 tools/perf/trace/beauty/pkey_alloc.c
create mode 100755 tools/perf/trace/beauty/pkey_alloc_access_rights.sh
Test results:
The first ones are container (docker) based builds of tools/perf with and
without libelf support, objtool where it is supported and samples/bpf/, ditto.
Where clang is available, it is also used to build perf with/without libelf.
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.
The 'perf test' also runs shell scripts exercising the tools, checking
if they affect the system in certain ways, like setting up kprobes and
uprobes, request callchains for well known programs and check that they
are the expected ones, see if 'perf trace' beautifies system call
arguments correctly, etc.
Additionally, a new set of tests, script based, runs the tools in a live system,
setting probes in place that then gets used by 'perf trace', with its output
compared against expected results.
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
2 alpine:3.5: Ok
3 alpine:3.6: Ok
4 alpine:edge: Ok
5 android-ndk:r12b-arm: Ok
6 archlinux:latest: Ok
7 centos:5: Ok
8 centos:6: Ok
9 centos:7: Ok
10 debian:7: Ok
11 debian:8: Ok
12 debian:9: Ok
13 debian:experimental: Ok
14 debian:experimental-x-arm64: Ok
15 debian:experimental-x-mips: Ok
16 debian:experimental-x-mips64: Ok
17 debian:experimental-x-mipsel: Ok
18 fedora:20: Ok
19 fedora:21: Ok
20 fedora:22: Ok
21 fedora:23: Ok
22 fedora:24: Ok
23 fedora:24-x-ARC-uClibc: Ok
24 fedora:25: Ok
25 fedora:26: Ok
26 fedora:rawhide: Ok
27 mageia:5: Ok
28 opensuse:13.2: Ok
29 opensuse:42.1: Ok
30 opensuse:42.2: Ok
31 opensuse:42.3: Ok
32 opensuse:tumbleweed: Ok
33 oraclelinux:6: Ok
34 oraclelinux:7: Ok
35 ubuntu:12.04.5: Ok
36 ubuntu:14.04.4: Ok
37 ubuntu:14.04.4-x-linaro-arm64: Ok
38 ubuntu:15.10: Ok
39 ubuntu:16.04: Ok
40 ubuntu:16.04-x-arm: Ok
41 ubuntu:16.04-x-arm64: Ok
42 ubuntu:16.04-x-powerpc: Ok
43 ubuntu:16.04-x-powerpc64: Ok
44 ubuntu:16.04-x-powerpc64el: Ok
45 ubuntu:16.04-x-s390: Ok
46 ubuntu:16.10: Ok
47 ubuntu:17.04: Ok
48 ubuntu:17.10: Ok
#
# uname -a
Linux jouet 4.13.0-rc4+ #2 SMP Fri Aug 11 12:39:09 -03 2017 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: x86 rdpmc : Ok
57: Convert perf time to TSC : Ok
58: DWARF unwind : Ok
59: x86 instruction decoder - new instructions : Ok
60: Intel cqm nmi context read : Skip
61: Use vfs_getname probe to get syscall args filenames : Ok
62: probe libc's inet_pton & backtrace it with ping : Ok
63: Check open filename arg using perf trace + vfs_getname: Ok
64: Add vfs_getname probe to get syscall args filenames : Ok
#
$ make -C tools/perf build-test
make: Entering directory '/home/acme/git/linux/tools/perf'
- tarpkg: ./tests/perf-targz-src-pkg .
make_install_prefix_slash_O: make install prefix=/tmp/krava/
make_no_backtrace_O: make NO_BACKTRACE=1
make_debug_O: make DEBUG=1
make_util_pmu_bison_o_O: make util/pmu-bison.o
make_no_demangle_O: make NO_DEMANGLE=1
make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
make_no_auxtrace_O: make NO_AUXTRACE=1
make_tags_O: make tags
make_install_prefix_O: make install prefix=/tmp/krava
make_no_gtk2_O: make NO_GTK2=1
make_with_babeltrace_O: make LIBBABELTRACE=1
make_no_libaudit_O: make NO_LIBAUDIT=1
make_no_libpython_O: make NO_LIBPYTHON=1
make_static_O: make LDFLAGS=-static
make_util_map_o_O: make util/map.o
make_no_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
make_no_libunwind_O: make NO_LIBUNWIND=1
make_install_O: make install
make_no_libelf_O: make NO_LIBELF=1
make_pure_O: make
make_no_libperl_O: make NO_LIBPERL=1
make_perf_o_O: make perf.o
make_with_clangllvm_O: make LIBCLANGLLVM=1
make_install_bin_O: make install-bin
make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
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_newt_O: make NO_NEWT=1
make_doc_O: make doc
make_no_libbpf_O: make NO_LIBBPF=1
make_clean_all_O: make clean all
make_help_O: make help
make_no_libbionic_O: make NO_LIBBIONIC=1
make_no_libnuma_O: make NO_LIBNUMA=1
make_no_slang_O: make NO_SLANG=1
OK
make: Leaving directory '/home/acme/git/linux/tools/perf'
$
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2017-08-29 19:42 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2017-08-29 19:42 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, linux-perf-users, Arnaldo Carvalho de Melo,
Adrian Hunter, Alexander Shishkin, Alexis Berlemont, Andi Kleen,
Andy Lutomirski, Arnd Bergmann, Borislav Petkov, Dave Hansen,
David Ahern, David Carrillo-Cisneros, David Tolnay, Hanjun Guo,
Hemant Kumar, Jack Henschel, Janakarajan Natarajan, Jiri Olsa,
Joe Mario
Hi Ingo,
Please consider pulling,
- Arnaldo
Test results at the end of this message, as usual.
The following changes since commit b00233b5306512a09e339d69ef5e390a77f2d302:
perf/x86: Export some PMU attributes in caps/ directory (2017-08-25 11:04:20 +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-4.14-20170829
for you to fetch changes up to b2f7605076d6cdd68162c42c34caadafbbe4c69f:
perf symbols: Fix plt entry calculation for ARM and AARCH64 (2017-08-29 11:41:27 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
- Fix remote HITM detection for Skylake in 'perf c2c' (Jiri Olsa)
- Fixes for the handling of PERF_RECORD_READ records (Jiri Olsa)
- Fix kprobes blackist symbol lookup in 'perf probe' (Li Bin)
- The PLT header and entry sizes are not the same in !x86, fix it for ARM and
AARCH64 (Li Bin)
- Beautify pkey_{alloc,free,mprotect} arguments in 'perf trace' (Arnaldo Carvalho de Melo)
- Fix CC, AR, LD external definition, allow flex and bison to be
externally defined and other related Makefile fixes (David Carrillo-Cisneros)
- Sync cpu features kernel ABI headers with tooling headers (Arnaldo Carvalho de Melo)
- Fix path to PMU formats in 'perf stat' documentation (Jack Henschel)
- Fix static build with newer toolchains (Jiri Olsa)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Arnaldo Carvalho de Melo (2):
tools headers: Sync cpu features kernel ABI headers with tooling headers
perf trace beauty: Beautify pkey_{alloc,free,mprotect} arguments
David Carrillo-Cisneros (5):
tools build tests: Don't hardcode gcc name
perf tools: Allow external definition of flex and bison binary names
tools lib: Allow external definition of CC, AR and LD
perf tools: Robustify detection of clang binary
perf tools: Pass full path of FEATURES_DUMP
Jack Henschel (1):
perf stat: Fix path to PMU formats in documentation
Jiri Olsa (8):
perf tools: Fix static build with newer toolchains
perf c2c: Fix remote HITM detection for Skylake
perf record: Set read_format for inherit_stat
perf report: Add dump_read function
perf values: Fix thread index bug
perf values: Fix allocation check
perf values: Zero value buffers
perf report: Group stat values on global event id
Li Bin (2):
perf probe: Fix kprobe blacklist checking condition
perf symbols: Fix plt entry calculation for ARM and AARCH64
tools/arch/x86/include/asm/cpufeatures.h | 5 +--
tools/arch/x86/include/asm/disabled-features.h | 4 +-
tools/build/tests/ex/Makefile | 2 +-
tools/lib/api/Makefile | 8 ++--
tools/lib/subcmd/Makefile | 2 +-
tools/perf/Documentation/perf-stat.txt | 4 +-
tools/perf/Makefile.config | 4 +-
tools/perf/Makefile.perf | 26 ++++++++---
tools/perf/builtin-report.c | 6 +--
tools/perf/builtin-trace.c | 8 ++++
tools/perf/trace/beauty/Build | 1 +
tools/perf/trace/beauty/beauty.h | 3 ++
tools/perf/trace/beauty/pkey_alloc.c | 50 ++++++++++++++++++++++
.../perf/trace/beauty/pkey_alloc_access_rights.sh | 10 +++++
tools/perf/util/evsel.c | 7 ++-
tools/perf/util/intel-pt-decoder/Build | 2 +-
tools/perf/util/mem-events.c | 11 ++++-
tools/perf/util/probe-event.c | 2 +-
tools/perf/util/session.c | 25 +++++++++++
tools/perf/util/symbol-elf.c | 27 +++++++++---
tools/perf/util/values.c | 17 +++++---
tools/scripts/Makefile.include | 4 +-
22 files changed, 185 insertions(+), 43 deletions(-)
create mode 100644 tools/perf/trace/beauty/pkey_alloc.c
create mode 100755 tools/perf/trace/beauty/pkey_alloc_access_rights.sh
Test results:
The first ones are container (docker) based builds of tools/perf with and
without libelf support, objtool where it is supported and samples/bpf/, ditto.
Where clang is available, it is also used to build perf with/without libelf.
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.
The 'perf test' also runs shell scripts exercising the tools, checking
if they affect the system in certain ways, like setting up kprobes and
uprobes, request callchains for well known programs and check that they
are the expected ones, see if 'perf trace' beautifies system call
arguments correctly, etc.
Additionally, a new set of tests, script based, runs the tools in a live system,
setting probes in place that then gets used by 'perf trace', with its output
compared against expected results.
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
2 alpine:3.5: Ok
3 alpine:3.6: Ok
4 alpine:edge: Ok
5 android-ndk:r12b-arm: Ok
6 archlinux:latest: Ok
7 centos:5: Ok
8 centos:6: Ok
9 centos:7: Ok
10 debian:7: Ok
11 debian:8: Ok
12 debian:9: Ok
13 debian:experimental: Ok
14 debian:experimental-x-arm64: Ok
15 debian:experimental-x-mips: Ok
16 debian:experimental-x-mips64: Ok
17 debian:experimental-x-mipsel: Ok
18 fedora:20: Ok
19 fedora:21: Ok
20 fedora:22: Ok
21 fedora:23: Ok
22 fedora:24: Ok
23 fedora:24-x-ARC-uClibc: Ok
24 fedora:25: Ok
25 fedora:26: Ok
26 fedora:rawhide: Ok
27 mageia:5: Ok
28 opensuse:13.2: Ok
29 opensuse:42.1: Ok
30 opensuse:42.2: Ok
31 opensuse:42.3: Ok
32 opensuse:tumbleweed: Ok
33 oraclelinux:6: Ok
34 oraclelinux:7: Ok
35 ubuntu:12.04.5: Ok
36 ubuntu:14.04.4: Ok
37 ubuntu:14.04.4-x-linaro-arm64: Ok
38 ubuntu:15.10: Ok
39 ubuntu:16.04: Ok
40 ubuntu:16.04-x-arm: Ok
41 ubuntu:16.04-x-arm64: Ok
42 ubuntu:16.04-x-powerpc: Ok
43 ubuntu:16.04-x-powerpc64: Ok
44 ubuntu:16.04-x-powerpc64el: Ok
45 ubuntu:16.04-x-s390: Ok
46 ubuntu:16.10: Ok
47 ubuntu:17.04: Ok
48 ubuntu:17.10: Ok
#
# uname -a
Linux jouet 4.13.0-rc4+ #2 SMP Fri Aug 11 12:39:09 -03 2017 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: x86 rdpmc : Ok
57: Convert perf time to TSC : Ok
58: DWARF unwind : Ok
59: x86 instruction decoder - new instructions : Ok
60: Intel cqm nmi context read : Skip
61: Use vfs_getname probe to get syscall args filenames : Ok
62: probe libc's inet_pton & backtrace it with ping : Ok
63: Check open filename arg using perf trace + vfs_getname: Ok
64: Add vfs_getname probe to get syscall args filenames : Ok
#
$ make -C tools/perf build-test
make: Entering directory '/home/acme/git/linux/tools/perf'
- tarpkg: ./tests/perf-targz-src-pkg .
make_install_prefix_slash_O: make install prefix=/tmp/krava/
make_no_backtrace_O: make NO_BACKTRACE=1
make_debug_O: make DEBUG=1
make_util_pmu_bison_o_O: make util/pmu-bison.o
make_no_demangle_O: make NO_DEMANGLE=1
make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
make_no_auxtrace_O: make NO_AUXTRACE=1
make_tags_O: make tags
make_install_prefix_O: make install prefix=/tmp/krava
make_no_gtk2_O: make NO_GTK2=1
make_with_babeltrace_O: make LIBBABELTRACE=1
make_no_libaudit_O: make NO_LIBAUDIT=1
make_no_libpython_O: make NO_LIBPYTHON=1
make_static_O: make LDFLAGS=-static
make_util_map_o_O: make util/map.o
make_no_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
make_no_libunwind_O: make NO_LIBUNWIND=1
make_install_O: make install
make_no_libelf_O: make NO_LIBELF=1
make_pure_O: make
make_no_libperl_O: make NO_LIBPERL=1
make_perf_o_O: make perf.o
make_with_clangllvm_O: make LIBCLANGLLVM=1
make_install_bin_O: make install-bin
make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
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_newt_O: make NO_NEWT=1
make_doc_O: make doc
make_no_libbpf_O: make NO_LIBBPF=1
make_clean_all_O: make clean all
make_help_O: make help
make_no_libbionic_O: make NO_LIBBIONIC=1
make_no_libnuma_O: make NO_LIBNUMA=1
make_no_slang_O: make NO_SLANG=1
OK
make: Leaving directory '/home/acme/git/linux/tools/perf'
$
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2017-08-29 19:42 ` Arnaldo Carvalho de Melo
@ 2017-08-29 21:15 ` Ingo Molnar
-1 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2017-08-29 21:15 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, linux-perf-users, Adrian Hunter,
Alexander Shishkin, Alexis Berlemont, Andi Kleen,
Andy Lutomirski, Arnd Bergmann, Borislav Petkov, Dave Hansen,
David Ahern, David Carrillo-Cisneros, David Tolnay, Hanjun Guo,
Hemant Kumar, Jack Henschel, Janakarajan Natarajan, Jiri Olsa,
Joe Mario, Li Bin, Mark Rutland, Masami Hiramatsu, Milian Wolff,
Namhyung Kim, Paul Turner, Peter Zijlstra, Stephane Eranian,
Wang Nan, zhangmengting, Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> Test results at the end of this message, as usual.
>
> The following changes since commit b00233b5306512a09e339d69ef5e390a77f2d302:
>
> perf/x86: Export some PMU attributes in caps/ directory (2017-08-25 11:04:20 +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-4.14-20170829
>
> for you to fetch changes up to b2f7605076d6cdd68162c42c34caadafbbe4c69f:
>
> perf symbols: Fix plt entry calculation for ARM and AARCH64 (2017-08-29 11:41:27 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> - Fix remote HITM detection for Skylake in 'perf c2c' (Jiri Olsa)
>
> - Fixes for the handling of PERF_RECORD_READ records (Jiri Olsa)
>
> - Fix kprobes blackist symbol lookup in 'perf probe' (Li Bin)
>
> - The PLT header and entry sizes are not the same in !x86, fix it for ARM and
> AARCH64 (Li Bin)
>
> - Beautify pkey_{alloc,free,mprotect} arguments in 'perf trace' (Arnaldo Carvalho de Melo)
>
> - Fix CC, AR, LD external definition, allow flex and bison to be
> externally defined and other related Makefile fixes (David Carrillo-Cisneros)
>
> - Sync cpu features kernel ABI headers with tooling headers (Arnaldo Carvalho de Melo)
>
> - Fix path to PMU formats in 'perf stat' documentation (Jack Henschel)
>
> - Fix static build with newer toolchains (Jiri Olsa)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Arnaldo Carvalho de Melo (2):
> tools headers: Sync cpu features kernel ABI headers with tooling headers
> perf trace beauty: Beautify pkey_{alloc,free,mprotect} arguments
>
> David Carrillo-Cisneros (5):
> tools build tests: Don't hardcode gcc name
> perf tools: Allow external definition of flex and bison binary names
> tools lib: Allow external definition of CC, AR and LD
> perf tools: Robustify detection of clang binary
> perf tools: Pass full path of FEATURES_DUMP
>
> Jack Henschel (1):
> perf stat: Fix path to PMU formats in documentation
>
> Jiri Olsa (8):
> perf tools: Fix static build with newer toolchains
> perf c2c: Fix remote HITM detection for Skylake
> perf record: Set read_format for inherit_stat
> perf report: Add dump_read function
> perf values: Fix thread index bug
> perf values: Fix allocation check
> perf values: Zero value buffers
> perf report: Group stat values on global event id
>
> Li Bin (2):
> perf probe: Fix kprobe blacklist checking condition
> perf symbols: Fix plt entry calculation for ARM and AARCH64
>
> tools/arch/x86/include/asm/cpufeatures.h | 5 +--
> tools/arch/x86/include/asm/disabled-features.h | 4 +-
> tools/build/tests/ex/Makefile | 2 +-
> tools/lib/api/Makefile | 8 ++--
> tools/lib/subcmd/Makefile | 2 +-
> tools/perf/Documentation/perf-stat.txt | 4 +-
> tools/perf/Makefile.config | 4 +-
> tools/perf/Makefile.perf | 26 ++++++++---
> tools/perf/builtin-report.c | 6 +--
> tools/perf/builtin-trace.c | 8 ++++
> tools/perf/trace/beauty/Build | 1 +
> tools/perf/trace/beauty/beauty.h | 3 ++
> tools/perf/trace/beauty/pkey_alloc.c | 50 ++++++++++++++++++++++
> .../perf/trace/beauty/pkey_alloc_access_rights.sh | 10 +++++
> tools/perf/util/evsel.c | 7 ++-
> tools/perf/util/intel-pt-decoder/Build | 2 +-
> tools/perf/util/mem-events.c | 11 ++++-
> tools/perf/util/probe-event.c | 2 +-
> tools/perf/util/session.c | 25 +++++++++++
> tools/perf/util/symbol-elf.c | 27 +++++++++---
> tools/perf/util/values.c | 17 +++++---
> tools/scripts/Makefile.include | 4 +-
> 22 files changed, 185 insertions(+), 43 deletions(-)
> create mode 100644 tools/perf/trace/beauty/pkey_alloc.c
> create mode 100755 tools/perf/trace/beauty/pkey_alloc_access_rights.sh
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
@ 2017-08-29 21:15 ` Ingo Molnar
0 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2017-08-29 21:15 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, linux-perf-users, Adrian Hunter,
Alexander Shishkin, Alexis Berlemont, Andi Kleen,
Andy Lutomirski, Arnd Bergmann, Borislav Petkov, Dave Hansen,
David Ahern, David Carrillo-Cisneros, David Tolnay, Hanjun Guo,
Hemant Kumar, Jack Henschel, Janakarajan Natarajan, Jiri Olsa,
Joe Mario, Li Bin
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> Test results at the end of this message, as usual.
>
> The following changes since commit b00233b5306512a09e339d69ef5e390a77f2d302:
>
> perf/x86: Export some PMU attributes in caps/ directory (2017-08-25 11:04:20 +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-4.14-20170829
>
> for you to fetch changes up to b2f7605076d6cdd68162c42c34caadafbbe4c69f:
>
> perf symbols: Fix plt entry calculation for ARM and AARCH64 (2017-08-29 11:41:27 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> - Fix remote HITM detection for Skylake in 'perf c2c' (Jiri Olsa)
>
> - Fixes for the handling of PERF_RECORD_READ records (Jiri Olsa)
>
> - Fix kprobes blackist symbol lookup in 'perf probe' (Li Bin)
>
> - The PLT header and entry sizes are not the same in !x86, fix it for ARM and
> AARCH64 (Li Bin)
>
> - Beautify pkey_{alloc,free,mprotect} arguments in 'perf trace' (Arnaldo Carvalho de Melo)
>
> - Fix CC, AR, LD external definition, allow flex and bison to be
> externally defined and other related Makefile fixes (David Carrillo-Cisneros)
>
> - Sync cpu features kernel ABI headers with tooling headers (Arnaldo Carvalho de Melo)
>
> - Fix path to PMU formats in 'perf stat' documentation (Jack Henschel)
>
> - Fix static build with newer toolchains (Jiri Olsa)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Arnaldo Carvalho de Melo (2):
> tools headers: Sync cpu features kernel ABI headers with tooling headers
> perf trace beauty: Beautify pkey_{alloc,free,mprotect} arguments
>
> David Carrillo-Cisneros (5):
> tools build tests: Don't hardcode gcc name
> perf tools: Allow external definition of flex and bison binary names
> tools lib: Allow external definition of CC, AR and LD
> perf tools: Robustify detection of clang binary
> perf tools: Pass full path of FEATURES_DUMP
>
> Jack Henschel (1):
> perf stat: Fix path to PMU formats in documentation
>
> Jiri Olsa (8):
> perf tools: Fix static build with newer toolchains
> perf c2c: Fix remote HITM detection for Skylake
> perf record: Set read_format for inherit_stat
> perf report: Add dump_read function
> perf values: Fix thread index bug
> perf values: Fix allocation check
> perf values: Zero value buffers
> perf report: Group stat values on global event id
>
> Li Bin (2):
> perf probe: Fix kprobe blacklist checking condition
> perf symbols: Fix plt entry calculation for ARM and AARCH64
>
> tools/arch/x86/include/asm/cpufeatures.h | 5 +--
> tools/arch/x86/include/asm/disabled-features.h | 4 +-
> tools/build/tests/ex/Makefile | 2 +-
> tools/lib/api/Makefile | 8 ++--
> tools/lib/subcmd/Makefile | 2 +-
> tools/perf/Documentation/perf-stat.txt | 4 +-
> tools/perf/Makefile.config | 4 +-
> tools/perf/Makefile.perf | 26 ++++++++---
> tools/perf/builtin-report.c | 6 +--
> tools/perf/builtin-trace.c | 8 ++++
> tools/perf/trace/beauty/Build | 1 +
> tools/perf/trace/beauty/beauty.h | 3 ++
> tools/perf/trace/beauty/pkey_alloc.c | 50 ++++++++++++++++++++++
> .../perf/trace/beauty/pkey_alloc_access_rights.sh | 10 +++++
> tools/perf/util/evsel.c | 7 ++-
> tools/perf/util/intel-pt-decoder/Build | 2 +-
> tools/perf/util/mem-events.c | 11 ++++-
> tools/perf/util/probe-event.c | 2 +-
> tools/perf/util/session.c | 25 +++++++++++
> tools/perf/util/symbol-elf.c | 27 +++++++++---
> tools/perf/util/values.c | 17 +++++---
> tools/scripts/Makefile.include | 4 +-
> 22 files changed, 185 insertions(+), 43 deletions(-)
> create mode 100644 tools/perf/trace/beauty/pkey_alloc.c
> create mode 100755 tools/perf/trace/beauty/pkey_alloc_access_rights.sh
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2017-04-12 0:51 Arnaldo Carvalho de Melo
2017-04-12 5:30 ` Ingo Molnar
0 siblings, 1 reply; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2017-04-12 0:51 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Alexander Shishkin,
Andi Kleen, Andreas Krebbel, Andrew Vagin, Christian Borntraeger,
David Ahern, David Carrillo-Cisneros, Don Zickus, He Kuang,
Hendrik Brueckner, Jiri Olsa, Kan Liang, Martin Schwidefsky,
Masami Hiramatsu, Namhyung Kim, Paul Turner, Peter Zijlstra,
Simon Que, stable, #, v4.10+,
Stephane Eranian, Taeung Song, Wang Nan, Yao Jin,
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 9df9078ef2086652647248ee6e82ca8f661cb3f5:
perf/amd/uncore: Fix pr_fmt() prefix (2017-04-11 08:44:59 +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-4.12-20170411
for you to fetch changes up to 986a5bc028a84d487c354a529730b48682d1fb41:
perf annotate: Use stripped line instead of raw disassemble line (2017-04-11 16:22:23 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
User visible:
- Support s390 jump instructions in perf annotate (Christian Borntraeger)
- When failing to setup multiple events (e.g. '-e irq_vectors:*'), state
which one caused the failure (Yao Jin)
- Various fixes for pipe mode, where the output of 'perf record' is
written to stdout instead of to a perf.data file, fixing workloads
such as: (David Carrillo-Cisneros)
$ perf record -o - noploop | perf inject -b > perf.data
$ perf record -o - noploop | perf annotate
Infrastructure:
- Simplify ltrim() implementation (Arnaldo Carvalho de Melo)
- Use ltrim() and rtrim() in places where ad-hoc equivalents were being
used (Taeung Song)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Arnaldo Carvalho de Melo (3):
perf callchains: Switch from strtok() to strtok_r() when parsing options
perf script: Use strtok_r() when parsing output field list
perf string: Simplify ltrim() implementation
Christian Borntraeger (2):
perf annotate s390: Fix perf annotate error -95 (4.10 regression)
perf annotate s390: Implement jump types for perf annotate
David Carrillo-Cisneros (6):
perf inject: Don't proceed if perf_session__process_event() fails
perf inject: Copy events when reordering events in pipe mode
perf tools: Describe pipe mode in perf.data-file-fomat.txt
perf annotate: Process attr and build_id records
perf session: Don't rely on evlist in pipe mode
perf tools: Do not print missing features in pipe-mode
Jin Yao (1):
perf evsel: Return exact sub event which failed with EPERM for wildcards
Taeung Song (6):
perf stat: Refactor the code to strip csv output with ltrim()
perf ui browser: Refactor the code to parse color configs with ltrim()
perf pmu: Refactor wordwrap() with ltrim()
perf tools: Refactor the code to strip command name with {l,r}trim()
perf annotate: Refactor the code to parse disassemble lines with {l,r}trim()
perf annotate: Use stripped line instead of raw disassemble line
tools/perf/Documentation/perf.data-file-format.txt | 19 +++++++-
tools/perf/arch/s390/annotate/instructions.c | 30 ++++++++++++
tools/perf/builtin-annotate.c | 2 +
tools/perf/builtin-inject.c | 2 +
tools/perf/builtin-script.c | 4 +-
tools/perf/builtin-stat.c | 10 +---
tools/perf/ui/browser.c | 2 +-
tools/perf/util/annotate.c | 54 +++++++---------------
tools/perf/util/callchain.c | 4 +-
tools/perf/util/event.c | 11 +----
tools/perf/util/evsel.c | 8 +++-
tools/perf/util/header.c | 3 ++
tools/perf/util/ordered-events.c | 3 +-
tools/perf/util/pmu.c | 3 +-
tools/perf/util/session.c | 17 +++++--
tools/perf/util/string.c | 6 +--
16 files changed, 105 insertions(+), 73 deletions(-)
create mode 100644 tools/perf/arch/s390/annotate/instructions.c
Test results:
The first ones are container (docker) based builds of tools/perf with and
without libelf support, objtool where it is supported and samples/bpf/, ditto.
Where clang is available, it is also used to build perf with/without libelf.
For this specific pull request the samples/bpf/ was disabled, as 'make headers_install'
is failing with the following error, in this case in fedora:rawhide:
INSTALL usr/include/uapi/ (0 file)
/git/linux/scripts/Makefile.headersinst:62: *** Missing generated UAPI file ./arch/x86/include/generated/uapi/asm/unistd_32.h. Stop.
make[1]: *** [/git/linux/Makefile:1151: headers_install] Error 2
make[1]: Leaving directory '/tmp/build/linux'
make: *** [Makefile:152: sub-make] Error 2
make: Leaving directory '/git/linux'
I'll investigate later, perf and objtool builds just fine, with clang and gcc.
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
2 alpine:3.5: Ok
3 alpine:edge: Ok
4 android-ndk:r12b-arm: Ok
5 archlinux:latest: Ok
6 centos:5: Ok
7 centos:6: Ok
8 centos:7: Ok
9 debian:7: Ok
10 debian:8: Ok
11 debian:9: Ok
12 debian:experimental: Ok
13 debian:experimental-x-arm64: Ok
14 debian:experimental-x-mips: Ok
15 debian:experimental-x-mips64: Ok
16 debian:experimental-x-mipsel: Ok
17 fedora:20: Ok
18 fedora:21: Ok
19 fedora:22: Ok
20 fedora:23: Ok
21 fedora:24: Ok
22 fedora:24-x-ARC-uClibc: Ok
23 fedora:25: Ok
24 fedora:rawhide: Ok
25 mageia:5: Ok
26 opensuse:13.2: Ok
27 opensuse:42.1: Ok
28 opensuse:tumbleweed: Ok
29 ubuntu:12.04.5: Ok
30 ubuntu:14.04.4: Ok
31 ubuntu:14.04.4-x-linaro-arm64: Ok
32 ubuntu:15.10: Ok
33 ubuntu:16.04: Ok
34 ubuntu:16.04-x-arm: Ok
35 ubuntu:16.04-x-arm64: Ok
36 ubuntu:16.04-x-powerpc: Ok
37 ubuntu:16.04-x-powerpc64: Ok
38 ubuntu:16.04-x-s390: Ok
39 ubuntu:16.10: Ok
40 ubuntu:17.04: Ok
#
# uname -a
Linux jouet 4.11.0-rc6+ #7 SMP Tue Apr 11 11:53:14 -03 2017 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: Parse event definition strings : Ok
6: Simple expression parser : Ok
7: PERF_RECORD_* events & perf_sample fields : Ok
8: Parse perf pmu format : Ok
9: DSO data read : Ok
10: DSO data cache : Ok
11: DSO data reopen : Ok
12: Roundtrip evsel->name : Ok
13: Parse sched tracepoints fields : Ok
14: syscalls:sys_enter_openat event fields : Ok
15: Setup struct perf_event_attr : Ok
16: Match and link multiple hists : Ok
17: 'import perf' in python : Ok
18: Breakpoint overflow signal handler : Ok
19: Breakpoint overflow sampling : Ok
20: Number of exit events of a simple workload : Ok
21: Software clock events period values : Ok
22: Object code reading : Ok
23: Sample parsing : Ok
24: Use a dummy software event to keep tracking: Ok
25: Parse with no sample_id_all bit set : Ok
26: Filter hist entries : Ok
27: Lookup mmap thread : Ok
28: Share thread mg : Ok
29: Sort output of hist entries : Ok
30: Cumulate child hist entries : Ok
31: Track with sched_switch : Ok
32: Filter fds with revents mask in a fdarray : Ok
33: Add fd to a fdarray, making it autogrow : Ok
34: kmod_path__parse : Ok
35: Thread map : Ok
36: LLVM search and compile :
36.1: Basic BPF llvm compile : Ok
36.2: kbuild searching : Ok
36.3: Compile source for BPF prologue generation: Ok
36.4: Compile source for BPF relocation : Ok
37: Session topology : Ok
38: BPF filter :
38.1: Basic BPF filtering : Ok
38.2: BPF pinning : Ok
38.3: BPF prologue generation : Ok
38.4: BPF relocation checker : Ok
39: Synthesize thread map : Ok
40: Remove thread map : Ok
41: Synthesize cpu map : Ok
42: Synthesize stat config : Ok
43: Synthesize stat : Ok
44: Synthesize stat round : Ok
45: Synthesize attr update : Ok
46: Event times : Ok
47: Read backward ring buffer : Ok
48: Print cpu map : Ok
49: Probe SDT events : Ok
50: is_printable_array : Ok
51: Print bitmap : Ok
52: perf hooks : Ok
53: builtin clang support : Skip (not compiled in)
54: unit_number__scnprintf : Ok
55: x86 rdpmc : Ok
56: Convert perf time to TSC : Ok
57: DWARF unwind : Ok
58: x86 instruction decoder - new instructions : Ok
59: Intel cqm nmi context read : Skip
#
$ make -C tools/perf build-test
make: Entering directory '/home/acme/git/linux/tools/perf'
- tarpkg: ./tests/perf-targz-src-pkg .
make_no_auxtrace_O: make NO_AUXTRACE=1
make_install_bin_O: make install-bin
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_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
make_install_prefix_slash_O: make install prefix=/tmp/krava/
make_no_libperl_O: make NO_LIBPERL=1
make_no_libelf_O: make NO_LIBELF=1
make_no_gtk2_O: make NO_GTK2=1
make_no_newt_O: make NO_NEWT=1
make_debug_O: make DEBUG=1
make_no_libbpf_O: make NO_LIBBPF=1
make_no_libnuma_O: make NO_LIBNUMA=1
make_help_O: make help
make_clean_all_O: make clean all
make_no_libunwind_O: make NO_LIBUNWIND=1
make_no_libpython_O: make NO_LIBPYTHON=1
make_perf_o_O: make perf.o
make_tags_O: make tags
make_util_map_o_O: make util/map.o
make_util_pmu_bison_o_O: make util/pmu-bison.o
make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
make_no_slang_O: make NO_SLANG=1
make_no_backtrace_O: make NO_BACKTRACE=1
make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
make_with_clangllvm_O: make LIBCLANGLLVM=1
make_with_babeltrace_O: make LIBBABELTRACE=1
make_pure_O: make
make_install_O: make install
make_no_libbionic_O: make NO_LIBBIONIC=1
make_static_O: make LDFLAGS=-static
make_doc_O: make doc
make_no_demangle_O: make NO_DEMANGLE=1
make_install_prefix_O: make install prefix=/tmp/krava
make_no_libaudit_O: make NO_LIBAUDIT=1
OK
make: Leaving directory '/home/acme/git/linux/tools/perf'
$
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2017-04-12 0:51 Arnaldo Carvalho de Melo
@ 2017-04-12 5:30 ` Ingo Molnar
2017-04-12 7:13 ` Christian Borntraeger
0 siblings, 1 reply; 57+ messages in thread
From: Ingo Molnar @ 2017-04-12 5:30 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Alexander Shishkin, Andi Kleen, Andreas Krebbel,
Andrew Vagin, Christian Borntraeger, David Ahern,
David Carrillo-Cisneros, Don Zickus, He Kuang, Hendrik Brueckner,
Jiri Olsa, Kan Liang, Martin Schwidefsky, Masami Hiramatsu,
Namhyung Kim, Paul Turner, Peter Zijlstra, Simon Que, stable, #,
v4.10+,
Stephane Eranian, Taeung Song, Wang Nan, Yao Jin,
Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> Test results at the end of this message, as usual.
>
> The following changes since commit 9df9078ef2086652647248ee6e82ca8f661cb3f5:
>
> perf/amd/uncore: Fix pr_fmt() prefix (2017-04-11 08:44:59 +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-4.12-20170411
>
> for you to fetch changes up to 986a5bc028a84d487c354a529730b48682d1fb41:
>
> perf annotate: Use stripped line instead of raw disassemble line (2017-04-11 16:22:23 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> User visible:
>
> - Support s390 jump instructions in perf annotate (Christian Borntraeger)
>
> - When failing to setup multiple events (e.g. '-e irq_vectors:*'), state
> which one caused the failure (Yao Jin)
>
> - Various fixes for pipe mode, where the output of 'perf record' is
> written to stdout instead of to a perf.data file, fixing workloads
> such as: (David Carrillo-Cisneros)
>
> $ perf record -o - noploop | perf inject -b > perf.data
>
> $ perf record -o - noploop | perf annotate
>
> Infrastructure:
>
> - Simplify ltrim() implementation (Arnaldo Carvalho de Melo)
>
> - Use ltrim() and rtrim() in places where ad-hoc equivalents were being
> used (Taeung Song)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Arnaldo Carvalho de Melo (3):
> perf callchains: Switch from strtok() to strtok_r() when parsing options
> perf script: Use strtok_r() when parsing output field list
> perf string: Simplify ltrim() implementation
>
> Christian Borntraeger (2):
> perf annotate s390: Fix perf annotate error -95 (4.10 regression)
> perf annotate s390: Implement jump types for perf annotate
>
> David Carrillo-Cisneros (6):
> perf inject: Don't proceed if perf_session__process_event() fails
> perf inject: Copy events when reordering events in pipe mode
> perf tools: Describe pipe mode in perf.data-file-fomat.txt
> perf annotate: Process attr and build_id records
> perf session: Don't rely on evlist in pipe mode
> perf tools: Do not print missing features in pipe-mode
>
> Jin Yao (1):
> perf evsel: Return exact sub event which failed with EPERM for wildcards
>
> Taeung Song (6):
> perf stat: Refactor the code to strip csv output with ltrim()
> perf ui browser: Refactor the code to parse color configs with ltrim()
> perf pmu: Refactor wordwrap() with ltrim()
> perf tools: Refactor the code to strip command name with {l,r}trim()
> perf annotate: Refactor the code to parse disassemble lines with {l,r}trim()
> perf annotate: Use stripped line instead of raw disassemble line
>
> tools/perf/Documentation/perf.data-file-format.txt | 19 +++++++-
> tools/perf/arch/s390/annotate/instructions.c | 30 ++++++++++++
> tools/perf/builtin-annotate.c | 2 +
> tools/perf/builtin-inject.c | 2 +
> tools/perf/builtin-script.c | 4 +-
> tools/perf/builtin-stat.c | 10 +---
> tools/perf/ui/browser.c | 2 +-
> tools/perf/util/annotate.c | 54 +++++++---------------
> tools/perf/util/callchain.c | 4 +-
> tools/perf/util/event.c | 11 +----
> tools/perf/util/evsel.c | 8 +++-
> tools/perf/util/header.c | 3 ++
> tools/perf/util/ordered-events.c | 3 +-
> tools/perf/util/pmu.c | 3 +-
> tools/perf/util/session.c | 17 +++++--
> tools/perf/util/string.c | 6 +--
> 16 files changed, 105 insertions(+), 73 deletions(-)
> create mode 100644 tools/perf/arch/s390/annotate/instructions.c
Pulled, thanks a lot Arnaldo!
Note, there was a conflict in tools/perf/util/annotate.c due to the s390 fix in
perf/urgent. I've fixed it up, but please double check the conflict resolution I
made in 43d5b075c400.
Thanks,
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2017-04-12 5:30 ` Ingo Molnar
@ 2017-04-12 7:13 ` Christian Borntraeger
2017-04-12 7:24 ` Ingo Molnar
0 siblings, 1 reply; 57+ messages in thread
From: Christian Borntraeger @ 2017-04-12 7:13 UTC (permalink / raw)
To: Ingo Molnar, Arnaldo Carvalho de Melo
Cc: linux-kernel, Alexander Shishkin, Andi Kleen, Andreas Krebbel,
Andrew Vagin, David Ahern, David Carrillo-Cisneros, Don Zickus,
He Kuang, Hendrik Brueckner, Jiri Olsa, Kan Liang,
Martin Schwidefsky, Masami Hiramatsu, Namhyung Kim, Paul Turner,
Peter Zijlstra, Simon Que, stable, #, v4.10+,
Stephane Eranian, Taeung Song, Wang Nan, Yao Jin,
Arnaldo Carvalho de Melo
On 04/12/2017 07:30 AM, Ingo Molnar wrote:
>
> * Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
>
>> Hi Ingo,
>>
>> Please consider pulling,
>>
>> - Arnaldo
>>
>> Test results at the end of this message, as usual.
>>
>> The following changes since commit 9df9078ef2086652647248ee6e82ca8f661cb3f5:
>>
>> perf/amd/uncore: Fix pr_fmt() prefix (2017-04-11 08:44:59 +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-4.12-20170411
>>
>> for you to fetch changes up to 986a5bc028a84d487c354a529730b48682d1fb41:
>>
>> perf annotate: Use stripped line instead of raw disassemble line (2017-04-11 16:22:23 -0300)
>>
>> ----------------------------------------------------------------
>> perf/core improvements and fixes:
>>
>> User visible:
>>
>> - Support s390 jump instructions in perf annotate (Christian Borntraeger)
>>
>> - When failing to setup multiple events (e.g. '-e irq_vectors:*'), state
>> which one caused the failure (Yao Jin)
>>
>> - Various fixes for pipe mode, where the output of 'perf record' is
>> written to stdout instead of to a perf.data file, fixing workloads
>> such as: (David Carrillo-Cisneros)
>>
>> $ perf record -o - noploop | perf inject -b > perf.data
>>
>> $ perf record -o - noploop | perf annotate
>>
>> Infrastructure:
>>
>> - Simplify ltrim() implementation (Arnaldo Carvalho de Melo)
>>
>> - Use ltrim() and rtrim() in places where ad-hoc equivalents were being
>> used (Taeung Song)
>>
>> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>>
>> ----------------------------------------------------------------
>> Arnaldo Carvalho de Melo (3):
>> perf callchains: Switch from strtok() to strtok_r() when parsing options
>> perf script: Use strtok_r() when parsing output field list
>> perf string: Simplify ltrim() implementation
>>
>> Christian Borntraeger (2):
>> perf annotate s390: Fix perf annotate error -95 (4.10 regression)
>> perf annotate s390: Implement jump types for perf annotate
>>
>> David Carrillo-Cisneros (6):
>> perf inject: Don't proceed if perf_session__process_event() fails
>> perf inject: Copy events when reordering events in pipe mode
>> perf tools: Describe pipe mode in perf.data-file-fomat.txt
>> perf annotate: Process attr and build_id records
>> perf session: Don't rely on evlist in pipe mode
>> perf tools: Do not print missing features in pipe-mode
>>
>> Jin Yao (1):
>> perf evsel: Return exact sub event which failed with EPERM for wildcards
>>
>> Taeung Song (6):
>> perf stat: Refactor the code to strip csv output with ltrim()
>> perf ui browser: Refactor the code to parse color configs with ltrim()
>> perf pmu: Refactor wordwrap() with ltrim()
>> perf tools: Refactor the code to strip command name with {l,r}trim()
>> perf annotate: Refactor the code to parse disassemble lines with {l,r}trim()
>> perf annotate: Use stripped line instead of raw disassemble line
>>
>> tools/perf/Documentation/perf.data-file-format.txt | 19 +++++++-
>> tools/perf/arch/s390/annotate/instructions.c | 30 ++++++++++++
>> tools/perf/builtin-annotate.c | 2 +
>> tools/perf/builtin-inject.c | 2 +
>> tools/perf/builtin-script.c | 4 +-
>> tools/perf/builtin-stat.c | 10 +---
>> tools/perf/ui/browser.c | 2 +-
>> tools/perf/util/annotate.c | 54 +++++++---------------
>> tools/perf/util/callchain.c | 4 +-
>> tools/perf/util/event.c | 11 +----
>> tools/perf/util/evsel.c | 8 +++-
>> tools/perf/util/header.c | 3 ++
>> tools/perf/util/ordered-events.c | 3 +-
>> tools/perf/util/pmu.c | 3 +-
>> tools/perf/util/session.c | 17 +++++--
>> tools/perf/util/string.c | 6 +--
>> 16 files changed, 105 insertions(+), 73 deletions(-)
>> create mode 100644 tools/perf/arch/s390/annotate/instructions.c
>
> Pulled, thanks a lot Arnaldo!
>
> Note, there was a conflict in tools/perf/util/annotate.c due to the s390 fix in
> perf/urgent. I've fixed it up, but please double check the conflict resolution I
> made in 43d5b075c400.
>
> Thanks,
>
> Ingo
>
The merge looks wrong:
dbdebdc53 (Ravi Bangoria 2016-11-23 21:33:46 +0530 133) },
3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 134) {
3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 135) .name = "s390",
d9f8dfa9b (Christian Borntraeger 2017-04-06 09:51:52 +0200 136) .init = s390__annotate_init,
e77852b32 (Christian Borntraeger 2017-04-06 09:51:51 +0200 137) .objdump = {
e77852b32 (Christian Borntraeger 2017-04-06 09:51:51 +0200 138) .comment_char = '#',
e77852b32 (Christian Borntraeger 2017-04-06 09:51:51 +0200 139) },
e77852b32 (Christian Borntraeger 2017-04-06 09:51:51 +0200 140) },
43d5b075c (Ingo Molnar 2017-04-12 07:29:13 +0200 141) {
43d5b075c (Ingo Molnar 2017-04-12 07:29:13 +0200 142) .name = "s390",
3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 143) .objdump = {
3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 144) .comment_char = '#',
3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 145) },
3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 146) },
786c1b518 (Arnaldo Carvalho de Melo 2016-11-16 15:39:50 -0300 147) };
You can delete line 141-146
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2017-04-12 7:13 ` Christian Borntraeger
@ 2017-04-12 7:24 ` Ingo Molnar
0 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2017-04-12 7:24 UTC (permalink / raw)
To: Christian Borntraeger
Cc: Arnaldo Carvalho de Melo, linux-kernel, Alexander Shishkin,
Andi Kleen, Andreas Krebbel, Andrew Vagin, David Ahern,
David Carrillo-Cisneros, Don Zickus, He Kuang, Hendrik Brueckner,
Jiri Olsa, Kan Liang, Martin Schwidefsky, Masami Hiramatsu,
Namhyung Kim, Paul Turner, Peter Zijlstra, Simon Que, stable, #,
v4.10+,
Stephane Eranian, Taeung Song, Wang Nan, Yao Jin,
Arnaldo Carvalho de Melo
* Christian Borntraeger <borntraeger@de.ibm.com> wrote:
> The merge looks wrong:
>
> dbdebdc53 (Ravi Bangoria 2016-11-23 21:33:46 +0530 133) },
> 3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 134) {
> 3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 135) .name = "s390",
> d9f8dfa9b (Christian Borntraeger 2017-04-06 09:51:52 +0200 136) .init = s390__annotate_init,
> e77852b32 (Christian Borntraeger 2017-04-06 09:51:51 +0200 137) .objdump = {
> e77852b32 (Christian Borntraeger 2017-04-06 09:51:51 +0200 138) .comment_char = '#',
> e77852b32 (Christian Borntraeger 2017-04-06 09:51:51 +0200 139) },
> e77852b32 (Christian Borntraeger 2017-04-06 09:51:51 +0200 140) },
> 43d5b075c (Ingo Molnar 2017-04-12 07:29:13 +0200 141) {
> 43d5b075c (Ingo Molnar 2017-04-12 07:29:13 +0200 142) .name = "s390",
> 3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 143) .objdump = {
> 3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 144) .comment_char = '#',
> 3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 145) },
> 3c1a42795 (Christian Borntraeger 2017-04-06 09:51:51 +0200 146) },
> 786c1b518 (Arnaldo Carvalho de Melo 2016-11-16 15:39:50 -0300 147) };
>
> You can delete line 141-146
Ok, I've deleted those lines and amended the merge commit - thanks!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2017-02-20 19:08 Arnaldo Carvalho de Melo
2017-02-21 8:08 ` Ingo Molnar
0 siblings, 1 reply; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2017-02-20 19:08 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Alexander Shishkin, Andi Kleen, Borislav Petkov, David Ahern,
Jan Stancek, Jiri Olsa, kernel-team, Masami Hiramatsu,
Namhyung Kim, Peter Zijlstra, Steven Rostedt, Wang Nan
From: Arnaldo Carvalho de Melo <acme@redhat.com>
Hi Ingo,
Please consider pulling,
- Arnaldo
Test results at the end of this message, as usual.
The following changes since commit 0c8967c9df230d2c4dde6649f410b62e01806c22:
Merge tag 'perf-core-for-mingo-4.11-20170215' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2017-02-16 20:53:13 +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.11-20170220
for you to fetch changes up to 68ba32352d51474d163d58e084b62a12bb610b21:
perf record: Honor --quiet option properly (2017-02-20 11:50:36 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
New features:
- Make -a/--all-cpus be the default target in 'perf record' and 'perf stat',
just like it is with 'perf trace' (Jiri Olsa)
- Introduce -q/--quiet to the 'annotate', 'diff' and 'report', fix up
its behaviour in 'record'. This makes the output more compact by
elliminating headers, leaving just the histogram lines (Namhyung Kim)
Fixes:
- Handle offline/absent CPUs (Jan Stancek)
Infrastructure:
- Filter out -specs=/a/b/c from CC options when building the python
support, allowing that feature to be built with clang (Arnaldo Carvalho de Melo)
- Fix DEBUG=1 build with clang (Arnaldo Carvalho de Melo)
Trivial:
- Fix spelling of 'preempt' in a libtraceevent function name (Steven Rostedt)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Arnaldo Carvalho de Melo (3):
tools perf scripting python: clang doesn't have -spec, remove it
perf python: Filter out -specs=/a/b/c from the python binding cc options
perf session: Fix DEBUG=1 build with clang
Jan Stancek (3):
perf cpumap: Add cpu__max_present_cpu()
perf header: Make build_cpu_topology skip offline/absent CPUs
perf tools: Replace _SC_NPROCESSORS_CONF with max_present_cpu in cpu_topology_map
Jiri Olsa (5):
perf build: Add special fixdep cleaning rule
perf tools: Move new_term arguments into struct parse_events_term template
perf tools: Fail on using multiple bits long terms without value
perf stat: Add -a as default target
perf record: Add -a as default target
Namhyung Kim (6):
perf utils: Add perf_quiet_option()
perf utils: Check verbose flag properly
perf report: Add -q/--quiet option
perf diff: Add -q/--quiet option
perf annotate: Add -q/--quiet option
perf record: Honor --quiet option properly
Steven Rostedt (VMware) (1):
tools lib traceevent: It's preempt not prempt
tools/build/Makefile | 4 +-
tools/build/Makefile.include | 3 +
tools/lib/traceevent/event-parse.c | 4 +-
tools/lib/traceevent/event-parse.h | 2 +-
tools/perf/Documentation/perf-annotate.txt | 4 ++
tools/perf/Documentation/perf-diff.txt | 4 ++
tools/perf/Documentation/perf-record.txt | 2 +-
tools/perf/Documentation/perf-report.txt | 4 ++
tools/perf/Documentation/perf-stat.txt | 2 +-
tools/perf/Makefile.config | 7 +++
tools/perf/Makefile.perf | 4 +-
tools/perf/builtin-annotate.c | 4 ++
tools/perf/builtin-diff.c | 14 +++--
tools/perf/builtin-mem.c | 4 +-
tools/perf/builtin-record.c | 8 ++-
tools/perf/builtin-report.c | 21 +++++--
tools/perf/builtin-sched.c | 12 ++--
tools/perf/builtin-stat.c | 11 ++--
tools/perf/builtin-top.c | 2 +-
tools/perf/builtin-trace.c | 6 +-
tools/perf/pmu-events/json.c | 2 +-
tools/perf/tests/attr.c | 2 +-
tools/perf/tests/builtin-test.c | 2 +-
tools/perf/tests/code-reading.c | 2 +-
tools/perf/tests/fdarray.c | 2 +-
tools/perf/tests/llvm.c | 2 +-
tools/perf/tests/parse-events.c | 2 +-
tools/perf/tests/perf-record.c | 4 +-
tools/perf/tests/python-use.c | 2 +-
tools/perf/tests/thread-map.c | 6 +-
tools/perf/tests/topology.c | 4 +-
tools/perf/tests/vmlinux-kallsyms.c | 2 +-
tools/perf/ui/browsers/map.c | 6 +-
tools/perf/ui/hist.c | 2 +-
tools/perf/util/annotate.c | 2 +-
tools/perf/util/cpumap.c | 22 +++++++
tools/perf/util/cpumap.h | 1 +
tools/perf/util/debug.c | 17 ++++++
tools/perf/util/debug.h | 1 +
tools/perf/util/dso.c | 2 +-
tools/perf/util/env.c | 2 +-
tools/perf/util/header.c | 33 ++++++----
tools/perf/util/hist.c | 6 +-
tools/perf/util/parse-events.c | 71 +++++++++++++---------
tools/perf/util/parse-events.h | 2 +
tools/perf/util/parse-events.y | 14 ++---
tools/perf/util/pmu.c | 21 +++++--
tools/perf/util/probe-event.c | 2 +-
.../util/scripting-engines/trace-event-python.c | 4 +-
tools/perf/util/session.c | 2 +-
tools/perf/util/setup.py | 9 ++-
tools/perf/util/sort.c | 8 +--
tools/perf/util/stat.c | 2 +-
tools/perf/util/symbol-elf.c | 2 +-
54 files changed, 256 insertions(+), 129 deletions(-)
Test results:
The first ones are container (docker) based builds of tools/perf with and
without libelf support, objtool where it is supported and samples/bpf/, ditto.
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
2 android-ndk:r12b-arm: Ok
3 archlinux:latest: Ok
4 centos:5: Ok
5 centos:6: Ok
6 centos:7: Ok
7 debian:7: Ok
8 debian:8: Ok
9 debian:experimental: Ok
10 debian:experimental-x-arm64: Ok
11 debian:experimental-x-mips: Ok
12 debian:experimental-x-mips64: Ok
13 debian:experimental-x-mipsel: Ok
14 fedora:20: Ok
15 fedora:21: Ok
16 fedora:22: Ok
17 fedora:23: Ok
18 fedora:24: Ok
19 fedora:24-x-ARC-uClibc: Ok
20 fedora:25: Ok
21 fedora:rawhide: Ok
22 mageia:5: Ok
23 opensuse:13.2: Ok
24 opensuse:42.1: Ok
25 opensuse:tumbleweed: Ok
26 ubuntu:12.04.5: Ok
27 ubuntu:14.04.4-x-linaro-arm64: Ok
28 ubuntu:15.10: Ok
29 ubuntu:16.04: Ok
30 ubuntu:16.04-x-arm: Ok
31 ubuntu:16.04-x-arm64: Ok
32 ubuntu:16.04-x-powerpc: Ok
33 ubuntu:16.04-x-powerpc64: Ok
34 ubuntu:16.04-x-powerpc64el: Ok
35 ubuntu:16.04-x-s390: Ok
36 ubuntu:16.10: Ok
#
# uname -a
Linux jouet 4.10.0-rc8 #2 SMP Wed Feb 15 15:26:36 BRT 2017 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: Parse event definition strings : Ok
6: PERF_RECORD_* events & perf_sample fields : Ok
7: Parse perf pmu format : Ok
8: DSO data read : Ok
9: DSO data cache : Ok
10: DSO data reopen : Ok
11: Roundtrip evsel->name : Ok
12: Parse sched tracepoints fields : Ok
13: syscalls:sys_enter_openat event fields : Ok
14: Setup struct perf_event_attr : Ok
15: Match and link multiple hists : Ok
16: 'import perf' in python : Ok
17: Breakpoint overflow signal handler : Ok
18: Breakpoint overflow sampling : Ok
19: Number of exit events of a simple workload : Ok
20: Software clock events period values : Ok
21: Object code reading : Ok
22: Sample parsing : Ok
23: Use a dummy software event to keep tracking: Ok
24: Parse with no sample_id_all bit set : Ok
25: Filter hist entries : Ok
26: Lookup mmap thread : Ok
27: Share thread mg : Ok
28: Sort output of hist entries : Ok
29: Cumulate child hist entries : Ok
30: Track with sched_switch : Ok
31: Filter fds with revents mask in a fdarray : Ok
32: Add fd to a fdarray, making it autogrow : Ok
33: kmod_path__parse : Ok
34: Thread map : Ok
35: LLVM search and compile :
35.1: Basic BPF llvm compile : Ok
35.2: kbuild searching : Ok
35.3: Compile source for BPF prologue generation: Ok
35.4: Compile source for BPF relocation : Ok
36: Session topology : Ok
37: BPF filter :
37.1: Basic BPF filtering : Ok
37.2: BPF pinning : Ok
37.3: BPF prologue generation : Ok
37.4: BPF relocation checker : Ok
38: Synthesize thread map : Ok
39: Remove thread map : Ok
40: Synthesize cpu map : Ok
41: Synthesize stat config : Ok
42: Synthesize stat : Ok
43: Synthesize stat round : Ok
44: Synthesize attr update : Ok
45: Event times : Ok
46: Read backward ring buffer : Ok
47: Print cpu map : Ok
48: Probe SDT events : Ok
49: is_printable_array : Ok
50: Print bitmap : Ok
51: perf hooks : Ok
52: builtin clang support : Skip (not compiled in)
53: unit_number__scnprintf : Ok
54: x86 rdpmc : Ok
55: Convert perf time to TSC : Ok
56: DWARF unwind : Ok
57: x86 instruction decoder - new instructions : Ok
58: Intel cqm nmi context read : Skip
#
$ make -C tools/perf build-test
make: Entering directory '/home/acme/git/linux/tools/perf'
- tarpkg: ./tests/perf-targz-src-pkg .
make_with_clangllvm_O: make LIBCLANGLLVM=1
make_no_libaudit_O: make NO_LIBAUDIT=1
make_tags_O: make tags
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_clean_all_O: make clean all
make_no_libunwind_O: make NO_LIBUNWIND=1
make_no_libpython_O: make NO_LIBPYTHON=1
make_install_bin_O: make install-bin
make_no_newt_O: make NO_NEWT=1
make_no_slang_O: make NO_SLANG=1
make_doc_O: make doc
make_no_libbpf_O: make NO_LIBBPF=1
make_perf_o_O: make perf.o
make_install_prefix_O: make install prefix=/tmp/krava
make_no_auxtrace_O: make NO_AUXTRACE=1
make_no_libnuma_O: make NO_LIBNUMA=1
make_with_babeltrace_O: make LIBBABELTRACE=1
make_install_prefix_slash_O: make install prefix=/tmp/krava/
make_help_O: make help
make_pure_O: make
make_no_libelf_O: make NO_LIBELF=1
make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
make_debug_O: make DEBUG=1
make_install_O: make install
make_no_libbionic_O: make NO_LIBBIONIC=1
make_static_O: make LDFLAGS=-static
make_util_map_o_O: make util/map.o
make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
make_no_libperl_O: make NO_LIBPERL=1
make_no_backtrace_O: make NO_BACKTRACE=1
make_no_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
make_util_pmu_bison_o_O: make util/pmu-bison.o
make_no_gtk2_O: make NO_GTK2=1
make_no_demangle_O: make NO_DEMANGLE=1
OK
make: Leaving directory '/home/acme/git/linux/tools/perf'
$
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2017-02-20 19:08 Arnaldo Carvalho de Melo
@ 2017-02-21 8:08 ` Ingo Molnar
0 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2017-02-21 8:08 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Alexander Shishkin, Andi Kleen, Borislav Petkov, David Ahern,
Jan Stancek, Jiri Olsa, kernel-team, Masami Hiramatsu,
Namhyung Kim, Peter Zijlstra, Steven Rostedt, Wang Nan
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> From: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> Test results at the end of this message, as usual.
>
> The following changes since commit 0c8967c9df230d2c4dde6649f410b62e01806c22:
>
> Merge tag 'perf-core-for-mingo-4.11-20170215' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2017-02-16 20:53:13 +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.11-20170220
>
> for you to fetch changes up to 68ba32352d51474d163d58e084b62a12bb610b21:
>
> perf record: Honor --quiet option properly (2017-02-20 11:50:36 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> New features:
>
> - Make -a/--all-cpus be the default target in 'perf record' and 'perf stat',
> just like it is with 'perf trace' (Jiri Olsa)
>
> - Introduce -q/--quiet to the 'annotate', 'diff' and 'report', fix up
> its behaviour in 'record'. This makes the output more compact by
> elliminating headers, leaving just the histogram lines (Namhyung Kim)
>
> Fixes:
>
> - Handle offline/absent CPUs (Jan Stancek)
>
> Infrastructure:
>
> - Filter out -specs=/a/b/c from CC options when building the python
> support, allowing that feature to be built with clang (Arnaldo Carvalho de Melo)
>
> - Fix DEBUG=1 build with clang (Arnaldo Carvalho de Melo)
>
> Trivial:
>
> - Fix spelling of 'preempt' in a libtraceevent function name (Steven Rostedt)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Arnaldo Carvalho de Melo (3):
> tools perf scripting python: clang doesn't have -spec, remove it
> perf python: Filter out -specs=/a/b/c from the python binding cc options
> perf session: Fix DEBUG=1 build with clang
>
> Jan Stancek (3):
> perf cpumap: Add cpu__max_present_cpu()
> perf header: Make build_cpu_topology skip offline/absent CPUs
> perf tools: Replace _SC_NPROCESSORS_CONF with max_present_cpu in cpu_topology_map
>
> Jiri Olsa (5):
> perf build: Add special fixdep cleaning rule
> perf tools: Move new_term arguments into struct parse_events_term template
> perf tools: Fail on using multiple bits long terms without value
> perf stat: Add -a as default target
> perf record: Add -a as default target
>
> Namhyung Kim (6):
> perf utils: Add perf_quiet_option()
> perf utils: Check verbose flag properly
> perf report: Add -q/--quiet option
> perf diff: Add -q/--quiet option
> perf annotate: Add -q/--quiet option
> perf record: Honor --quiet option properly
>
> Steven Rostedt (VMware) (1):
> tools lib traceevent: It's preempt not prempt
>
> tools/build/Makefile | 4 +-
> tools/build/Makefile.include | 3 +
> tools/lib/traceevent/event-parse.c | 4 +-
> tools/lib/traceevent/event-parse.h | 2 +-
> tools/perf/Documentation/perf-annotate.txt | 4 ++
> tools/perf/Documentation/perf-diff.txt | 4 ++
> tools/perf/Documentation/perf-record.txt | 2 +-
> tools/perf/Documentation/perf-report.txt | 4 ++
> tools/perf/Documentation/perf-stat.txt | 2 +-
> tools/perf/Makefile.config | 7 +++
> tools/perf/Makefile.perf | 4 +-
> tools/perf/builtin-annotate.c | 4 ++
> tools/perf/builtin-diff.c | 14 +++--
> tools/perf/builtin-mem.c | 4 +-
> tools/perf/builtin-record.c | 8 ++-
> tools/perf/builtin-report.c | 21 +++++--
> tools/perf/builtin-sched.c | 12 ++--
> tools/perf/builtin-stat.c | 11 ++--
> tools/perf/builtin-top.c | 2 +-
> tools/perf/builtin-trace.c | 6 +-
> tools/perf/pmu-events/json.c | 2 +-
> tools/perf/tests/attr.c | 2 +-
> tools/perf/tests/builtin-test.c | 2 +-
> tools/perf/tests/code-reading.c | 2 +-
> tools/perf/tests/fdarray.c | 2 +-
> tools/perf/tests/llvm.c | 2 +-
> tools/perf/tests/parse-events.c | 2 +-
> tools/perf/tests/perf-record.c | 4 +-
> tools/perf/tests/python-use.c | 2 +-
> tools/perf/tests/thread-map.c | 6 +-
> tools/perf/tests/topology.c | 4 +-
> tools/perf/tests/vmlinux-kallsyms.c | 2 +-
> tools/perf/ui/browsers/map.c | 6 +-
> tools/perf/ui/hist.c | 2 +-
> tools/perf/util/annotate.c | 2 +-
> tools/perf/util/cpumap.c | 22 +++++++
> tools/perf/util/cpumap.h | 1 +
> tools/perf/util/debug.c | 17 ++++++
> tools/perf/util/debug.h | 1 +
> tools/perf/util/dso.c | 2 +-
> tools/perf/util/env.c | 2 +-
> tools/perf/util/header.c | 33 ++++++----
> tools/perf/util/hist.c | 6 +-
> tools/perf/util/parse-events.c | 71 +++++++++++++---------
> tools/perf/util/parse-events.h | 2 +
> tools/perf/util/parse-events.y | 14 ++---
> tools/perf/util/pmu.c | 21 +++++--
> tools/perf/util/probe-event.c | 2 +-
> .../util/scripting-engines/trace-event-python.c | 4 +-
> tools/perf/util/session.c | 2 +-
> tools/perf/util/setup.py | 9 ++-
> tools/perf/util/sort.c | 8 +--
> tools/perf/util/stat.c | 2 +-
> tools/perf/util/symbol-elf.c | 2 +-
> 54 files changed, 256 insertions(+), 129 deletions(-)
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2016-11-23 16:40 Arnaldo Carvalho de Melo
2016-11-24 4:10 ` Ingo Molnar
0 siblings, 1 reply; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2016-11-23 16:40 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Alexander Shishkin, Andi Kleen, Andrew Morton, Chris Riyder,
David Ahern, Don Zickus, Jiri Olsa, Joe Mario, Kim Phillips,
Markus Trippelsdorf, Masami Hiramatsu, Namhyung Kim,
Naveen N . Rao, Pawel Moll, Peter Zijlstra, Ravi Bangoria,
Russell King, Stephane Eranian, Steven Rostedt, Taeung Song,
Wang Nan
From: Arnaldo Carvalho de Melo <acme@redhat.com>
Hi Ingo,
Please consider pulling,
- Arnaldo
Test results at the end.
The following changes since commit 6a6b12e2125591e24891e6860410795ea53aed11:
Merge tag 'perf-core-for-mingo-20161114' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2016-11-15 09:45:04 +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-20161123
for you to fetch changes up to a407b0678bc1c39d70af5fdbe6421c164b69a8c0:
perf sched timehist: Add -V/--cpu-visual option (2016-11-23 10:44:09 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
New tool:
- 'perf sched timehist' provides an analysis of scheduling events.
Example usage:
perf sched record -- sleep 1
perf sched timehist
By default it shows the individual schedule events, including the wait
time (time between sched-out and next sched-in events for the task), the
task scheduling delay (time between wakeup and actually running) and run
time for the task:
time cpu task name wait time sch delay run time
[tid/pid] (msec) (msec) (msec)
-------- ------ ---------------- --------- --------- --------
1.874569 [0011] gcc[31949] 0.014 0.000 1.148
1.874591 [0010] gcc[31951] 0.000 0.000 0.024
1.874603 [0010] migration/10[59] 3.350 0.004 0.011
1.874604 [0011] <idle> 1.148 0.000 0.035
1.874723 [0005] <idle> 0.016 0.000 1.383
1.874746 [0005] gcc[31949] 0.153 0.078 0.022
...
Times are in msec.usec. (David Ahern, Namhyung Kim)
Improvements:
- Make 'perf c2c report' support -f/--force, to allow skipping the
ownership check for root users, for instance, just like the other
tools (Jiri Olsa)
- Allow sorting cachelines by total number of HITMs, in addition to
local and remote numbers (Jiri Olsa)
Fixes:
- Make sure errors aren't suppressed by the TUI reset at the end of
a 'perf c2c report' session (Jiri Olsa)
Infrastructure:
- Initial work on having the annotate code better support multiple
architectures, including the ability to cross-annotate, i.e. to
annotate perf.data files collected on an ARM system on a x86_64
workstation (Arnaldo Carvalho de Melo, Ravi Bangoria, Kim Phillips)
- Use USECS_PER_SEC instead of hard coded number in libtraceevent (Steven Rostedt)
- Add retrieval of preempt count and latency flags in libtraceevent (Steven Rostedt)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Arnaldo Carvalho de Melo (3):
perf annotate: Start supporting cross arch annotation
perf annotate: Allow arches to specify functions to skip
perf annotate: Add per arch instructions annotate handlers
David Ahern (5):
perf sched timehist: Introduce timehist command
perf sched timehist: Add summary options
perf sched timehist: Add -w/--wakeups option
perf sched timehist: Add call graph options
perf sched timehist: Add -V/--cpu-visual option
Jiri Olsa (6):
perf tools: Show event fd in debug output
perf c2c report: Setup browser after opening perf.data
perf c2c report: Add -f/--force option
perf c2c report: Add struct c2c_stats::tot_hitm field
perf c2c report: Display total HITMs on default
perf c2c: Support cascading options
Namhyung Kim (2):
perf symbols: Print symbol offsets conditionally
perf evsel: Support printing callchains with arrows
Steven Rostedt (2):
tools lib traceevent: Use USECS_PER_SEC instead of hardcoded number
tools lib traceevent: Add retrieval of preempt count and latency flags
tools/lib/traceevent/event-parse.c | 41 +-
tools/lib/traceevent/event-parse.h | 5 +-
tools/perf/Documentation/perf-c2c.txt | 8 +
tools/perf/Documentation/perf-sched.txt | 66 +-
tools/perf/arch/arm/annotate/instructions.c | 90 +++
tools/perf/arch/x86/annotate/instructions.c | 78 +++
tools/perf/builtin-c2c.c | 80 ++-
tools/perf/builtin-sched.c | 914 +++++++++++++++++++++++++++-
tools/perf/builtin-top.c | 2 +-
tools/perf/ui/browsers/annotate.c | 2 +-
tools/perf/ui/gtk/annotate.c | 2 +-
tools/perf/util/annotate.c | 251 ++++----
tools/perf/util/annotate.h | 6 +-
tools/perf/util/evsel.c | 6 +-
tools/perf/util/evsel.h | 1 +
tools/perf/util/evsel_fprintf.c | 12 +-
tools/perf/util/mem-events.c | 12 +-
tools/perf/util/mem-events.h | 1 +
tools/perf/util/symbol.h | 3 +-
tools/perf/util/symbol_fprintf.c | 11 +-
20 files changed, 1406 insertions(+), 185 deletions(-)
create mode 100644 tools/perf/arch/arm/annotate/instructions.c
create mode 100644 tools/perf/arch/x86/annotate/instructions.c
# uname -a
Linux jouet 4.8.6-201.fc24.x86_64 #1 SMP Thu Nov 3 14:38:57 UTC 2016 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: parse events tests : Ok
6: Validate PERF_RECORD_* events & perf_sample fields : Ok
7: Test perf pmu format parsing : Ok
8: Test dso data read : Ok
9: Test dso data cache : Ok
10: Test dso data reopen : Ok
11: roundtrip evsel->name check : Ok
12: Check parsing of sched tracepoints fields : Ok
13: Generate and check syscalls:sys_enter_openat event fields: Ok
14: struct perf_event_attr setup : Ok
15: Test matching and linking multiple hists : Ok
16: Try 'import perf' in python, checking link problems : Ok
17: Test breakpoint overflow signal handler : Ok
18: Test breakpoint overflow sampling : Ok
19: Test number of exit event of a simple workload : Ok
20: Test software clock events have valid period values : Ok
21: Test object code reading : Ok
22: Test sample parsing : Ok
23: Test using a dummy software event to keep tracking : Ok
24: Test parsing with no sample_id_all bit set : Ok
25: Test filtering hist entries : Ok
26: Test mmap thread lookup : Ok
27: Test thread mg sharing : Ok
28: Test output sorting of hist entries : Ok
29: Test cumulation of child hist entries : Ok
30: Test tracking with sched_switch : Ok
31: Filter fds with revents mask in a fdarray : Ok
32: Add fd to a fdarray, making it autogrow : Ok
33: Test kmod_path__parse function : Ok
34: Test thread map : Ok
35: Test LLVM searching and compiling :
35.1: Basic BPF llvm compiling test : Ok
35.2: Test kbuild searching : Ok
35.3: Compile source for BPF prologue generation test : Ok
35.4: Compile source for BPF relocation test : Ok
36: Test topology in session : Ok
37: Test BPF filter :
37.1: Test basic BPF filtering : Ok
37.2: Test BPF prologue generation : Ok
37.3: Test BPF relocation checker : Ok
38: Test thread map synthesize : Ok
39: Test cpu map synthesize : Ok
40: Test stat config synthesize : Ok
41: Test stat synthesize : Ok
42: Test stat round synthesize : Ok
43: Test attr update synthesize : Ok
44: Test events times : Ok
45: Test backward reading from ring buffer : Ok
46: Test cpu map print : Ok
47: Test SDT event probing : Ok
48: Test is_printable_array function : Ok
49: Test bitmap print : Ok
50: x86 rdpmc test : Ok
51: Test converting perf time to TSC : Ok
52: Test dwarf unwind : Ok
53: Test x86 instruction decoder - new instructions : Ok
54: Test intel cqm nmi context read : Skip
#
# dm
1 alpine:3.4: Ok
2 android-ndk:r12b-arm: Ok
3 archlinux:latest: Ok
4 centos:5: Ok
5 centos:6: Ok
6 centos:7: Ok
7 debian:7: Ok
8 debian:8: Ok
9 debian:experimental: Ok
10 fedora:20: Ok
11 fedora:21: Ok
12 fedora:22: Ok
13 fedora:23: Ok
14 fedora:24: Ok
15 fedora:24-x-ARC-uClibc: Ok
16 fedora:rawhide: Ok
17 mageia:5: Ok
18 opensuse:13.2: Ok
19 opensuse:42.1: Ok
20 opensuse:tumbleweed: Ok
21 ubuntu:12.04.5: Ok
22 ubuntu:14.04: Ok
23 ubuntu:14.04.4: Ok
24 ubuntu:15.10: Ok
25 ubuntu:16.04: Ok
26 ubuntu:16.04-x-arm: Ok
27 ubuntu:16.04-x-arm64: Ok
28 ubuntu:16.04-x-powerpc: Ok
29 ubuntu:16.04-x-powerpc64: Ok
30 ubuntu:16.04-x-powerpc64el: Ok
31 ubuntu:16.04-x-s390: Ok
32 ubuntu:16.10: Ok
#
$ make -C tools/perf build-test
make: Entering directory '/home/acme/git/linux/tools/perf'
- tarpkg: ./tests/perf-targz-src-pkg .
make_no_libperl_O: make NO_LIBPERL=1
make_no_demangle_O: make NO_DEMANGLE=1
make_no_libnuma_O: make NO_LIBNUMA=1
make_install_bin_O: make install-bin
make_install_prefix_O: make install prefix=/tmp/krava
make_util_map_o_O: make util/map.o
make_no_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
make_no_libbpf_O: make NO_LIBBPF=1
make_doc_O: make doc
make_util_pmu_bison_o_O: make util/pmu-bison.o
make_with_babeltrace_O: make LIBBABELTRACE=1
make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
make_debug_O: make DEBUG=1
make_perf_o_O: make perf.o
make_no_slang_O: make NO_SLANG=1
make_no_newt_O: make NO_NEWT=1
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_install_O: make install
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_clean_all_O: make clean all
make_no_libpython_O: make NO_LIBPYTHON=1
make_no_libaudit_O: make NO_LIBAUDIT=1
make_no_libbionic_O: make NO_LIBBIONIC=1
make_help_O: make help
make_no_libelf_O: make NO_LIBELF=1
make_tags_O: make tags
make_no_libunwind_O: make NO_LIBUNWIND=1
make_no_gtk2_O: make NO_GTK2=1
make_pure_O: make
make_static_O: make LDFLAGS=-static
OK
make: Leaving directory '/home/acme/git/linux/tools/perf'
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2016-11-23 16:40 Arnaldo Carvalho de Melo
@ 2016-11-24 4:10 ` Ingo Molnar
0 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2016-11-24 4:10 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Alexander Shishkin, Andi Kleen, Andrew Morton, Chris Riyder,
David Ahern, Don Zickus, Jiri Olsa, Joe Mario, Kim Phillips,
Markus Trippelsdorf, Masami Hiramatsu, Namhyung Kim,
Naveen N . Rao, Pawel Moll, Peter Zijlstra, Ravi Bangoria,
Russell King, Stephane Eranian, Steven Rostedt, Taeung Song,
Wang Nan
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> From: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> Test results at the end.
>
> The following changes since commit 6a6b12e2125591e24891e6860410795ea53aed11:
>
> Merge tag 'perf-core-for-mingo-20161114' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2016-11-15 09:45:04 +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-20161123
>
> for you to fetch changes up to a407b0678bc1c39d70af5fdbe6421c164b69a8c0:
>
> perf sched timehist: Add -V/--cpu-visual option (2016-11-23 10:44:09 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> New tool:
>
> - 'perf sched timehist' provides an analysis of scheduling events.
>
> Example usage:
> perf sched record -- sleep 1
> perf sched timehist
>
> By default it shows the individual schedule events, including the wait
> time (time between sched-out and next sched-in events for the task), the
> task scheduling delay (time between wakeup and actually running) and run
> time for the task:
>
> time cpu task name wait time sch delay run time
> [tid/pid] (msec) (msec) (msec)
> -------- ------ ---------------- --------- --------- --------
> 1.874569 [0011] gcc[31949] 0.014 0.000 1.148
> 1.874591 [0010] gcc[31951] 0.000 0.000 0.024
> 1.874603 [0010] migration/10[59] 3.350 0.004 0.011
> 1.874604 [0011] <idle> 1.148 0.000 0.035
> 1.874723 [0005] <idle> 0.016 0.000 1.383
> 1.874746 [0005] gcc[31949] 0.153 0.078 0.022
> ...
>
> Times are in msec.usec. (David Ahern, Namhyung Kim)
>
> Improvements:
>
> - Make 'perf c2c report' support -f/--force, to allow skipping the
> ownership check for root users, for instance, just like the other
> tools (Jiri Olsa)
>
> - Allow sorting cachelines by total number of HITMs, in addition to
> local and remote numbers (Jiri Olsa)
>
> Fixes:
>
> - Make sure errors aren't suppressed by the TUI reset at the end of
> a 'perf c2c report' session (Jiri Olsa)
>
> Infrastructure:
>
> - Initial work on having the annotate code better support multiple
> architectures, including the ability to cross-annotate, i.e. to
> annotate perf.data files collected on an ARM system on a x86_64
> workstation (Arnaldo Carvalho de Melo, Ravi Bangoria, Kim Phillips)
>
> - Use USECS_PER_SEC instead of hard coded number in libtraceevent (Steven Rostedt)
>
> - Add retrieval of preempt count and latency flags in libtraceevent (Steven Rostedt)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Arnaldo Carvalho de Melo (3):
> perf annotate: Start supporting cross arch annotation
> perf annotate: Allow arches to specify functions to skip
> perf annotate: Add per arch instructions annotate handlers
>
> David Ahern (5):
> perf sched timehist: Introduce timehist command
> perf sched timehist: Add summary options
> perf sched timehist: Add -w/--wakeups option
> perf sched timehist: Add call graph options
> perf sched timehist: Add -V/--cpu-visual option
>
> Jiri Olsa (6):
> perf tools: Show event fd in debug output
> perf c2c report: Setup browser after opening perf.data
> perf c2c report: Add -f/--force option
> perf c2c report: Add struct c2c_stats::tot_hitm field
> perf c2c report: Display total HITMs on default
> perf c2c: Support cascading options
>
> Namhyung Kim (2):
> perf symbols: Print symbol offsets conditionally
> perf evsel: Support printing callchains with arrows
>
> Steven Rostedt (2):
> tools lib traceevent: Use USECS_PER_SEC instead of hardcoded number
> tools lib traceevent: Add retrieval of preempt count and latency flags
>
> tools/lib/traceevent/event-parse.c | 41 +-
> tools/lib/traceevent/event-parse.h | 5 +-
> tools/perf/Documentation/perf-c2c.txt | 8 +
> tools/perf/Documentation/perf-sched.txt | 66 +-
> tools/perf/arch/arm/annotate/instructions.c | 90 +++
> tools/perf/arch/x86/annotate/instructions.c | 78 +++
> tools/perf/builtin-c2c.c | 80 ++-
> tools/perf/builtin-sched.c | 914 +++++++++++++++++++++++++++-
> tools/perf/builtin-top.c | 2 +-
> tools/perf/ui/browsers/annotate.c | 2 +-
> tools/perf/ui/gtk/annotate.c | 2 +-
> tools/perf/util/annotate.c | 251 ++++----
> tools/perf/util/annotate.h | 6 +-
> tools/perf/util/evsel.c | 6 +-
> tools/perf/util/evsel.h | 1 +
> tools/perf/util/evsel_fprintf.c | 12 +-
> tools/perf/util/mem-events.c | 12 +-
> tools/perf/util/mem-events.h | 1 +
> tools/perf/util/symbol.h | 3 +-
> tools/perf/util/symbol_fprintf.c | 11 +-
> 20 files changed, 1406 insertions(+), 185 deletions(-)
> create mode 100644 tools/perf/arch/arm/annotate/instructions.c
> create mode 100644 tools/perf/arch/x86/annotate/instructions.c
>
> # uname -a
> Linux jouet 4.8.6-201.fc24.x86_64 #1 SMP Thu Nov 3 14:38:57 UTC 2016 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: parse events tests : Ok
> 6: Validate PERF_RECORD_* events & perf_sample fields : Ok
> 7: Test perf pmu format parsing : Ok
> 8: Test dso data read : Ok
> 9: Test dso data cache : Ok
> 10: Test dso data reopen : Ok
> 11: roundtrip evsel->name check : Ok
> 12: Check parsing of sched tracepoints fields : Ok
> 13: Generate and check syscalls:sys_enter_openat event fields: Ok
> 14: struct perf_event_attr setup : Ok
> 15: Test matching and linking multiple hists : Ok
> 16: Try 'import perf' in python, checking link problems : Ok
> 17: Test breakpoint overflow signal handler : Ok
> 18: Test breakpoint overflow sampling : Ok
> 19: Test number of exit event of a simple workload : Ok
> 20: Test software clock events have valid period values : Ok
> 21: Test object code reading : Ok
> 22: Test sample parsing : Ok
> 23: Test using a dummy software event to keep tracking : Ok
> 24: Test parsing with no sample_id_all bit set : Ok
> 25: Test filtering hist entries : Ok
> 26: Test mmap thread lookup : Ok
> 27: Test thread mg sharing : Ok
> 28: Test output sorting of hist entries : Ok
> 29: Test cumulation of child hist entries : Ok
> 30: Test tracking with sched_switch : Ok
> 31: Filter fds with revents mask in a fdarray : Ok
> 32: Add fd to a fdarray, making it autogrow : Ok
> 33: Test kmod_path__parse function : Ok
> 34: Test thread map : Ok
> 35: Test LLVM searching and compiling :
> 35.1: Basic BPF llvm compiling test : Ok
> 35.2: Test kbuild searching : Ok
> 35.3: Compile source for BPF prologue generation test : Ok
> 35.4: Compile source for BPF relocation test : Ok
> 36: Test topology in session : Ok
> 37: Test BPF filter :
> 37.1: Test basic BPF filtering : Ok
> 37.2: Test BPF prologue generation : Ok
> 37.3: Test BPF relocation checker : Ok
> 38: Test thread map synthesize : Ok
> 39: Test cpu map synthesize : Ok
> 40: Test stat config synthesize : Ok
> 41: Test stat synthesize : Ok
> 42: Test stat round synthesize : Ok
> 43: Test attr update synthesize : Ok
> 44: Test events times : Ok
> 45: Test backward reading from ring buffer : Ok
> 46: Test cpu map print : Ok
> 47: Test SDT event probing : Ok
> 48: Test is_printable_array function : Ok
> 49: Test bitmap print : Ok
> 50: x86 rdpmc test : Ok
> 51: Test converting perf time to TSC : Ok
> 52: Test dwarf unwind : Ok
> 53: Test x86 instruction decoder - new instructions : Ok
> 54: Test intel cqm nmi context read : Skip
> #
>
> # dm
> 1 alpine:3.4: Ok
> 2 android-ndk:r12b-arm: Ok
> 3 archlinux:latest: Ok
> 4 centos:5: Ok
> 5 centos:6: Ok
> 6 centos:7: Ok
> 7 debian:7: Ok
> 8 debian:8: Ok
> 9 debian:experimental: Ok
> 10 fedora:20: Ok
> 11 fedora:21: Ok
> 12 fedora:22: Ok
> 13 fedora:23: Ok
> 14 fedora:24: Ok
> 15 fedora:24-x-ARC-uClibc: Ok
> 16 fedora:rawhide: Ok
> 17 mageia:5: Ok
> 18 opensuse:13.2: Ok
> 19 opensuse:42.1: Ok
> 20 opensuse:tumbleweed: Ok
> 21 ubuntu:12.04.5: Ok
> 22 ubuntu:14.04: Ok
> 23 ubuntu:14.04.4: Ok
> 24 ubuntu:15.10: Ok
> 25 ubuntu:16.04: Ok
> 26 ubuntu:16.04-x-arm: Ok
> 27 ubuntu:16.04-x-arm64: Ok
> 28 ubuntu:16.04-x-powerpc: Ok
> 29 ubuntu:16.04-x-powerpc64: Ok
> 30 ubuntu:16.04-x-powerpc64el: Ok
> 31 ubuntu:16.04-x-s390: Ok
> 32 ubuntu:16.10: Ok
> #
>
> $ make -C tools/perf build-test
> make: Entering directory '/home/acme/git/linux/tools/perf'
> - tarpkg: ./tests/perf-targz-src-pkg .
> make_no_libperl_O: make NO_LIBPERL=1
> make_no_demangle_O: make NO_DEMANGLE=1
> make_no_libnuma_O: make NO_LIBNUMA=1
> make_install_bin_O: make install-bin
> make_install_prefix_O: make install prefix=/tmp/krava
> make_util_map_o_O: make util/map.o
> make_no_libdw_dwarf_unwind_O: make NO_LIBDW_DWARF_UNWIND=1
> make_no_libbpf_O: make NO_LIBBPF=1
> make_doc_O: make doc
> make_util_pmu_bison_o_O: make util/pmu-bison.o
> make_with_babeltrace_O: make LIBBABELTRACE=1
> make_no_ui_O: make NO_NEWT=1 NO_SLANG=1 NO_GTK2=1
> make_no_scripts_O: make NO_LIBPYTHON=1 NO_LIBPERL=1
> make_debug_O: make DEBUG=1
> make_perf_o_O: make perf.o
> make_no_slang_O: make NO_SLANG=1
> make_no_newt_O: make NO_NEWT=1
> 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_install_O: make install
> 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_clean_all_O: make clean all
> make_no_libpython_O: make NO_LIBPYTHON=1
> make_no_libaudit_O: make NO_LIBAUDIT=1
> make_no_libbionic_O: make NO_LIBBIONIC=1
> make_help_O: make help
> make_no_libelf_O: make NO_LIBELF=1
> make_tags_O: make tags
> make_no_libunwind_O: make NO_LIBUNWIND=1
> make_no_gtk2_O: make NO_GTK2=1
> make_pure_O: make
> make_static_O: make LDFLAGS=-static
> OK
> make: Leaving directory '/home/acme/git/linux/tools/perf'
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2016-06-27 21:01 Arnaldo Carvalho de Melo
2016-06-28 7:02 ` Ingo Molnar
0 siblings, 1 reply; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2016-06-27 21:01 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Ananth N Mavinakayanahalli, Andi Kleen, Anton Blanchard,
Daniel Axtens, David Ahern, He Kuang, Jiri Olsa,
Marc Kleine-Budde, Masami Hiramatsu, Michael Ellerman,
Namhyung Kim, Naveen N . Rao, Neeraj Badlani, Nilay Vaish,
Peter Zijlstra, pi3orama, Ravi Bangoria, Taeung Song, Wang Nan,
Zefan Li, Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit d4cf1949f9689314aef962eea95df84a8288d097:
perf/x86/intel: Add {rd,wr}lbr_{to,from} wrappers (2016-06-27 11:34:21 +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-20160627
for you to fetch changes up to 6d9c675078e697309c1c06a1051f01de8151c476:
perf data ctf: Generate fork and exit events to CTF output (2016-06-27 15:50:23 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
New features:
- Generate comm, fork and exit events when converting perf.data files to CTF (Wang Nan)
Documentation:
- Document perf.data on disk format (Andi Kleen)
Infrastructure:
- Add libbabeltrace to build-test (Wang Nan)
- 'perf record' prep work to support multiple evlists (Wang Nan)
- Remove unused hist_entry__annotate function (Ravi Bangoria)
- Add more toolchain triplets (Ravi Bangoria)
- Update message for slang devel packages on Ubuntu (Neeraj Badlani)
- Generalize handling of 'ret' instructions in the annotate TUI (Naveen N. Rao)
- Use proper dso name for is_regular_file, fixing device file handling (Jiri Olsa)
Build Fixes:
- Add missing config.h include, fixing the build with libabeltrace (Jiri Olsa)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Andi Kleen (1):
perf tools: Add documentation for perf.data on disk format
Jiri Olsa (2):
perf data convert: Include config.h header
perf symbols: Use proper dso name for is_regular_file
Naveen N. Rao (1):
perf annotate: Generalize handling of 'ret' instructions
Neeraj Badlani (1):
perf tools: Update makefile message for installing slang devel package
Ravi Bangoria (2):
perf annotate: Remove unused hist_entry__annotate function
perf tools: Add more toolchain triplets
Wang Nan (11):
perf build: Add libbabeltrace to build-test
perf record: Move mmap setup block to separate function
perf record: Prepare reading from multiple evlists in record__mmap_read_all()
perf record: Prepare picking perf_event_mmap_page from multiple evlists
perf data ctf: Add value_set_string() helper
perf data ctf: Pass convert options through opts structure
perf data ctf: Add 'all' option
perf data ctf: Prepare collect non-sample events
perf data ctf: Generate comm event to CTF output
perf data ctf: Add '--all' option for 'perf data convert'
perf data ctf: Generate fork and exit events to CTF output
tools/perf/Documentation/perf-data.txt | 4 +
tools/perf/Documentation/perf-file-format.txt | 442 ++++++++++++++++++++++++++
tools/perf/arch/common.c | 17 +
tools/perf/builtin-data.c | 11 +-
tools/perf/builtin-record.c | 105 ++++--
tools/perf/config/Makefile | 2 +-
tools/perf/tests/make | 2 +
tools/perf/ui/browsers/annotate.c | 20 +-
tools/perf/util/annotate.c | 15 +-
tools/perf/util/annotate.h | 3 +-
tools/perf/util/data-convert-bt.c | 196 +++++++++++-
tools/perf/util/data-convert-bt.h | 4 +-
tools/perf/util/data-convert.h | 9 +
tools/perf/util/symbol.c | 2 +-
14 files changed, 773 insertions(+), 59 deletions(-)
create mode 100644 tools/perf/Documentation/perf-file-format.txt
create mode 100644 tools/perf/util/data-convert.h
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2016-06-27 21:01 Arnaldo Carvalho de Melo
@ 2016-06-28 7:02 ` Ingo Molnar
2016-06-28 8:27 ` Jiri Olsa
2016-06-28 14:01 ` Arnaldo Carvalho de Melo
0 siblings, 2 replies; 57+ messages in thread
From: Ingo Molnar @ 2016-06-28 7:02 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Adrian Hunter, Ananth N Mavinakayanahalli,
Andi Kleen, Anton Blanchard, Daniel Axtens, David Ahern,
He Kuang, Jiri Olsa, Marc Kleine-Budde, Masami Hiramatsu,
Michael Ellerman, Namhyung Kim, Naveen N . Rao, Neeraj Badlani,
Nilay Vaish, Peter Zijlstra, pi3orama, Ravi Bangoria,
Taeung Song, 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 d4cf1949f9689314aef962eea95df84a8288d097:
>
> perf/x86/intel: Add {rd,wr}lbr_{to,from} wrappers (2016-06-27 11:34:21 +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-20160627
>
> for you to fetch changes up to 6d9c675078e697309c1c06a1051f01de8151c476:
>
> perf data ctf: Generate fork and exit events to CTF output (2016-06-27 15:50:23 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> New features:
>
> - Generate comm, fork and exit events when converting perf.data files to CTF (Wang Nan)
>
> Documentation:
>
> - Document perf.data on disk format (Andi Kleen)
>
> Infrastructure:
>
> - Add libbabeltrace to build-test (Wang Nan)
>
> - 'perf record' prep work to support multiple evlists (Wang Nan)
>
> - Remove unused hist_entry__annotate function (Ravi Bangoria)
>
> - Add more toolchain triplets (Ravi Bangoria)
>
> - Update message for slang devel packages on Ubuntu (Neeraj Badlani)
>
> - Generalize handling of 'ret' instructions in the annotate TUI (Naveen N. Rao)
>
> - Use proper dso name for is_regular_file, fixing device file handling (Jiri Olsa)
>
> Build Fixes:
>
> - Add missing config.h include, fixing the build with libabeltrace (Jiri Olsa)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Andi Kleen (1):
> perf tools: Add documentation for perf.data on disk format
The doc build fails with:
asciidoc: FAILED: manpage document title is mandatory
Makefile:276: recipe for target 'perf-file-format.xml' failed
make[2]: *** [perf-file-format.xml] Error 1
make[2]: *** Waiting for unfinished jobs....
Thanks,
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2016-06-28 7:02 ` Ingo Molnar
@ 2016-06-28 8:27 ` Jiri Olsa
2016-06-28 14:01 ` Arnaldo Carvalho de Melo
1 sibling, 0 replies; 57+ messages in thread
From: Jiri Olsa @ 2016-06-28 8:27 UTC (permalink / raw)
To: Ingo Molnar
Cc: Arnaldo Carvalho de Melo, linux-kernel, Adrian Hunter,
Ananth N Mavinakayanahalli, Andi Kleen, Anton Blanchard,
Daniel Axtens, David Ahern, He Kuang, Marc Kleine-Budde,
Masami Hiramatsu, Michael Ellerman, Namhyung Kim, Naveen N . Rao,
Neeraj Badlani, Nilay Vaish, Peter Zijlstra, pi3orama,
Ravi Bangoria, Taeung Song, Wang Nan, Zefan Li,
Arnaldo Carvalho de Melo
On Tue, Jun 28, 2016 at 09:02:57AM +0200, Ingo Molnar wrote:
SNIP
> > - Add missing config.h include, fixing the build with libabeltrace (Jiri Olsa)
> >
> > Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
> >
> > ----------------------------------------------------------------
> > Andi Kleen (1):
> > perf tools: Add documentation for perf.data on disk format
>
> The doc build fails with:
>
> asciidoc: FAILED: manpage document title is mandatory
> Makefile:276: recipe for target 'perf-file-format.xml' failed
> make[2]: *** [perf-file-format.xml] Error 1
> make[2]: *** Waiting for unfinished jobs....
>
hum, my asciidoc does not complain
jirka
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2016-06-28 7:02 ` Ingo Molnar
2016-06-28 8:27 ` Jiri Olsa
@ 2016-06-28 14:01 ` Arnaldo Carvalho de Melo
2016-06-28 14:12 ` Arnaldo Carvalho de Melo
2016-06-29 9:36 ` Ingo Molnar
1 sibling, 2 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2016-06-28 14:01 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Adrian Hunter, Ananth N Mavinakayanahalli,
Andi Kleen, Anton Blanchard, Daniel Axtens, David Ahern,
He Kuang, Jiri Olsa, Marc Kleine-Budde, Masami Hiramatsu,
Michael Ellerman, Namhyung Kim, Naveen N . Rao, Neeraj Badlani,
Nilay Vaish, Peter Zijlstra, pi3orama, Ravi Bangoria,
Taeung Song, Wang Nan, Zefan Li, Arnaldo Carvalho de Melo
Em Tue, Jun 28, 2016 at 09:02:57AM +0200, Ingo Molnar escreveu:
>
> * Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
>
> > Hi Ingo,
> >
> > Please consider pulling,
> >
> > - Arnaldo
> >
> > The following changes since commit d4cf1949f9689314aef962eea95df84a8288d097:
> >
> > perf/x86/intel: Add {rd,wr}lbr_{to,from} wrappers (2016-06-27 11:34:21 +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-20160627
> >
> > for you to fetch changes up to 6d9c675078e697309c1c06a1051f01de8151c476:
> >
> > perf data ctf: Generate fork and exit events to CTF output (2016-06-27 15:50:23 -0300)
> >
> > ----------------------------------------------------------------
> > perf/core improvements and fixes:
> >
> > New features:
> >
> > - Generate comm, fork and exit events when converting perf.data files to CTF (Wang Nan)
> >
> > Documentation:
> >
> > - Document perf.data on disk format (Andi Kleen)
> >
> > Infrastructure:
> >
> > - Add libbabeltrace to build-test (Wang Nan)
> >
> > - 'perf record' prep work to support multiple evlists (Wang Nan)
> >
> > - Remove unused hist_entry__annotate function (Ravi Bangoria)
> >
> > - Add more toolchain triplets (Ravi Bangoria)
> >
> > - Update message for slang devel packages on Ubuntu (Neeraj Badlani)
> >
> > - Generalize handling of 'ret' instructions in the annotate TUI (Naveen N. Rao)
> >
> > - Use proper dso name for is_regular_file, fixing device file handling (Jiri Olsa)
> >
> > Build Fixes:
> >
> > - Add missing config.h include, fixing the build with libabeltrace (Jiri Olsa)
> >
> > Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
> >
> > ----------------------------------------------------------------
> > Andi Kleen (1):
> > perf tools: Add documentation for perf.data on disk format
>
> The doc build fails with:
>
> asciidoc: FAILED: manpage document title is mandatory
> Makefile:276: recipe for target 'perf-file-format.xml' failed
> make[2]: *** [perf-file-format.xml] Error 1
> make[2]: *** Waiting for unfinished jobs....
Ok, I've created a perf-core-for-mingo-20160628 with that patch removed
while we investigate this, please consider pulling that one instead.
build-test should've caught this... Reproduced, trying to fix...
- Arnaldo
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2016-06-28 14:01 ` Arnaldo Carvalho de Melo
@ 2016-06-28 14:12 ` Arnaldo Carvalho de Melo
2016-06-29 9:36 ` Ingo Molnar
1 sibling, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2016-06-28 14:12 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: Ingo Molnar, linux-kernel, Adrian Hunter,
Ananth N Mavinakayanahalli, Andi Kleen, Anton Blanchard,
Daniel Axtens, David Ahern, He Kuang, Jiri Olsa,
Marc Kleine-Budde, Masami Hiramatsu, Michael Ellerman,
Namhyung Kim, Naveen N . Rao, Neeraj Badlani, Nilay Vaish,
Peter Zijlstra, pi3orama, Ravi Bangoria, Taeung Song, Wang Nan,
Zefan Li, Arnaldo Carvalho de Melo
Em Tue, Jun 28, 2016 at 11:01:55AM -0300, Arnaldo Carvalho de Melo escreveu:
> Em Tue, Jun 28, 2016 at 09:02:57AM +0200, Ingo Molnar escreveu:
> > * Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> > > Andi Kleen (1):
> > > perf tools: Add documentation for perf.data on disk format
> > The doc build fails with:
> > asciidoc: FAILED: manpage document title is mandatory
> > Makefile:276: recipe for target 'perf-file-format.xml' failed
> > make[2]: *** [perf-file-format.xml] Error 1
> > make[2]: *** Waiting for unfinished jobs....
> Ok, I've created a perf-core-for-mingo-20160628 with that patch removed
> while we investigate this, please consider pulling that one instead.
> build-test should've caught this... Reproduced, trying to fix...
So, when doing the docs install it expects files starting with perf-*
will be fed to asciidoc to generate man pages, etc, so the quick fix
here is to rename perf-file-format.txt to perf.data-file-format.txt,
which I did, so this will go in the next pull request.
Volunteers accepted to turn this into asciidoc format so that we can do
a man perf-data-file-format or somesuch.
- Arnaldo
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2016-06-28 14:01 ` Arnaldo Carvalho de Melo
2016-06-28 14:12 ` Arnaldo Carvalho de Melo
@ 2016-06-29 9:36 ` Ingo Molnar
1 sibling, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2016-06-29 9:36 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Adrian Hunter, Ananth N Mavinakayanahalli,
Andi Kleen, Anton Blanchard, Daniel Axtens, David Ahern,
He Kuang, Jiri Olsa, Marc Kleine-Budde, Masami Hiramatsu,
Michael Ellerman, Namhyung Kim, Naveen N . Rao, Neeraj Badlani,
Nilay Vaish, Peter Zijlstra, pi3orama, Ravi Bangoria,
Taeung Song, Wang Nan, Zefan Li, Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Em Tue, Jun 28, 2016 at 09:02:57AM +0200, Ingo Molnar escreveu:
> >
> > * Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> >
> > > Hi Ingo,
> > >
> > > Please consider pulling,
> > >
> > > - Arnaldo
> > >
> > > The following changes since commit d4cf1949f9689314aef962eea95df84a8288d097:
> > >
> > > perf/x86/intel: Add {rd,wr}lbr_{to,from} wrappers (2016-06-27 11:34:21 +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-20160627
> > >
> > > for you to fetch changes up to 6d9c675078e697309c1c06a1051f01de8151c476:
> > >
> > > perf data ctf: Generate fork and exit events to CTF output (2016-06-27 15:50:23 -0300)
> > >
> > > ----------------------------------------------------------------
> > > perf/core improvements and fixes:
> > >
> > > New features:
> > >
> > > - Generate comm, fork and exit events when converting perf.data files to CTF (Wang Nan)
> > >
> > > Documentation:
> > >
> > > - Document perf.data on disk format (Andi Kleen)
> > >
> > > Infrastructure:
> > >
> > > - Add libbabeltrace to build-test (Wang Nan)
> > >
> > > - 'perf record' prep work to support multiple evlists (Wang Nan)
> > >
> > > - Remove unused hist_entry__annotate function (Ravi Bangoria)
> > >
> > > - Add more toolchain triplets (Ravi Bangoria)
> > >
> > > - Update message for slang devel packages on Ubuntu (Neeraj Badlani)
> > >
> > > - Generalize handling of 'ret' instructions in the annotate TUI (Naveen N. Rao)
> > >
> > > - Use proper dso name for is_regular_file, fixing device file handling (Jiri Olsa)
> > >
> > > Build Fixes:
> > >
> > > - Add missing config.h include, fixing the build with libabeltrace (Jiri Olsa)
> > >
> > > Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
> > >
> > > ----------------------------------------------------------------
> > > Andi Kleen (1):
> > > perf tools: Add documentation for perf.data on disk format
> >
> > The doc build fails with:
> >
> > asciidoc: FAILED: manpage document title is mandatory
> > Makefile:276: recipe for target 'perf-file-format.xml' failed
> > make[2]: *** [perf-file-format.xml] Error 1
> > make[2]: *** Waiting for unfinished jobs....
>
> Ok, I've created a perf-core-for-mingo-20160628 with that patch removed
> while we investigate this, please consider pulling that one instead.
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2015-07-24 1:58 Arnaldo Carvalho de Melo
2015-07-27 15:58 ` Ingo Molnar
0 siblings, 1 reply; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-07-24 1:58 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Andi Kleen, Borislav Petkov, David Ahern, Frederic Weisbecker,
Jiri Olsa, Mathieu Poirier, Namhyung Kim, Pawel Moll,
Peter Zijlstra, Stephane Eranian, Steven Rostedt,
Thomas Gleixner, Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit a11c51acc52822754d66a11c15f6f6edd4d23c55:
Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2015-07-21 07:58:06 +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 7c14898ba9386ee5c939bb418643ac6baff52840:
perf script: Add option --show-switch-events (2015-07-23 22:51:14 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
New features:
- Introduce PERF_RECORD_SWITCH(_CPU_WIDE) and use it in 'record' to
ask for context switches, allowing non priviledged tasks to know
when they are switched in and out, which wasn't possible with
the other context switch tracepoint and software events, see the
patch description for a comprehensive justification (Adrian Hunter)
- Stop collecting /proc/kallsyms in perf.data files, saving about
4.5MB on a typical x86-64 system, use the symbol resolution
routines used in all the other tools (report, top, etc) now that
we can ask libtraceevent to use perf's symbol resolution code.
(Arnaldo Carvalho de Melo)
User visible fixes:
- Expose perf's symbol resolver to libtraceecent, so that its plugins can
resolve tracepoint fields to kernel functions, like the 'function' field
in the "timer:hrtimer_start tracepoint" (Arnaldo Carvalho de Melo)
Infrastructure:
- Map propagation of thread and cpu maps improvements, prep work for
'perf stat' new features (Jiri Olsa)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Adrian Hunter (5):
perf: Add PERF_RECORD_SWITCH to indicate context switches
perf tools: Add new PERF_RECORD_SWITCH event
perf record: Add option --switch-events to select PERF_RECORD_SWITCH events
perf script: Don't assume evsel position of tracking events
perf script: Add option --show-switch-events
Arnaldo Carvalho de Melo (8):
perf symbols: Add front end cache for DSO symbol lookup
perf symbols: Introduce map__is_(kernel,kmodule)()
tools lib traceevent: Allow setting an alternative symbol resolver
perf symbols: Provide libtraceevent callback to resolve kernel symbols
perf trace: Provide libtracevent with a kernel symbol resolver
perf script: Switch from perf.data's kallsyms to perf's symbol resolver
perf tools: Stop reading the kallsyms data from perf.data
perf tools: Stop copying kallsyms into the perf.data file header
Jiri Olsa (5):
perf test: Check for refcnt in thread_map test
perf evlist: Force perf_evlist__set_maps to propagate maps through events
perf evlist: Use bool instead of target argument in propagate_maps()
perf evlist: Tolerate NULL maps in propagate_maps
perf header: Use argv style storage for cmdline feature data
include/uapi/linux/perf_event.h | 31 +++++++++-
kernel/events/core.c | 103 +++++++++++++++++++++++++++++++
tools/lib/traceevent/event-parse.c | 68 +++++++++++++++++++-
tools/lib/traceevent/event-parse.h | 8 +++
tools/perf/Documentation/perf-record.txt | 4 ++
tools/perf/Documentation/perf-script.txt | 4 ++
tools/perf/builtin-inject.c | 1 +
tools/perf/builtin-record.c | 7 +++
tools/perf/builtin-script.c | 48 ++++++++++++--
tools/perf/builtin-trace.c | 3 +
tools/perf/perf.h | 1 +
tools/perf/tests/thread-map.c | 4 ++
tools/perf/util/dso.h | 4 ++
tools/perf/util/event.c | 28 +++++++++
tools/perf/util/event.h | 12 ++++
tools/perf/util/evlist.c | 28 +++++++--
tools/perf/util/evlist.h | 12 ++--
tools/perf/util/evsel.c | 4 ++
tools/perf/util/header.c | 35 ++++++-----
tools/perf/util/header.h | 1 +
tools/perf/util/machine.c | 25 ++++++++
tools/perf/util/machine.h | 6 ++
tools/perf/util/map.c | 14 +++++
tools/perf/util/map.h | 7 +++
tools/perf/util/record.c | 10 +++
tools/perf/util/session.c | 21 +++++++
tools/perf/util/symbol.c | 7 ++-
tools/perf/util/tool.h | 1 +
tools/perf/util/trace-event-info.c | 22 +++----
tools/perf/util/trace-event-parse.c | 30 ---------
tools/perf/util/trace-event-read.c | 28 ++++-----
tools/perf/util/trace-event.c | 45 +++++++++-----
tools/perf/util/trace-event.h | 1 +
33 files changed, 513 insertions(+), 110 deletions(-)
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2015-07-24 1:58 Arnaldo Carvalho de Melo
@ 2015-07-27 15:58 ` Ingo Molnar
0 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2015-07-27 15:58 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Adrian Hunter, Andi Kleen, Borislav Petkov,
David Ahern, Frederic Weisbecker, Jiri Olsa, Mathieu Poirier,
Namhyung Kim, Pawel Moll, Peter Zijlstra, Stephane Eranian,
Steven Rostedt, Thomas Gleixner, Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> The following changes since commit a11c51acc52822754d66a11c15f6f6edd4d23c55:
>
> Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2015-07-21 07:58:06 +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 7c14898ba9386ee5c939bb418643ac6baff52840:
>
> perf script: Add option --show-switch-events (2015-07-23 22:51:14 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> New features:
>
> - Introduce PERF_RECORD_SWITCH(_CPU_WIDE) and use it in 'record' to
> ask for context switches, allowing non priviledged tasks to know
> when they are switched in and out, which wasn't possible with
> the other context switch tracepoint and software events, see the
> patch description for a comprehensive justification (Adrian Hunter)
>
> - Stop collecting /proc/kallsyms in perf.data files, saving about
> 4.5MB on a typical x86-64 system, use the symbol resolution
> routines used in all the other tools (report, top, etc) now that
> we can ask libtraceevent to use perf's symbol resolution code.
> (Arnaldo Carvalho de Melo)
>
> User visible fixes:
>
> - Expose perf's symbol resolver to libtraceecent, so that its plugins can
> resolve tracepoint fields to kernel functions, like the 'function' field
> in the "timer:hrtimer_start tracepoint" (Arnaldo Carvalho de Melo)
>
> Infrastructure:
>
> - Map propagation of thread and cpu maps improvements, prep work for
> 'perf stat' new features (Jiri Olsa)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Adrian Hunter (5):
> perf: Add PERF_RECORD_SWITCH to indicate context switches
> perf tools: Add new PERF_RECORD_SWITCH event
> perf record: Add option --switch-events to select PERF_RECORD_SWITCH events
> perf script: Don't assume evsel position of tracking events
> perf script: Add option --show-switch-events
>
> Arnaldo Carvalho de Melo (8):
> perf symbols: Add front end cache for DSO symbol lookup
> perf symbols: Introduce map__is_(kernel,kmodule)()
> tools lib traceevent: Allow setting an alternative symbol resolver
> perf symbols: Provide libtraceevent callback to resolve kernel symbols
> perf trace: Provide libtracevent with a kernel symbol resolver
> perf script: Switch from perf.data's kallsyms to perf's symbol resolver
> perf tools: Stop reading the kallsyms data from perf.data
> perf tools: Stop copying kallsyms into the perf.data file header
>
> Jiri Olsa (5):
> perf test: Check for refcnt in thread_map test
> perf evlist: Force perf_evlist__set_maps to propagate maps through events
> perf evlist: Use bool instead of target argument in propagate_maps()
> perf evlist: Tolerate NULL maps in propagate_maps
> perf header: Use argv style storage for cmdline feature data
>
> include/uapi/linux/perf_event.h | 31 +++++++++-
> kernel/events/core.c | 103 +++++++++++++++++++++++++++++++
> tools/lib/traceevent/event-parse.c | 68 +++++++++++++++++++-
> tools/lib/traceevent/event-parse.h | 8 +++
> tools/perf/Documentation/perf-record.txt | 4 ++
> tools/perf/Documentation/perf-script.txt | 4 ++
> tools/perf/builtin-inject.c | 1 +
> tools/perf/builtin-record.c | 7 +++
> tools/perf/builtin-script.c | 48 ++++++++++++--
> tools/perf/builtin-trace.c | 3 +
> tools/perf/perf.h | 1 +
> tools/perf/tests/thread-map.c | 4 ++
> tools/perf/util/dso.h | 4 ++
> tools/perf/util/event.c | 28 +++++++++
> tools/perf/util/event.h | 12 ++++
> tools/perf/util/evlist.c | 28 +++++++--
> tools/perf/util/evlist.h | 12 ++--
> tools/perf/util/evsel.c | 4 ++
> tools/perf/util/header.c | 35 ++++++-----
> tools/perf/util/header.h | 1 +
> tools/perf/util/machine.c | 25 ++++++++
> tools/perf/util/machine.h | 6 ++
> tools/perf/util/map.c | 14 +++++
> tools/perf/util/map.h | 7 +++
> tools/perf/util/record.c | 10 +++
> tools/perf/util/session.c | 21 +++++++
> tools/perf/util/symbol.c | 7 ++-
> tools/perf/util/tool.h | 1 +
> tools/perf/util/trace-event-info.c | 22 +++----
> tools/perf/util/trace-event-parse.c | 30 ---------
> tools/perf/util/trace-event-read.c | 28 ++++-----
> tools/perf/util/trace-event.c | 45 +++++++++-----
> tools/perf/util/trace-event.h | 1 +
> 33 files changed, 513 insertions(+), 110 deletions(-)
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2015-05-18 15:50 Arnaldo Carvalho de Melo
2015-05-20 11:25 ` Ingo Molnar
0 siblings, 1 reply; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2015-05-18 15:50 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Alexei Starovoitov, Andi Kleen, Borislav Petkov, Brendan Gregg,
Daniel Borkmann, David Ahern, Don Zickus, Frederic Weisbecker,
He Kuang, Ingo Molnar, Jan Stancek, Jiri Olsa, Jiri Olsa,
Masami Hiramatsu, Namhyung Kim, Paul Mackerras, Peter Zijlstra,
pi3orama, Stephane Eranian, Steven Rostedt, Vinson Lee, Wang Nan,
Zefan Li, Arnaldo Carvalho de Melo
Hi Ingo,
Please consider applying,
- Arnaldo
The following changes since commit aa891009ee8863944a96ba4a348102f3d5f5f931:
Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2015-05-15 08:36:33 +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 2d8e405acd787f4b975f73e0f8d9804b272c00f0:
perf bench numa: Share sched_getcpu() __weak def with cloexec.c (2015-05-18 12:36:46 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
User visible:
- Fix "Command" sort_entry's cmp and collapse function (Jiri Olsa)
- Load map's symtab before 'perf probe' glob matching (Wang Nan)
- Set vmlinux_path__nr_entries to 0 in vmlinux_path__exit, to fix
the use case where this code is called multiple times, which wasn't
that common when it was introduced but seems to be now (Wang Nan).
Infrastructure:
- Protect dso symtab and cache operations with a mutex (Namhyung Kim)
- Make all refcnt operations use atomic.h (Arnaldo Carvalho de Melo)
- Install libtraceevent.a into libdir (Wang Nan)
Build fixes:
- Fix one build failure on RHEL5 by making 'perf bench numa' use the
__weak sched_getcpu() provided by cloexec.h (Arnaldo Carvalho de Melo)
- Fix dwarf-aux.c compilation on i386 (Jiri Olsa)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Arnaldo Carvalho de Melo (6):
perf tools: Use atomic.h for the map_groups refcount
perf machine: Stop accessing atomic_t::counter directly
perf evlist: Use atomic.h for the perf_mmap refcount
perf cgroup: Use atomic.h for refcounting
perf tools: Elliminate alignment holes
perf bench numa: Share sched_getcpu() __weak def with cloexec.c
Jiri Olsa (2):
perf tools: Fix dwarf-aux.c compilation on i386
perf tools: Fix "Command" sort_entry's cmp and collapse function
Namhyung Kim (5):
perf tools: Add rm_rf() utility function
perf tools: Introduce copyfile_offset() function
perf symbols: Protect dso symbol loading using a mutex
perf symbols: Protect dso cache tree using dso->lock
perf tools: Protect dso cache fd with a mutex
Wang Nan (5):
perf probe: Load map before glob matching
tools include: add __aligned_u64 to types.h.
perf tools: Set vmlinux_path__nr_entries to 0 in vmlinux_path__exit
tools lib traceevent: Install libtraceevent.a into libdir
tools build: Change FEATURE_TESTS and FEATURE_DISPLAY to weak binding
tools/build/Makefile.feature | 4 +-
tools/include/linux/types.h | 4 ++
tools/lib/traceevent/Makefile | 20 ++++--
tools/perf/bench/numa.c | 1 +
tools/perf/builtin-timechart.c | 4 +-
tools/perf/tests/thread-mg-share.c | 12 ++--
tools/perf/util/cgroup.c | 10 +--
tools/perf/util/cgroup.h | 4 +-
tools/perf/util/dso.c | 134 ++++++++++++++++++++++++++++---------
tools/perf/util/dso.h | 1 +
tools/perf/util/dwarf-aux.c | 8 +--
tools/perf/util/evlist.c | 12 ++--
tools/perf/util/evlist.h | 5 +-
tools/perf/util/evsel.h | 4 +-
tools/perf/util/machine.c | 2 +-
tools/perf/util/map.c | 4 +-
tools/perf/util/map.h | 6 +-
tools/perf/util/probe-event.c | 3 +
tools/perf/util/sort.c | 4 +-
tools/perf/util/symbol.c | 35 +++++++---
tools/perf/util/thread.h | 2 +-
tools/perf/util/util.c | 81 +++++++++++++++++++---
tools/perf/util/util.h | 2 +
23 files changed, 263 insertions(+), 99 deletions(-)
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2015-05-18 15:50 Arnaldo Carvalho de Melo
@ 2015-05-20 11:25 ` Ingo Molnar
0 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2015-05-20 11:25 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Adrian Hunter, Alexei Starovoitov, Andi Kleen,
Borislav Petkov, Brendan Gregg, Daniel Borkmann, David Ahern,
Don Zickus, Frederic Weisbecker, He Kuang, Ingo Molnar,
Jan Stancek, Jiri Olsa, Jiri Olsa, Masami Hiramatsu,
Namhyung Kim, Paul Mackerras, Peter Zijlstra, pi3orama,
Stephane Eranian, Steven Rostedt, Vinson Lee, Wang Nan, Zefan Li,
Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider applying,
>
> - Arnaldo
>
> The following changes since commit aa891009ee8863944a96ba4a348102f3d5f5f931:
>
> Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2015-05-15 08:36:33 +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 2d8e405acd787f4b975f73e0f8d9804b272c00f0:
>
> perf bench numa: Share sched_getcpu() __weak def with cloexec.c (2015-05-18 12:36:46 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> User visible:
>
> - Fix "Command" sort_entry's cmp and collapse function (Jiri Olsa)
>
> - Load map's symtab before 'perf probe' glob matching (Wang Nan)
>
> - Set vmlinux_path__nr_entries to 0 in vmlinux_path__exit, to fix
> the use case where this code is called multiple times, which wasn't
> that common when it was introduced but seems to be now (Wang Nan).
>
> Infrastructure:
>
> - Protect dso symtab and cache operations with a mutex (Namhyung Kim)
>
> - Make all refcnt operations use atomic.h (Arnaldo Carvalho de Melo)
>
> - Install libtraceevent.a into libdir (Wang Nan)
>
> Build fixes:
>
> - Fix one build failure on RHEL5 by making 'perf bench numa' use the
> __weak sched_getcpu() provided by cloexec.h (Arnaldo Carvalho de Melo)
>
> - Fix dwarf-aux.c compilation on i386 (Jiri Olsa)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Arnaldo Carvalho de Melo (6):
> perf tools: Use atomic.h for the map_groups refcount
> perf machine: Stop accessing atomic_t::counter directly
> perf evlist: Use atomic.h for the perf_mmap refcount
> perf cgroup: Use atomic.h for refcounting
> perf tools: Elliminate alignment holes
> perf bench numa: Share sched_getcpu() __weak def with cloexec.c
>
> Jiri Olsa (2):
> perf tools: Fix dwarf-aux.c compilation on i386
> perf tools: Fix "Command" sort_entry's cmp and collapse function
>
> Namhyung Kim (5):
> perf tools: Add rm_rf() utility function
> perf tools: Introduce copyfile_offset() function
> perf symbols: Protect dso symbol loading using a mutex
> perf symbols: Protect dso cache tree using dso->lock
> perf tools: Protect dso cache fd with a mutex
>
> Wang Nan (5):
> perf probe: Load map before glob matching
> tools include: add __aligned_u64 to types.h.
> perf tools: Set vmlinux_path__nr_entries to 0 in vmlinux_path__exit
> tools lib traceevent: Install libtraceevent.a into libdir
> tools build: Change FEATURE_TESTS and FEATURE_DISPLAY to weak binding
>
> tools/build/Makefile.feature | 4 +-
> tools/include/linux/types.h | 4 ++
> tools/lib/traceevent/Makefile | 20 ++++--
> tools/perf/bench/numa.c | 1 +
> tools/perf/builtin-timechart.c | 4 +-
> tools/perf/tests/thread-mg-share.c | 12 ++--
> tools/perf/util/cgroup.c | 10 +--
> tools/perf/util/cgroup.h | 4 +-
> tools/perf/util/dso.c | 134 ++++++++++++++++++++++++++++---------
> tools/perf/util/dso.h | 1 +
> tools/perf/util/dwarf-aux.c | 8 +--
> tools/perf/util/evlist.c | 12 ++--
> tools/perf/util/evlist.h | 5 +-
> tools/perf/util/evsel.h | 4 +-
> tools/perf/util/machine.c | 2 +-
> tools/perf/util/map.c | 4 +-
> tools/perf/util/map.h | 6 +-
> tools/perf/util/probe-event.c | 3 +
> tools/perf/util/sort.c | 4 +-
> tools/perf/util/symbol.c | 35 +++++++---
> tools/perf/util/thread.h | 2 +-
> tools/perf/util/util.c | 81 +++++++++++++++++++---
> tools/perf/util/util.h | 2 +
> 23 files changed, 263 insertions(+), 99 deletions(-)
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2014-12-16 16:57 Arnaldo Carvalho de Melo
2014-12-17 14:50 ` Arnaldo Carvalho de Melo
0 siblings, 1 reply; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-16 16:57 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, Mike Galbraith, Mitchell Krome, Namhyung Kim,
Paul Mackerras, Peter Zijlstra, Stephane Eranian,
Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit 41e950c033b7df997d4b38653efe6554be9b96a7:
Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/urgent (2014-12-12 09:09:52 +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 67195c75a87232f055ff415fc4624ef01f24fc3d:
perf symbols: Fix use after free in filename__read_build_id (2014-12-16 13:38:28 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
User visible:
- The mmap address range for the ring buffer now is calculated using the
contents of /proc/sys/kernel/perf_event_mlock_kb.
This fixes an -EPERM case where 'trace' was trying to use more than what
configured on perf_event_mlock_kb. (Arnaldo Carvalho de Melo)
Infrastructure:
- Move bitops definitions so that they match the header file hierarchy
in the kernel sources where that code came from. (Arnaldo Carvalho de Melo)
- Adopt round{down,up}_pow_of_two from the kernel and use it instead of
equivalent code, so that we reuse more kernel code and make tools/ look
more like kernel source code, to encourage further contributions from
kernel hackers (Arnaldo Carvalho de Melo)
- Fix use after free in filename__read_build_id (Mitchell Krome)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Arnaldo Carvalho de Melo (17):
perf evlist: Fixup brown paper bag on "hint" for --mmap-pages cmdline arg
perf evlist: Clarify sterror_mmap variable names
perf evlist: Improve the strerror_mmap method
perf trace: Let the perf_evlist__mmap autosize the number of pages to use
perf evlist: Do not use hard coded value for a mmap_pages default
tools: Move __ffs implementation to tools/include/asm-generic/bitops/__ffs.h
tools: Move code originally from linux/log2.h to tools/include/linux/
tools: Move code originally from asm-generic/atomic.h into tools/include/asm-generic/
tools: Whitespace prep patches for moving bitops.h
tools lib: Move asm-generic/bitops/find.h code to tools/include and tools/lib
tools: Introduce asm-generic/bitops.h
tools: Move bitops.h from tools/perf/util to tools/
tools: Adopt fls_long and deps
tools: Adopt rounddown_pow_of_two and deps
perf tools: Make the mmap length autotuning more robust
tools: Adopt roundup_pow_of_two
perf evlist: Use roundup_pow_of_two
Mitchell Krome (1):
perf symbols: Fix use after free in filename__read_build_id
tools/include/asm-generic/bitops.h | 27 +++++
tools/include/asm-generic/bitops/__ffs.h | 43 +++++++
tools/include/asm-generic/bitops/__fls.h | 1 +
tools/include/asm-generic/bitops/atomic.h | 22 ++++
tools/include/asm-generic/bitops/find.h | 33 ++++++
tools/include/asm-generic/bitops/fls.h | 1 +
tools/include/asm-generic/bitops/fls64.h | 1 +
tools/include/linux/bitops.h | 53 +++++++++
tools/include/linux/log2.h | 185 ++++++++++++++++++++++++++++++
tools/lib/util/find_next_bit.c | 89 ++++++++++++++
tools/perf/MANIFEST | 13 ++-
tools/perf/Makefile.perf | 14 ++-
tools/perf/builtin-trace.c | 2 +-
tools/perf/util/evlist.c | 46 ++++++--
tools/perf/util/include/linux/bitops.h | 162 --------------------------
tools/perf/util/symbol-minimal.c | 8 +-
tools/perf/util/util.h | 29 -----
17 files changed, 522 insertions(+), 207 deletions(-)
create mode 100644 tools/include/asm-generic/bitops.h
create mode 100644 tools/include/asm-generic/bitops/__ffs.h
create mode 100644 tools/include/asm-generic/bitops/__fls.h
create mode 100644 tools/include/asm-generic/bitops/atomic.h
create mode 100644 tools/include/asm-generic/bitops/find.h
create mode 100644 tools/include/asm-generic/bitops/fls.h
create mode 100644 tools/include/asm-generic/bitops/fls64.h
create mode 100644 tools/include/linux/bitops.h
create mode 100644 tools/include/linux/log2.h
create mode 100644 tools/lib/util/find_next_bit.c
delete mode 100644 tools/perf/util/include/linux/bitops.h
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2014-12-16 16:57 Arnaldo Carvalho de Melo
@ 2014-12-17 14:50 ` Arnaldo Carvalho de Melo
2014-12-18 6:24 ` Ingo Molnar
0 siblings, 1 reply; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-12-17 14:50 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Adrian Hunter, Borislav Petkov, David Ahern,
Don Zickus, Frederic Weisbecker, Jiri Olsa, Mike Galbraith,
Mitchell Krome, Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Stephane Eranian
Em Tue, Dec 16, 2014 at 01:57:02PM -0300, Arnaldo Carvalho de Melo escreveu:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> The following changes since commit 41e950c033b7df997d4b38653efe6554be9b96a7:
>
> Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/urgent (2014-12-12 09:09:52 +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
Ingo,
Please consider pulling the perf-core-for-mingo-2 signed tag
instead, it is exactly the same content modulo removal of some
whitespaces at the end of a few lines in tools/perf/Makefile.perf that
Jiri found while reading those patches,
Thanks,
- Arnaldo
> for you to fetch changes up to 67195c75a87232f055ff415fc4624ef01f24fc3d:
>
> perf symbols: Fix use after free in filename__read_build_id (2014-12-16 13:38:28 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> User visible:
>
> - The mmap address range for the ring buffer now is calculated using the
> contents of /proc/sys/kernel/perf_event_mlock_kb.
>
> This fixes an -EPERM case where 'trace' was trying to use more than what
> configured on perf_event_mlock_kb. (Arnaldo Carvalho de Melo)
>
> Infrastructure:
>
> - Move bitops definitions so that they match the header file hierarchy
> in the kernel sources where that code came from. (Arnaldo Carvalho de Melo)
>
> - Adopt round{down,up}_pow_of_two from the kernel and use it instead of
> equivalent code, so that we reuse more kernel code and make tools/ look
> more like kernel source code, to encourage further contributions from
> kernel hackers (Arnaldo Carvalho de Melo)
>
> - Fix use after free in filename__read_build_id (Mitchell Krome)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Arnaldo Carvalho de Melo (17):
> perf evlist: Fixup brown paper bag on "hint" for --mmap-pages cmdline arg
> perf evlist: Clarify sterror_mmap variable names
> perf evlist: Improve the strerror_mmap method
> perf trace: Let the perf_evlist__mmap autosize the number of pages to use
> perf evlist: Do not use hard coded value for a mmap_pages default
> tools: Move __ffs implementation to tools/include/asm-generic/bitops/__ffs.h
> tools: Move code originally from linux/log2.h to tools/include/linux/
> tools: Move code originally from asm-generic/atomic.h into tools/include/asm-generic/
> tools: Whitespace prep patches for moving bitops.h
> tools lib: Move asm-generic/bitops/find.h code to tools/include and tools/lib
> tools: Introduce asm-generic/bitops.h
> tools: Move bitops.h from tools/perf/util to tools/
> tools: Adopt fls_long and deps
> tools: Adopt rounddown_pow_of_two and deps
> perf tools: Make the mmap length autotuning more robust
> tools: Adopt roundup_pow_of_two
> perf evlist: Use roundup_pow_of_two
>
> Mitchell Krome (1):
> perf symbols: Fix use after free in filename__read_build_id
>
> tools/include/asm-generic/bitops.h | 27 +++++
> tools/include/asm-generic/bitops/__ffs.h | 43 +++++++
> tools/include/asm-generic/bitops/__fls.h | 1 +
> tools/include/asm-generic/bitops/atomic.h | 22 ++++
> tools/include/asm-generic/bitops/find.h | 33 ++++++
> tools/include/asm-generic/bitops/fls.h | 1 +
> tools/include/asm-generic/bitops/fls64.h | 1 +
> tools/include/linux/bitops.h | 53 +++++++++
> tools/include/linux/log2.h | 185 ++++++++++++++++++++++++++++++
> tools/lib/util/find_next_bit.c | 89 ++++++++++++++
> tools/perf/MANIFEST | 13 ++-
> tools/perf/Makefile.perf | 14 ++-
> tools/perf/builtin-trace.c | 2 +-
> tools/perf/util/evlist.c | 46 ++++++--
> tools/perf/util/include/linux/bitops.h | 162 --------------------------
> tools/perf/util/symbol-minimal.c | 8 +-
> tools/perf/util/util.h | 29 -----
> 17 files changed, 522 insertions(+), 207 deletions(-)
> create mode 100644 tools/include/asm-generic/bitops.h
> create mode 100644 tools/include/asm-generic/bitops/__ffs.h
> create mode 100644 tools/include/asm-generic/bitops/__fls.h
> create mode 100644 tools/include/asm-generic/bitops/atomic.h
> create mode 100644 tools/include/asm-generic/bitops/find.h
> create mode 100644 tools/include/asm-generic/bitops/fls.h
> create mode 100644 tools/include/asm-generic/bitops/fls64.h
> create mode 100644 tools/include/linux/bitops.h
> create mode 100644 tools/include/linux/log2.h
> create mode 100644 tools/lib/util/find_next_bit.c
> delete mode 100644 tools/perf/util/include/linux/bitops.h
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2014-12-17 14:50 ` Arnaldo Carvalho de Melo
@ 2014-12-18 6:24 ` Ingo Molnar
0 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2014-12-18 6:24 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Adrian Hunter, Borislav Petkov, David Ahern,
Don Zickus, Frederic Weisbecker, Jiri Olsa, Mike Galbraith,
Mitchell Krome, Namhyung Kim, Paul Mackerras, Peter Zijlstra,
Stephane Eranian
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Em Tue, Dec 16, 2014 at 01:57:02PM -0300, Arnaldo Carvalho de Melo escreveu:
> > Hi Ingo,
> >
> > Please consider pulling,
> >
> > - Arnaldo
> >
> > The following changes since commit 41e950c033b7df997d4b38653efe6554be9b96a7:
> >
> > Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/urgent (2014-12-12 09:09:52 +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
>
> Ingo,
>
> Please consider pulling the perf-core-for-mingo-2 signed tag
> instead, it is exactly the same content modulo removal of some
> whitespaces at the end of a few lines in tools/perf/Makefile.perf that
> Jiri found while reading those patches,
Pulled, thanks a lot!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2014-11-06 21:04 Arnaldo Carvalho de Melo
2014-11-07 5:24 ` Ingo Molnar
0 siblings, 1 reply; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-11-06 21:04 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Corey Ashford, David Ahern, Frederic Weisbecker, Jiri Olsa,
Namhyung Kim, Paul Mackerras, Peter Zijlstra, Stephane Eranian,
Steven Rostedt, Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit daa01794a4a36a1da1b09a529adec0c8c0b94ab2:
perf evsel: Do not call pevent_free_format when deleting tracepoint (2014-11-06 17:47:14 -0300)
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 daa01794a4a36a1da1b09a529adec0c8c0b94ab2:
perf evsel: Do not call pevent_free_format when deleting tracepoint (2014-11-06 17:47:14 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
Infrastructure:
o Add gzip decompression support for kernel modules (Namhyung Kim)
o More prep patches for Intel PT, including a a thread stack and
more stuff made available via the database export mechanism (Adrian Hunter)
o Optimize checking that tracepoint events are defined in perf script perl/python (Jiri Olsa)
o Do not free pevent when deleting tracepoint evsel (Jiri Olsa)
o Fix build-id matching for vmlinux (Namhyung Kim)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2014-11-06 21:04 Arnaldo Carvalho de Melo
@ 2014-11-07 5:24 ` Ingo Molnar
0 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2014-11-07 5:24 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Adrian Hunter, Corey Ashford, David Ahern,
Frederic Weisbecker, Jiri Olsa, Namhyung Kim, Paul Mackerras,
Peter Zijlstra, Stephane Eranian, Steven Rostedt,
Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> The following changes since commit daa01794a4a36a1da1b09a529adec0c8c0b94ab2:
>
> perf evsel: Do not call pevent_free_format when deleting tracepoint (2014-11-06 17:47:14 -0300)
>
> 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 daa01794a4a36a1da1b09a529adec0c8c0b94ab2:
>
> perf evsel: Do not call pevent_free_format when deleting tracepoint (2014-11-06 17:47:14 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> Infrastructure:
>
> o Add gzip decompression support for kernel modules (Namhyung Kim)
>
> o More prep patches for Intel PT, including a a thread stack and
> more stuff made available via the database export mechanism (Adrian Hunter)
>
> o Optimize checking that tracepoint events are defined in perf script perl/python (Jiri Olsa)
>
> o Do not free pevent when deleting tracepoint evsel (Jiri Olsa)
>
> o Fix build-id matching for vmlinux (Namhyung Kim)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2014-08-15 16:49 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-08-15 16:49 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Alex Converse, Andi Kleen, Anshuman Khandual, Arun Sharma,
Brendan Gregg, Cody P Schafer, David Ahern, Elliott Hughes,
Frederic Weisbecker, Haren Myneni, Jiri Olsa, linuxppc-dev,
Masami Hiramatsu, Michael Ellerman, Namhyung Kim, Naohiro Aota,
Paul Mackerras, Peter Zijlstra, Rodrigo Campos, Stephane Eranian,
Sukadev Bhattiprolu, yrl.pp-manager.tt, Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit f373da34282560c60f0c197690eecb1b2dc49fc0:
Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2014-08-14 10:38:40 +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 759e612bf96627b64fcafe4174b3f6f2dedf2c0d:
perf stat: Use strerror_r instead of strerror (2014-08-15 13:08:40 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
User visible:
. Warn user to rebuild target with debuginfo in 'perf probe' (Masami Hiramatsu)
. Don't truncate Intel style addresses in 'annotate'. (Alex Converse)
Developer stuff:
. Annotate PMU related list_head members with type info. (Cody P Schafer)
. Add the triplet used for arm64 by Android (Elliott Hughes)
. Replace thread unsafe strerror() with strerror_r() accross the
whole tools/perf/ tree (Masami Hiramatsu)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Alex Converse (1):
perf annotate: Don't truncate Intel style addresses
Cody P Schafer (1):
perf tools: Annotate PMU related list_head members with type info
Elliott Hughes (1):
perf tools: Add arm64 triplets
Masami Hiramatsu (14):
perf probe: Warn user to rebuild target with debuginfo
perf probe: Don't use strerror if strlist__add failed
perf: Use strerror_r instead of strerror
perf probe: Make error messages thread-safe
perf util: Replace strerror with strerror_r for thread-safety
perf top: Use strerror_r instead of strerror
perf trace: Use strerror_r instead of strerror
perf record: Use strerror_r instead of strerror
perf test: Use strerror_r instead of strerror
perf sched: Use strerror_r instead of strerror
perf buildid-cache: Use strerror_r instead of strerror
perf kvm: Use strerror_r instead of strerror
perf help: Use strerror_r instead of strerror
perf stat: Use strerror_r instead of strerror
Namhyung Kim (1):
perf report: Relax -g option parsing not to limit the option order
tools/perf/arch/common.c | 9 +++
tools/perf/builtin-buildid-cache.c | 7 ++-
tools/perf/builtin-help.c | 20 +++++--
tools/perf/builtin-kvm.c | 7 ++-
tools/perf/builtin-probe.c | 5 +-
tools/perf/builtin-record.c | 7 ++-
tools/perf/builtin-sched.c | 4 +-
tools/perf/builtin-stat.c | 2 +-
tools/perf/builtin-top.c | 2 +-
tools/perf/builtin-trace.c | 6 +-
tools/perf/perf.c | 10 +++-
tools/perf/tests/builtin-test.c | 4 +-
tools/perf/tests/mmap-basic.c | 7 ++-
tools/perf/tests/open-syscall-all-cpus.c | 5 +-
tools/perf/tests/open-syscall-tp-fields.c | 7 ++-
tools/perf/tests/open-syscall.c | 3 +-
tools/perf/tests/perf-record.c | 13 +++--
tools/perf/tests/rdpmc.c | 6 +-
tools/perf/tests/sw-clock.c | 6 +-
tools/perf/tests/task-exit.c | 6 +-
tools/perf/util/annotate.c | 12 +++-
tools/perf/util/callchain.c | 95 +++++++++++++------------------
tools/perf/util/cloexec.c | 6 +-
tools/perf/util/data.c | 8 ++-
tools/perf/util/debug.h | 3 +
tools/perf/util/dso.c | 8 ++-
tools/perf/util/evlist.c | 2 +-
tools/perf/util/evsel.c | 7 ++-
tools/perf/util/parse-events.c | 5 +-
tools/perf/util/pmu.c | 4 +-
tools/perf/util/pmu.h | 6 +-
tools/perf/util/probe-event.c | 75 +++++++++++++-----------
tools/perf/util/probe-finder.c | 7 ++-
tools/perf/util/run-command.c | 9 ++-
tools/perf/util/util.c | 5 +-
35 files changed, 234 insertions(+), 154 deletions(-)
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2014-08-15 16:49 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-08-15 16:49 UTC (permalink / raw)
To: Ingo Molnar
Cc: Peter Zijlstra, Frederic Weisbecker, Alex Converse,
Adrian Hunter, Paul Mackerras, Masami Hiramatsu, Jiri Olsa,
Anshuman Khandual, Namhyung Kim, Andi Kleen, Cody P Schafer,
Sukadev Bhattiprolu, Arun Sharma, Naohiro Aota,
Arnaldo Carvalho de Melo, Arnaldo Carvalho de Melo,
Stephane Eranian, yrl.pp-manager.tt, Michael Ellerman,
Rodrigo Campos, linux-kernel, David Ahern, Brendan Gregg,
Elliott Hughes, linuxppc-dev
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit f373da34282560c60f0c197690eecb1b2dc49fc0:
Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2014-08-14 10:38:40 +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 759e612bf96627b64fcafe4174b3f6f2dedf2c0d:
perf stat: Use strerror_r instead of strerror (2014-08-15 13:08:40 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
User visible:
. Warn user to rebuild target with debuginfo in 'perf probe' (Masami Hiramatsu)
. Don't truncate Intel style addresses in 'annotate'. (Alex Converse)
Developer stuff:
. Annotate PMU related list_head members with type info. (Cody P Schafer)
. Add the triplet used for arm64 by Android (Elliott Hughes)
. Replace thread unsafe strerror() with strerror_r() accross the
whole tools/perf/ tree (Masami Hiramatsu)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Alex Converse (1):
perf annotate: Don't truncate Intel style addresses
Cody P Schafer (1):
perf tools: Annotate PMU related list_head members with type info
Elliott Hughes (1):
perf tools: Add arm64 triplets
Masami Hiramatsu (14):
perf probe: Warn user to rebuild target with debuginfo
perf probe: Don't use strerror if strlist__add failed
perf: Use strerror_r instead of strerror
perf probe: Make error messages thread-safe
perf util: Replace strerror with strerror_r for thread-safety
perf top: Use strerror_r instead of strerror
perf trace: Use strerror_r instead of strerror
perf record: Use strerror_r instead of strerror
perf test: Use strerror_r instead of strerror
perf sched: Use strerror_r instead of strerror
perf buildid-cache: Use strerror_r instead of strerror
perf kvm: Use strerror_r instead of strerror
perf help: Use strerror_r instead of strerror
perf stat: Use strerror_r instead of strerror
Namhyung Kim (1):
perf report: Relax -g option parsing not to limit the option order
tools/perf/arch/common.c | 9 +++
tools/perf/builtin-buildid-cache.c | 7 ++-
tools/perf/builtin-help.c | 20 +++++--
tools/perf/builtin-kvm.c | 7 ++-
tools/perf/builtin-probe.c | 5 +-
tools/perf/builtin-record.c | 7 ++-
tools/perf/builtin-sched.c | 4 +-
tools/perf/builtin-stat.c | 2 +-
tools/perf/builtin-top.c | 2 +-
tools/perf/builtin-trace.c | 6 +-
tools/perf/perf.c | 10 +++-
tools/perf/tests/builtin-test.c | 4 +-
tools/perf/tests/mmap-basic.c | 7 ++-
tools/perf/tests/open-syscall-all-cpus.c | 5 +-
tools/perf/tests/open-syscall-tp-fields.c | 7 ++-
tools/perf/tests/open-syscall.c | 3 +-
tools/perf/tests/perf-record.c | 13 +++--
tools/perf/tests/rdpmc.c | 6 +-
tools/perf/tests/sw-clock.c | 6 +-
tools/perf/tests/task-exit.c | 6 +-
tools/perf/util/annotate.c | 12 +++-
tools/perf/util/callchain.c | 95 +++++++++++++------------------
tools/perf/util/cloexec.c | 6 +-
tools/perf/util/data.c | 8 ++-
tools/perf/util/debug.h | 3 +
tools/perf/util/dso.c | 8 ++-
tools/perf/util/evlist.c | 2 +-
tools/perf/util/evsel.c | 7 ++-
tools/perf/util/parse-events.c | 5 +-
tools/perf/util/pmu.c | 4 +-
tools/perf/util/pmu.h | 6 +-
tools/perf/util/probe-event.c | 75 +++++++++++++-----------
tools/perf/util/probe-finder.c | 7 ++-
tools/perf/util/run-command.c | 9 ++-
tools/perf/util/util.c | 5 +-
35 files changed, 234 insertions(+), 154 deletions(-)
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
2014-08-15 16:49 ` Arnaldo Carvalho de Melo
@ 2014-08-18 8:18 ` Ingo Molnar
-1 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2014-08-18 8:18 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: linux-kernel, Adrian Hunter, Alex Converse, Andi Kleen,
Anshuman Khandual, Arun Sharma, Brendan Gregg, Cody P Schafer,
David Ahern, Elliott Hughes, Frederic Weisbecker, Haren Myneni,
Jiri Olsa, linuxppc-dev, Masami Hiramatsu, Michael Ellerman,
Namhyung Kim, Naohiro Aota, Paul Mackerras, Peter Zijlstra,
Rodrigo Campos, Stephane Eranian, Sukadev Bhattiprolu,
yrl.pp-manager.tt, Arnaldo Carvalho de Melo
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> The following changes since commit f373da34282560c60f0c197690eecb1b2dc49fc0:
>
> Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2014-08-14 10:38:40 +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 759e612bf96627b64fcafe4174b3f6f2dedf2c0d:
>
> perf stat: Use strerror_r instead of strerror (2014-08-15 13:08:40 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> User visible:
>
> . Warn user to rebuild target with debuginfo in 'perf probe' (Masami Hiramatsu)
>
> . Don't truncate Intel style addresses in 'annotate'. (Alex Converse)
>
> Developer stuff:
>
> . Annotate PMU related list_head members with type info. (Cody P Schafer)
>
> . Add the triplet used for arm64 by Android (Elliott Hughes)
>
> . Replace thread unsafe strerror() with strerror_r() accross the
> whole tools/perf/ tree (Masami Hiramatsu)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Alex Converse (1):
> perf annotate: Don't truncate Intel style addresses
>
> Cody P Schafer (1):
> perf tools: Annotate PMU related list_head members with type info
>
> Elliott Hughes (1):
> perf tools: Add arm64 triplets
>
> Masami Hiramatsu (14):
> perf probe: Warn user to rebuild target with debuginfo
> perf probe: Don't use strerror if strlist__add failed
> perf: Use strerror_r instead of strerror
> perf probe: Make error messages thread-safe
> perf util: Replace strerror with strerror_r for thread-safety
> perf top: Use strerror_r instead of strerror
> perf trace: Use strerror_r instead of strerror
> perf record: Use strerror_r instead of strerror
> perf test: Use strerror_r instead of strerror
> perf sched: Use strerror_r instead of strerror
> perf buildid-cache: Use strerror_r instead of strerror
> perf kvm: Use strerror_r instead of strerror
> perf help: Use strerror_r instead of strerror
> perf stat: Use strerror_r instead of strerror
>
> Namhyung Kim (1):
> perf report: Relax -g option parsing not to limit the option order
>
> tools/perf/arch/common.c | 9 +++
> tools/perf/builtin-buildid-cache.c | 7 ++-
> tools/perf/builtin-help.c | 20 +++++--
> tools/perf/builtin-kvm.c | 7 ++-
> tools/perf/builtin-probe.c | 5 +-
> tools/perf/builtin-record.c | 7 ++-
> tools/perf/builtin-sched.c | 4 +-
> tools/perf/builtin-stat.c | 2 +-
> tools/perf/builtin-top.c | 2 +-
> tools/perf/builtin-trace.c | 6 +-
> tools/perf/perf.c | 10 +++-
> tools/perf/tests/builtin-test.c | 4 +-
> tools/perf/tests/mmap-basic.c | 7 ++-
> tools/perf/tests/open-syscall-all-cpus.c | 5 +-
> tools/perf/tests/open-syscall-tp-fields.c | 7 ++-
> tools/perf/tests/open-syscall.c | 3 +-
> tools/perf/tests/perf-record.c | 13 +++--
> tools/perf/tests/rdpmc.c | 6 +-
> tools/perf/tests/sw-clock.c | 6 +-
> tools/perf/tests/task-exit.c | 6 +-
> tools/perf/util/annotate.c | 12 +++-
> tools/perf/util/callchain.c | 95 +++++++++++++------------------
> tools/perf/util/cloexec.c | 6 +-
> tools/perf/util/data.c | 8 ++-
> tools/perf/util/debug.h | 3 +
> tools/perf/util/dso.c | 8 ++-
> tools/perf/util/evlist.c | 2 +-
> tools/perf/util/evsel.c | 7 ++-
> tools/perf/util/parse-events.c | 5 +-
> tools/perf/util/pmu.c | 4 +-
> tools/perf/util/pmu.h | 6 +-
> tools/perf/util/probe-event.c | 75 +++++++++++++-----------
> tools/perf/util/probe-finder.c | 7 ++-
> tools/perf/util/run-command.c | 9 ++-
> tools/perf/util/util.c | 5 +-
> 35 files changed, 234 insertions(+), 154 deletions(-)
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* Re: [GIT PULL 00/18] perf/core improvements and fixes
@ 2014-08-18 8:18 ` Ingo Molnar
0 siblings, 0 replies; 57+ messages in thread
From: Ingo Molnar @ 2014-08-18 8:18 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo
Cc: Peter Zijlstra, Frederic Weisbecker, Alex Converse,
Adrian Hunter, Paul Mackerras, Masami Hiramatsu, Jiri Olsa,
Anshuman Khandual, Namhyung Kim, Andi Kleen, Cody P Schafer,
Sukadev Bhattiprolu, Arun Sharma, Naohiro Aota,
Arnaldo Carvalho de Melo, Stephane Eranian, yrl.pp-manager.tt,
Michael Ellerman, Rodrigo Campos, linux-kernel, David Ahern,
Brendan Gregg, Elliott Hughes, linuxppc-dev
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Hi Ingo,
>
> Please consider pulling,
>
> - Arnaldo
>
> The following changes since commit f373da34282560c60f0c197690eecb1b2dc49fc0:
>
> Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2014-08-14 10:38:40 +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 759e612bf96627b64fcafe4174b3f6f2dedf2c0d:
>
> perf stat: Use strerror_r instead of strerror (2014-08-15 13:08:40 -0300)
>
> ----------------------------------------------------------------
> perf/core improvements and fixes:
>
> User visible:
>
> . Warn user to rebuild target with debuginfo in 'perf probe' (Masami Hiramatsu)
>
> . Don't truncate Intel style addresses in 'annotate'. (Alex Converse)
>
> Developer stuff:
>
> . Annotate PMU related list_head members with type info. (Cody P Schafer)
>
> . Add the triplet used for arm64 by Android (Elliott Hughes)
>
> . Replace thread unsafe strerror() with strerror_r() accross the
> whole tools/perf/ tree (Masami Hiramatsu)
>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
>
> ----------------------------------------------------------------
> Alex Converse (1):
> perf annotate: Don't truncate Intel style addresses
>
> Cody P Schafer (1):
> perf tools: Annotate PMU related list_head members with type info
>
> Elliott Hughes (1):
> perf tools: Add arm64 triplets
>
> Masami Hiramatsu (14):
> perf probe: Warn user to rebuild target with debuginfo
> perf probe: Don't use strerror if strlist__add failed
> perf: Use strerror_r instead of strerror
> perf probe: Make error messages thread-safe
> perf util: Replace strerror with strerror_r for thread-safety
> perf top: Use strerror_r instead of strerror
> perf trace: Use strerror_r instead of strerror
> perf record: Use strerror_r instead of strerror
> perf test: Use strerror_r instead of strerror
> perf sched: Use strerror_r instead of strerror
> perf buildid-cache: Use strerror_r instead of strerror
> perf kvm: Use strerror_r instead of strerror
> perf help: Use strerror_r instead of strerror
> perf stat: Use strerror_r instead of strerror
>
> Namhyung Kim (1):
> perf report: Relax -g option parsing not to limit the option order
>
> tools/perf/arch/common.c | 9 +++
> tools/perf/builtin-buildid-cache.c | 7 ++-
> tools/perf/builtin-help.c | 20 +++++--
> tools/perf/builtin-kvm.c | 7 ++-
> tools/perf/builtin-probe.c | 5 +-
> tools/perf/builtin-record.c | 7 ++-
> tools/perf/builtin-sched.c | 4 +-
> tools/perf/builtin-stat.c | 2 +-
> tools/perf/builtin-top.c | 2 +-
> tools/perf/builtin-trace.c | 6 +-
> tools/perf/perf.c | 10 +++-
> tools/perf/tests/builtin-test.c | 4 +-
> tools/perf/tests/mmap-basic.c | 7 ++-
> tools/perf/tests/open-syscall-all-cpus.c | 5 +-
> tools/perf/tests/open-syscall-tp-fields.c | 7 ++-
> tools/perf/tests/open-syscall.c | 3 +-
> tools/perf/tests/perf-record.c | 13 +++--
> tools/perf/tests/rdpmc.c | 6 +-
> tools/perf/tests/sw-clock.c | 6 +-
> tools/perf/tests/task-exit.c | 6 +-
> tools/perf/util/annotate.c | 12 +++-
> tools/perf/util/callchain.c | 95 +++++++++++++------------------
> tools/perf/util/cloexec.c | 6 +-
> tools/perf/util/data.c | 8 ++-
> tools/perf/util/debug.h | 3 +
> tools/perf/util/dso.c | 8 ++-
> tools/perf/util/evlist.c | 2 +-
> tools/perf/util/evsel.c | 7 ++-
> tools/perf/util/parse-events.c | 5 +-
> tools/perf/util/pmu.c | 4 +-
> tools/perf/util/pmu.h | 6 +-
> tools/perf/util/probe-event.c | 75 +++++++++++++-----------
> tools/perf/util/probe-finder.c | 7 ++-
> tools/perf/util/run-command.c | 9 ++-
> tools/perf/util/util.c | 5 +-
> 35 files changed, 234 insertions(+), 154 deletions(-)
Pulled, thanks a lot Arnaldo!
Ingo
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2014-08-15 16:48 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-08-15 16:48 UTC (permalink / raw)
To: Ingo Molnar
Cc: linux-kernel, Arnaldo Carvalho de Melo, Adrian Hunter,
Alex Converse, Andi Kleen, Anshuman Khandual, Arun Sharma,
Brendan Gregg, Cody P Schafer, David Ahern, Elliott Hughes,
Frederic Weisbecker, Haren Myneni, Jiri Olsa, linuxppc-dev,
Masami Hiramatsu, Michael Ellerman, Namhyung Kim, Naohiro Aota,
Paul Mackerras, Peter Zijlstra, Rodrigo Campos, Stephane Eranian,
Sukadev Bhattiprolu, yrl.pp-manager.tt, Arnaldo Carvalho de Melo
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit f373da34282560c60f0c197690eecb1b2dc49fc0:
Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2014-08-14 10:38:40 +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 759e612bf96627b64fcafe4174b3f6f2dedf2c0d:
perf stat: Use strerror_r instead of strerror (2014-08-15 13:08:40 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
User visible:
. Warn user to rebuild target with debuginfo in 'perf probe' (Masami Hiramatsu)
. Don't truncate Intel style addresses in 'annotate'. (Alex Converse)
Developer stuff:
. Annotate PMU related list_head members with type info. (Cody P Schafer)
. Add the triplet used for arm64 by Android (Elliott Hughes)
. Replace thread unsafe strerror() with strerror_r() accross the
whole tools/perf/ tree (Masami Hiramatsu)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Alex Converse (1):
perf annotate: Don't truncate Intel style addresses
Cody P Schafer (1):
perf tools: Annotate PMU related list_head members with type info
Elliott Hughes (1):
perf tools: Add arm64 triplets
Masami Hiramatsu (14):
perf probe: Warn user to rebuild target with debuginfo
perf probe: Don't use strerror if strlist__add failed
perf: Use strerror_r instead of strerror
perf probe: Make error messages thread-safe
perf util: Replace strerror with strerror_r for thread-safety
perf top: Use strerror_r instead of strerror
perf trace: Use strerror_r instead of strerror
perf record: Use strerror_r instead of strerror
perf test: Use strerror_r instead of strerror
perf sched: Use strerror_r instead of strerror
perf buildid-cache: Use strerror_r instead of strerror
perf kvm: Use strerror_r instead of strerror
perf help: Use strerror_r instead of strerror
perf stat: Use strerror_r instead of strerror
Namhyung Kim (1):
perf report: Relax -g option parsing not to limit the option order
tools/perf/arch/common.c | 9 +++
tools/perf/builtin-buildid-cache.c | 7 ++-
tools/perf/builtin-help.c | 20 +++++--
tools/perf/builtin-kvm.c | 7 ++-
tools/perf/builtin-probe.c | 5 +-
tools/perf/builtin-record.c | 7 ++-
tools/perf/builtin-sched.c | 4 +-
tools/perf/builtin-stat.c | 2 +-
tools/perf/builtin-top.c | 2 +-
tools/perf/builtin-trace.c | 6 +-
tools/perf/perf.c | 10 +++-
tools/perf/tests/builtin-test.c | 4 +-
tools/perf/tests/mmap-basic.c | 7 ++-
tools/perf/tests/open-syscall-all-cpus.c | 5 +-
tools/perf/tests/open-syscall-tp-fields.c | 7 ++-
tools/perf/tests/open-syscall.c | 3 +-
tools/perf/tests/perf-record.c | 13 +++--
tools/perf/tests/rdpmc.c | 6 +-
tools/perf/tests/sw-clock.c | 6 +-
tools/perf/tests/task-exit.c | 6 +-
tools/perf/util/annotate.c | 12 +++-
tools/perf/util/callchain.c | 95 +++++++++++++------------------
tools/perf/util/cloexec.c | 6 +-
tools/perf/util/data.c | 8 ++-
tools/perf/util/debug.h | 3 +
tools/perf/util/dso.c | 8 ++-
tools/perf/util/evlist.c | 2 +-
tools/perf/util/evsel.c | 7 ++-
tools/perf/util/parse-events.c | 5 +-
tools/perf/util/pmu.c | 4 +-
tools/perf/util/pmu.h | 6 +-
tools/perf/util/probe-event.c | 75 +++++++++++++-----------
tools/perf/util/probe-finder.c | 7 ++-
tools/perf/util/run-command.c | 9 ++-
tools/perf/util/util.c | 5 +-
35 files changed, 234 insertions(+), 154 deletions(-)
^ permalink raw reply [flat|nested] 57+ messages in thread
* [GIT PULL 00/18] perf/core improvements and fixes
@ 2014-08-15 16:48 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 57+ messages in thread
From: Arnaldo Carvalho de Melo @ 2014-08-15 16:48 UTC (permalink / raw)
To: Ingo Molnar
Cc: Peter Zijlstra, Frederic Weisbecker, Alex Converse,
Adrian Hunter, Paul Mackerras, Masami Hiramatsu, Jiri Olsa,
Anshuman Khandual, Namhyung Kim, Andi Kleen, Cody P Schafer,
Sukadev Bhattiprolu, Arun Sharma, Naohiro Aota,
Arnaldo Carvalho de Melo, Arnaldo Carvalho de Melo,
Stephane Eranian, yrl.pp-manager.tt, Michael Ellerman,
Rodrigo Campos, linux-kernel, David Ahern, Brendan Gregg,
Elliott Hughes, linuxppc-dev
Hi Ingo,
Please consider pulling,
- Arnaldo
The following changes since commit f373da34282560c60f0c197690eecb1b2dc49fc0:
Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2014-08-14 10:38:40 +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 759e612bf96627b64fcafe4174b3f6f2dedf2c0d:
perf stat: Use strerror_r instead of strerror (2014-08-15 13:08:40 -0300)
----------------------------------------------------------------
perf/core improvements and fixes:
User visible:
. Warn user to rebuild target with debuginfo in 'perf probe' (Masami Hiramatsu)
. Don't truncate Intel style addresses in 'annotate'. (Alex Converse)
Developer stuff:
. Annotate PMU related list_head members with type info. (Cody P Schafer)
. Add the triplet used for arm64 by Android (Elliott Hughes)
. Replace thread unsafe strerror() with strerror_r() accross the
whole tools/perf/ tree (Masami Hiramatsu)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
----------------------------------------------------------------
Alex Converse (1):
perf annotate: Don't truncate Intel style addresses
Cody P Schafer (1):
perf tools: Annotate PMU related list_head members with type info
Elliott Hughes (1):
perf tools: Add arm64 triplets
Masami Hiramatsu (14):
perf probe: Warn user to rebuild target with debuginfo
perf probe: Don't use strerror if strlist__add failed
perf: Use strerror_r instead of strerror
perf probe: Make error messages thread-safe
perf util: Replace strerror with strerror_r for thread-safety
perf top: Use strerror_r instead of strerror
perf trace: Use strerror_r instead of strerror
perf record: Use strerror_r instead of strerror
perf test: Use strerror_r instead of strerror
perf sched: Use strerror_r instead of strerror
perf buildid-cache: Use strerror_r instead of strerror
perf kvm: Use strerror_r instead of strerror
perf help: Use strerror_r instead of strerror
perf stat: Use strerror_r instead of strerror
Namhyung Kim (1):
perf report: Relax -g option parsing not to limit the option order
tools/perf/arch/common.c | 9 +++
tools/perf/builtin-buildid-cache.c | 7 ++-
tools/perf/builtin-help.c | 20 +++++--
tools/perf/builtin-kvm.c | 7 ++-
tools/perf/builtin-probe.c | 5 +-
tools/perf/builtin-record.c | 7 ++-
tools/perf/builtin-sched.c | 4 +-
tools/perf/builtin-stat.c | 2 +-
tools/perf/builtin-top.c | 2 +-
tools/perf/builtin-trace.c | 6 +-
tools/perf/perf.c | 10 +++-
tools/perf/tests/builtin-test.c | 4 +-
tools/perf/tests/mmap-basic.c | 7 ++-
tools/perf/tests/open-syscall-all-cpus.c | 5 +-
tools/perf/tests/open-syscall-tp-fields.c | 7 ++-
tools/perf/tests/open-syscall.c | 3 +-
tools/perf/tests/perf-record.c | 13 +++--
tools/perf/tests/rdpmc.c | 6 +-
tools/perf/tests/sw-clock.c | 6 +-
tools/perf/tests/task-exit.c | 6 +-
tools/perf/util/annotate.c | 12 +++-
tools/perf/util/callchain.c | 95 +++++++++++++------------------
tools/perf/util/cloexec.c | 6 +-
tools/perf/util/data.c | 8 ++-
tools/perf/util/debug.h | 3 +
tools/perf/util/dso.c | 8 ++-
tools/perf/util/evlist.c | 2 +-
tools/perf/util/evsel.c | 7 ++-
tools/perf/util/parse-events.c | 5 +-
tools/perf/util/pmu.c | 4 +-
tools/perf/util/pmu.h | 6 +-
tools/perf/util/probe-event.c | 75 +++++++++++++-----------
tools/perf/util/probe-finder.c | 7 ++-
tools/perf/util/run-command.c | 9 ++-
tools/perf/util/util.c | 5 +-
35 files changed, 234 insertions(+), 154 deletions(-)
^ permalink raw reply [flat|nested] 57+ messages in thread
end of thread, other threads:[~2018-05-19 11:34 UTC | newest]
Thread overview: 57+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-12-11 21:25 [GIT PULL 00/18] perf/core improvements and fixes Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 01/18] perf bench: Prepare memcpy for merge Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 02/18] perf bench: Merge memset into memcpy Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 03/18] perf bench: Fix memcpy/memset output Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 04/18] perf hists browser: Change print format from %lu to %PRIu64 Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 05/18] perf tools: Use single strcmp call instead of two Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 06/18] perf buildid-cache: Remove extra debugdir variables Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 07/18] perf buildid cache: Fix -a segfault related to kcore handling Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 08/18] perf tools: Add --buildid-dir option to set cache directory Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 09/18] perf callchain: Fixup parameter handling error message Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 10/18] perf callchain: Move cpumode resolve code to add_callchain_ip Arnaldo Carvalho de Melo
2014-12-11 21:25 ` [PATCH 11/18] calloc/xcalloc: Fix argument order Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 12/18] perf tests: Fix attr tests size values to cope with machine state on interrupt ABI changes Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 13/18] perf kvm stat live: Mark events as (x86 only) in help output Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 14/18] tools lib fs: Adopt filename__read_int from tools/perf/ Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 15/18] tools lib fs: Add sysctl__read_int helper Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 16/18] perf tools: Use sysctl__read_int instead of ad-hoc copies Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 17/18] perf evlist: Introduce strerror_mmap method Arnaldo Carvalho de Melo
2014-12-11 21:26 ` [PATCH 18/18] perf trace: Provide a better explanation when mmap fails Arnaldo Carvalho de Melo
2014-12-12 8:10 ` [GIT PULL 00/18] perf/core improvements and fixes Ingo Molnar
-- strict thread matches above, loose matches on Subject: below --
2018-05-19 10:54 Arnaldo Carvalho de Melo
2018-05-19 10:54 ` Arnaldo Carvalho de Melo
2018-05-19 11:33 ` Ingo Molnar
2018-05-19 11:33 ` Ingo Molnar
2017-08-29 19:42 Arnaldo Carvalho de Melo
2017-08-29 19:42 ` Arnaldo Carvalho de Melo
2017-08-29 21:15 ` Ingo Molnar
2017-08-29 21:15 ` Ingo Molnar
2017-04-12 0:51 Arnaldo Carvalho de Melo
2017-04-12 5:30 ` Ingo Molnar
2017-04-12 7:13 ` Christian Borntraeger
2017-04-12 7:24 ` Ingo Molnar
2017-02-20 19:08 Arnaldo Carvalho de Melo
2017-02-21 8:08 ` Ingo Molnar
2016-11-23 16:40 Arnaldo Carvalho de Melo
2016-11-24 4:10 ` Ingo Molnar
2016-06-27 21:01 Arnaldo Carvalho de Melo
2016-06-28 7:02 ` Ingo Molnar
2016-06-28 8:27 ` Jiri Olsa
2016-06-28 14:01 ` Arnaldo Carvalho de Melo
2016-06-28 14:12 ` Arnaldo Carvalho de Melo
2016-06-29 9:36 ` Ingo Molnar
2015-07-24 1:58 Arnaldo Carvalho de Melo
2015-07-27 15:58 ` Ingo Molnar
2015-05-18 15:50 Arnaldo Carvalho de Melo
2015-05-20 11:25 ` Ingo Molnar
2014-12-16 16:57 Arnaldo Carvalho de Melo
2014-12-17 14:50 ` Arnaldo Carvalho de Melo
2014-12-18 6:24 ` Ingo Molnar
2014-11-06 21:04 Arnaldo Carvalho de Melo
2014-11-07 5:24 ` Ingo Molnar
2014-08-15 16:49 Arnaldo Carvalho de Melo
2014-08-15 16:49 ` Arnaldo Carvalho de Melo
2014-08-18 8:18 ` Ingo Molnar
2014-08-18 8:18 ` Ingo Molnar
2014-08-15 16:48 Arnaldo Carvalho de Melo
2014-08-15 16:48 ` 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.