Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1505012 > unrolled thread

[GIT PULL 00/52] New Tool: perf c2c

Started byArnaldo Carvalho de Melo <acme@kernel.org>
First post2016-10-20 17:20 +0200
Last post2016-10-24 11:50 +0200
Articles 8 on this page of 28 — 6 participants

Back to article view | Back to linux.kernel


Contents

  [GIT PULL 00/52] New Tool: perf c2c Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 16/52] perf c2c report: Add hitm related dimension keys Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 29/52] perf c2c report: Add 'node' sort key Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 26/52] perf c2c report: Add 'pid' sort key Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 02/52] perf c2c: Introduce c2c_add_stats function Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 45/52] perf c2c report: Recalc width of global sort entries Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 30/52] perf c2c report: Add stats related sort keys Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 27/52] perf c2c report: Add 'tid' sort key Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 50/52] perf c2c: Add man page and credits Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 31/52] perf c2c report: Add 'cpucnt' sort key Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 19/52] perf c2c report: Add llc and remote loads related dimension keys Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 39/52] perf c2c report: Add shared cachelines stats stdio output Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 10/52] perf c2c report: Add cacheline hists processing Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 23/52] perf c2c report: Add hitm percent sort key Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 05/52] perf c2c: Add report subcommand Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 04/52] perf c2c: Add record subcommand Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    [PATCH 15/52] perf c2c report: Add 'iaddr' dimension key Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-10-20 17:20 +0200
    Re: [GIT PULL 00/52] New Tool: perf c2c Kim Phillips <kim.phillips@arm.com> - 2016-10-21 01:10 +0200
      [PATCH] perf c2c report: Properly check data presence in rb_tree loop Jiri Olsa <jolsa@redhat.com> - 2016-10-21 02:20 +0200
        Re: [PATCH] perf c2c report: Properly check data presence in  rb_tree loop Kim Phillips <kim.phillips@arm.com> - 2016-10-21 21:30 +0200
        [tip:perf/core] perf c2c report: Add main TUI browser tip-bot for Jiri Olsa <tipbot@zytor.com> - 2016-10-22 11:00 +0200
      Re: [GIT PULL 00/52] New Tool: perf c2c Jiri Olsa <jolsa@redhat.com> - 2016-10-21 02:30 +0200
    Re: [GIT PULL 00/52] New Tool: perf c2c Ingo Molnar <mingo@kernel.org> - 2016-10-22 10:30 +0200
      Re: [GIT PULL 00/52] New Tool: perf c2c Jiri Olsa <jolsa@redhat.com> - 2016-10-23 13:10 +0200
        Re: [GIT PULL 00/52] New Tool: perf c2c Andi Kleen <andi@firstfloor.org> - 2016-10-24 01:50 +0200
          Re: [GIT PULL 00/52] New Tool: perf c2c Jiri Olsa <jolsa@redhat.com> - 2016-10-24 08:40 +0200
        Re: [GIT PULL 00/52] New Tool: perf c2c Ingo Molnar <mingo@kernel.org> - 2016-10-24 11:30 +0200
          Re: [GIT PULL 00/52] New Tool: perf c2c Jiri Olsa <jolsa@redhat.com> - 2016-10-24 11:50 +0200

Page 2 of 2 — ← Prev page 1 [2]


#1506451 — [tip:perf/core] perf c2c report: Add main TUI browser

Fromtip-bot for Jiri Olsa <tipbot@zytor.com>
Date2016-10-22 11:00 +0200
Subject[tip:perf/core] perf c2c report: Add main TUI browser
Message-ID<sv0jM-195-33@gated-at.bofh.it>
In reply to#1505349
Commit-ID:  5a1a99cd2e4e15571a74f65facf05f806d5303fd
Gitweb:     http://git.kernel.org/tip/5a1a99cd2e4e15571a74f65facf05f806d5303fd
Author:     Jiri Olsa <jolsa@kernel.org>
AuthorDate: Wed, 6 Jan 2016 16:59:02 +0100
Committer:  Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Fri, 21 Oct 2016 10:30:03 -0300

perf c2c report: Add main TUI browser

Add the main cachelines TUI browser. It allows to navigate through
cachelines and display their details and callchains (implemented in the
following patches).

Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Joe Mario <jmario@redhat.com>
Cc: Kim Phillips <kim.phillips@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/n/tip-pk632k4h1uwc5t0lqc7k61zg@git.kernel.org
Link: http://lkml.kernel.org/r/20161021001706.GB23970@krava
[ Handle file with no entries, fixing segfault reported by Kim Phillips ]
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
 tools/perf/builtin-c2c.c       | 117 ++++++++++++++++++++++++++++++++++++++++-
 tools/perf/ui/browsers/hists.c |   2 +-
 tools/perf/ui/browsers/hists.h |   1 +
 3 files changed, 117 insertions(+), 3 deletions(-)

diff --git a/tools/perf/builtin-c2c.c b/tools/perf/builtin-c2c.c
index 33db26c..34da2a3 100644
--- a/tools/perf/builtin-c2c.c
+++ b/tools/perf/builtin-c2c.c
@@ -14,6 +14,7 @@
 #include "data.h"
 #include "sort.h"
 #include <asm/bug.h>
+#include "ui/browsers/hists.h"
 
 struct c2c_hists {
 	struct hists		hists;
@@ -53,6 +54,7 @@ struct perf_c2c {
 	int			 node_info;
 
 	bool			 show_src;
+	bool			 use_stdio;
 };
 
 static struct perf_c2c c2c;
@@ -657,6 +659,10 @@ percent_color(struct perf_hpp_fmt *fmt, struct perf_hpp *hpp,
 	c2c_he = container_of(he, struct c2c_hist_entry, he);
 	per = get_percent(c2c_he);
 
+#ifdef HAVE_SLANG_SUPPORT
+	if (use_browser)
+		return __hpp__slsmg_color_printf(hpp, "%*.2f%%", width - 1, per);
+#endif
 	return hpp_color_scnprintf(hpp, "%*.2f%%", width - 1, per);
 }
 
@@ -1077,6 +1083,8 @@ static struct c2c_dimension dim_dcacheline = {
 	.width		= 18,
 };
 
+static struct c2c_header header_offset_tui = HEADER_LOW("Off");
+
 static struct c2c_dimension dim_offset = {
 	.header		= HEADER_BOTH("Data address", "Offset"),
 	.name		= "offset",
@@ -1803,6 +1811,100 @@ static void perf_c2c__hists_fprintf(FILE *out)
 	print_pareto(out);
 }
 
+#ifdef HAVE_SLANG_SUPPORT
+static void c2c_browser__update_nr_entries(struct hist_browser *hb)
+{
+	u64 nr_entries = 0;
+	struct rb_node *nd = rb_first(&hb->hists->entries);
+
+	while (nd) {
+		struct hist_entry *he = rb_entry(nd, struct hist_entry, rb_node);
+
+		if (!he->filtered)
+			nr_entries++;
+
+		nd = rb_next(nd);
+	}
+
+	hb->nr_non_filtered_entries = nr_entries;
+}
+
+static int perf_c2c_browser__title(struct hist_browser *browser,
+				   char *bf, size_t size)
+{
+	scnprintf(bf, size,
+		  "Shared Data Cache Line Table "
+		  "(%lu entries)", browser->nr_non_filtered_entries);
+	return 0;
+}
+
+static struct hist_browser*
+perf_c2c_browser__new(struct hists *hists)
+{
+	struct hist_browser *browser = hist_browser__new(hists);
+
+	if (browser) {
+		browser->title = perf_c2c_browser__title;
+		browser->c2c_filter = true;
+	}
+
+	return browser;
+}
+
+static int perf_c2c__hists_browse(struct hists *hists)
+{
+	struct hist_browser *browser;
+	int key = -1;
+
+	browser = perf_c2c_browser__new(hists);
+	if (browser == NULL)
+		return -1;
+
+	/* reset abort key so that it can get Ctrl-C as a key */
+	SLang_reset_tty();
+	SLang_init_tty(0, 0, 0);
+
+	c2c_browser__update_nr_entries(browser);
+
+	while (1) {
+		key = hist_browser__run(browser, "help");
+
+		switch (key) {
+		case 'q':
+			goto out;
+		default:
+			break;
+		}
+	}
+
+out:
+	hist_browser__delete(browser);
+	return 0;
+}
+
+static void perf_c2c_display(void)
+{
+	if (c2c.use_stdio)
+		perf_c2c__hists_fprintf(stdout);
+	else
+		perf_c2c__hists_browse(&c2c.hists.hists);
+}
+#else
+static void perf_c2c_display(void)
+{
+	use_browser = 0;
+	perf_c2c__hists_fprintf(stdout);
+}
+#endif /* HAVE_SLANG_SUPPORT */
+
+static void ui_quirks(void)
+{
+	if (!c2c.use_stdio) {
+		dim_offset.width  = 5;
+		dim_offset.header = header_offset_tui;
+	}
+}
+
 static int perf_c2c__report(int argc, const char **argv)
 {
 	struct perf_session *session;
@@ -1819,6 +1921,9 @@ static int perf_c2c__report(int argc, const char **argv)
 		   "the input file to process"),
 	OPT_INCR('N', "node-info", &c2c.node_info,
 		 "show extra node info in report (repeat for more info)"),
+#ifdef HAVE_SLANG_SUPPORT
+	OPT_BOOLEAN(0, "stdio", &c2c.use_stdio, "Use the stdio interface"),
+#endif
 	OPT_END()
 	};
 	int err = 0;
@@ -1828,6 +1933,13 @@ static int perf_c2c__report(int argc, const char **argv)
 	if (argc)
 		usage_with_options(report_c2c_usage, c2c_options);
 
+	if (c2c.use_stdio)
+		use_browser = 0;
+	else
+		use_browser = 1;
+
+	setup_browser(false);
+
 	if (!input_name || !strlen(input_name))
 		input_name = "perf.data";
 
@@ -1886,8 +1998,9 @@ static int perf_c2c__report(int argc, const char **argv)
 
 	ui_progress__finish();
 
-	use_browser = 0;
-	perf_c2c__hists_fprintf(stdout);
+	ui_quirks();
+
+	perf_c2c_display();
 
 out_session:
 	perf_session__delete(session);
diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
index 4ffff7b..31d6d5a 100644
--- a/tools/perf/ui/browsers/hists.c
+++ b/tools/perf/ui/browsers/hists.c
@@ -30,7 +30,7 @@ static struct rb_node *hists__filter_entries(struct rb_node *nd,
 
 static bool hist_browser__has_filter(struct hist_browser *hb)
 {
-	return hists__has_filter(hb->hists) || hb->min_pcnt || symbol_conf.has_filter;
+	return hists__has_filter(hb->hists) || hb->min_pcnt || symbol_conf.has_filter || hb->c2c_filter;
 }
 
 static int hist_browser__get_folding(struct hist_browser *browser)
diff --git a/tools/perf/ui/browsers/hists.h b/tools/perf/ui/browsers/hists.h
index 39bd0f2..23d6acb 100644
--- a/tools/perf/ui/browsers/hists.h
+++ b/tools/perf/ui/browsers/hists.h
@@ -18,6 +18,7 @@ struct hist_browser {
 	u64		     nr_non_filtered_entries;
 	u64		     nr_hierarchy_entries;
 	u64		     nr_callchain_rows;
+	bool		     c2c_filter;
 
 	/* Get title string. */
 	int                  (*title)(struct hist_browser *browser,

[toc] | [prev] | [next] | [standalone]


#1505350

FromJiri Olsa <jolsa@redhat.com>
Date2016-10-21 02:30 +0200
Message-ID<suvSF-6p0-5@gated-at.bofh.it>
In reply to#1505319
On Thu, Oct 20, 2016 at 06:02:24PM -0500, Kim Phillips wrote:
> On Thu, 20 Oct 2016 12:03:44 -0300
> Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> 
> >   git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-c2c-for-mingo-20161020
> 
> Running this as a normal user may not be the best thing to do, but I'm
> pretty sure the TUI c2c report shouldn't sigsegv:

right, it also helps to have the store event..

we added the 'e' to be able to change events properties (like ldlat,modifiers..)

it wasn't meant to be to specify just single event, because
the c2c report expects both events.. maybe we should limit that
or at least warn

thanks,
jirka

[toc] | [prev] | [next] | [standalone]


#1506397

FromIngo Molnar <mingo@kernel.org>
Date2016-10-22 10:30 +0200
Message-ID<suZQP-YS-5@gated-at.bofh.it>
In reply to#1505012
* Arnaldo Carvalho de Melo <acme@kernel.org> wrote:

> Hi Ingo,
> 
> 	Please consider pulling into tip/perf/core,
> 
> Thanks,
> 
> - Arnaldo
> 
> The following changes since commit 10b37cb59fa1e61fec1386f324615e0e8202cd87:
> 
>   Merge tag 'perf-vendor_events-for-mingo-20161018' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core (2016-10-19 15:22:26 +0200)
> 
> are available in the git repository at:
> 
>   git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git tags/perf-c2c-for-mingo-20161020
> 
> for you to fetch changes up to 535bbde62701b2bb298063e9dfa007e8a1ff95d1:
> 
>   perf c2c report: Add --show-all option (2016-10-19 13:18:31 -0300)
> 
> ----------------------------------------------------------------
> - The 'perf c2c' tool provides means for Shared Data C2C/HITM analysis.
> 
>   It allows you to track down cacheline contention. The tool is based
>   on x86's load latency and precise store facility events provided by
>   Intel CPUs.
> 
>   It was tested by Joe Mario and has proven to be useful, finding some
>   cacheline contentions. Joe also wrote a blog about c2c tool with
>   examples:
> 
>     https://joemario.github.io/blog/2016/09/01/c2c-blog/
> 
>   Excerpt of the content on this site:
> 
>   ---
>     At a high level, “perf c2c” will show you:
> 
>     * The cachelines where false sharing was detected.
>     * The readers and writers to those cachelines, and the offsets where those accesses occurred.
>     * The pid, tid, instruction addr, function name, binary object name for those readers and writers.
>     * The source file and line number for each reader and writer.
>     * The average load latency for the loads to those cachelines.
>     * Which numa nodes the samples a cacheline came from and which CPUs were involved.
> 
>     Using perf c2c is similar to using the Linux perf tool today.
>     First collect data with “perf c2c record” Then generate a report output with “perf c2c report”
>   ---
> 
>   There one finds extensive details on using the tool, with tips on
>   reducing the volume of samples while still capturing enough to do
>   its job. (Dick Fowles, Joe Mario, Don Zickus, Jiri Olsa)
> 
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
> 
> ----------------------------------------------------------------
> Jiri Olsa (52):
>       perf c2c: Introduce c2c_decode_stats function
>       perf c2c: Introduce c2c_add_stats function
>       perf c2c: Add c2c command
>       perf c2c: Add record subcommand
>       perf c2c: Add report subcommand
>       perf c2c report: Add dimension support
>       perf c2c report: Add sort_entry dimension support
>       perf c2c report: Fallback to standard dimensions
>       perf c2c report: Add sample processing
>       perf c2c report: Add cacheline hists processing
>       perf c2c report: Decode c2c_stats for hist entries
>       perf c2c report: Add header macros
>       perf c2c report: Add 'dcacheline' dimension key
>       perf c2c report: Add 'offset' dimension key
>       perf c2c report: Add 'iaddr' dimension key
>       perf c2c report: Add hitm related dimension keys
>       perf c2c report: Add stores related dimension keys
>       perf c2c report: Add loads related dimension keys
>       perf c2c report: Add llc and remote loads related dimension keys
>       perf c2c report: Add llc load miss dimension key
>       perf c2c report: Add total record sort key
>       perf c2c report: Add total loads sort key
>       perf c2c report: Add hitm percent sort key
>       perf c2c report: Add hitm/store percent related sort keys
>       perf c2c report: Add dram related sort keys
>       perf c2c report: Add 'pid' sort key
>       perf c2c report: Add 'tid' sort key
>       perf c2c report: Add 'symbol' and 'dso' sort keys
>       perf c2c report: Add 'node' sort key
>       perf c2c report: Add stats related sort keys
>       perf c2c report: Add 'cpucnt' sort key
>       perf c2c report: Add src line sort key
>       perf c2c report: Setup number of header lines for hists
>       perf c2c report: Set final resort fields
>       perf c2c report: Add stdio output support
>       perf c2c report: Add main TUI browser
>       perf c2c report: Add TUI cacheline browser
>       perf c2c report: Add global stats stdio output
>       perf c2c report: Add shared cachelines stats stdio output
>       perf c2c report: Add c2c related stats stdio output
>       perf c2c report: Allow to report callchains
>       perf c2c report: Limit the cachelines table entries
>       perf c2c report: Add support to choose local HITMs
>       perf c2c report: Allow to set cacheline sort fields
>       perf c2c report: Recalc width of global sort entries
>       perf c2c report: Add cacheline index entry
>       perf c2c report: Add support to manage symbol name length
>       perf c2c report: Iterate node display in browser
>       perf c2c report: Add help windows
>       perf c2c: Add man page and credits
>       perf c2c report: Add --no-source option
>       perf c2c report: Add --show-all option
> 
>  tools/perf/Build                      |    1 +
>  tools/perf/Documentation/perf-c2c.txt |  282 ++++
>  tools/perf/builtin-c2c.c              | 2754 +++++++++++++++++++++++++++++++++
>  tools/perf/builtin.h                  |    1 +
>  tools/perf/perf.c                     |    1 +
>  tools/perf/ui/browsers/hists.c        |    2 +-
>  tools/perf/ui/browsers/hists.h        |    1 +
>  tools/perf/util/hist.c                |    1 +
>  tools/perf/util/hist.h                |    1 +
>  tools/perf/util/mem-events.c          |  128 ++
>  tools/perf/util/mem-events.h          |   37 +
>  tools/perf/util/sort.c                |    2 +-
>  tools/perf/util/sort.h                |    1 +
>  13 files changed, 3210 insertions(+), 2 deletions(-)
>  create mode 100644 tools/perf/Documentation/perf-c2c.txt
>  create mode 100644 tools/perf/builtin-c2c.c

Pulled the perf-c2c-for-mingo-20161021 tag, thanks a lot Arnaldo!

I can see some teething problems. For example if I run it on an older kernel (v4.4 
distro kernel), I get this:

 triton:~/tip> perf c2c record perf bench sched pipe
 # Running 'sched/pipe' benchmark:
 # Executed 1000000 pipe operations between two processes

     Total time: 12.001 [sec]

      12.001919 usecs/op
          83320 ops/sec
 [ perf record: Woken up 18 times to write data ]
 [ perf record: Captured and wrote 5.356 MB perf.data (69804 samples) ]

but there's no 'perf c2c report' TUI output at all:

 Shared Data Cache Line Table     (0 entries, sorted on remote HITMs)                                                                                                                  
                              Total      Rmt  ----- LLC Load Hitm -----  ---- Store Reference ----  --- Load Dram ----      LLC    Total  ----- Core Load Hit -----  -- LLC Load Hit -
 Index           Cacheline  records     Hitm    Total      Lcl      Rmt    Total    L1Hit   L1Miss       Lcl       Rmt  Ld Miss    Loads       FB       L1       L2       Llc       Rm
                                                                                                                                                                                     
and just an empty screen.

If I do 'perf report' I get two events:

 Available samples
 24K cpu/mem-loads,ldlat=30/P
 45K cpu/mem-stores/P

and both have some real data.

What am I missing?

	Ingo

[toc] | [prev] | [next] | [standalone]


#1506673

FromJiri Olsa <jolsa@redhat.com>
Date2016-10-23 13:10 +0200
Message-ID<svoP7-9x-11@gated-at.bofh.it>
In reply to#1506397
On Sat, Oct 22, 2016 at 10:28:06AM +0200, Ingo Molnar wrote:

SNIP

> >  tools/perf/ui/browsers/hists.h        |    1 +
> >  tools/perf/util/hist.c                |    1 +
> >  tools/perf/util/hist.h                |    1 +
> >  tools/perf/util/mem-events.c          |  128 ++
> >  tools/perf/util/mem-events.h          |   37 +
> >  tools/perf/util/sort.c                |    2 +-
> >  tools/perf/util/sort.h                |    1 +
> >  13 files changed, 3210 insertions(+), 2 deletions(-)
> >  create mode 100644 tools/perf/Documentation/perf-c2c.txt
> >  create mode 100644 tools/perf/builtin-c2c.c
> 
> Pulled the perf-c2c-for-mingo-20161021 tag, thanks a lot Arnaldo!
> 
> I can see some teething problems. For example if I run it on an older kernel (v4.4 
> distro kernel), I get this:
> 
>  triton:~/tip> perf c2c record perf bench sched pipe
>  # Running 'sched/pipe' benchmark:
>  # Executed 1000000 pipe operations between two processes
> 
>      Total time: 12.001 [sec]
> 
>       12.001919 usecs/op
>           83320 ops/sec
>  [ perf record: Woken up 18 times to write data ]
>  [ perf record: Captured and wrote 5.356 MB perf.data (69804 samples) ]
> 
> but there's no 'perf c2c report' TUI output at all:
> 
>  Shared Data Cache Line Table     (0 entries, sorted on remote HITMs)                                                                                                                  
>                               Total      Rmt  ----- LLC Load Hitm -----  ---- Store Reference ----  --- Load Dram ----      LLC    Total  ----- Core Load Hit -----  -- LLC Load Hit -
>  Index           Cacheline  records     Hitm    Total      Lcl      Rmt    Total    L1Hit   L1Miss       Lcl       Rmt  Ld Miss    Loads       FB       L1       L2       Llc       Rm
>                                                                                                                                                                                      
> and just an empty screen.
> 
> If I do 'perf report' I get two events:
> 
>  Available samples
>  24K cpu/mem-loads,ldlat=30/P
>  45K cpu/mem-stores/P
> 
> and both have some real data.
> 
> What am I missing?

hm, most likely you did not generate any remote HITMs.. if it was on the laptop?
you might get some results for local HITMs with -d option:

  $ perf c2c report -d lcl

the default display/filter is for Remote HITMs.. perhaps we could be
smart enough and switch to local when we found no data for remote

jirka

[toc] | [prev] | [next] | [standalone]


#1506796

FromAndi Kleen <andi@firstfloor.org>
Date2016-10-24 01:50 +0200
Message-ID<svAGC-81J-29@gated-at.bofh.it>
In reply to#1506673
> hm, most likely you did not generate any remote HITMs.. if it was on the laptop?
> you might get some results for local HITMs with -d option:
> 
>   $ perf c2c report -d lcl
> 
> the default display/filter is for Remote HITMs.. perhaps we could be
> smart enough and switch to local when we found no data for remote

It would be better to default to local + remote. Even local HITMs can be
a big problem, especially on server chips with many cores.

-Andi

[toc] | [prev] | [next] | [standalone]


#1506934

FromJiri Olsa <jolsa@redhat.com>
Date2016-10-24 08:40 +0200
Message-ID<svH5o-3Tr-17@gated-at.bofh.it>
In reply to#1506796
On Sun, Oct 23, 2016 at 04:47:19PM -0700, Andi Kleen wrote:
> > hm, most likely you did not generate any remote HITMs.. if it was on the laptop?
> > you might get some results for local HITMs with -d option:
> > 
> >   $ perf c2c report -d lcl
> > 
> > the default display/filter is for Remote HITMs.. perhaps we could be
> > smart enough and switch to local when we found no data for remote
> 
> It would be better to default to local + remote. Even local HITMs can be
> a big problem, especially on server chips with many cores.

ok, will check on this, thanks

jirka

[toc] | [prev] | [next] | [standalone]


#1507032

FromIngo Molnar <mingo@kernel.org>
Date2016-10-24 11:30 +0200
Message-ID<svJJU-5DE-25@gated-at.bofh.it>
In reply to#1506673
* Jiri Olsa <jolsa@redhat.com> wrote:

> > If I do 'perf report' I get two events:
> > 
> >  Available samples
> >  24K cpu/mem-loads,ldlat=30/P
> >  45K cpu/mem-stores/P
> > 
> > and both have some real data.
> > 
> > What am I missing?
> 
> hm, most likely you did not generate any remote HITMs.. if it was on the laptop?

Yeah.

> you might get some results for local HITMs with -d option:
> 
>   $ perf c2c report -d lcl
> 
> the default display/filter is for Remote HITMs.. perhaps we could be
> smart enough and switch to local when we found no data for remote

Yeah, this did the trick.

Could we please make sure there's always actionable output by the tool? I.e. it 
should either clearly refuse to work (due to lack of hw), or it should produce 
something meaningful.

Thanks,

	Ingo

[toc] | [prev] | [next] | [standalone]


#1507042

FromJiri Olsa <jolsa@redhat.com>
Date2016-10-24 11:50 +0200
Message-ID<svK3f-5Kp-13@gated-at.bofh.it>
In reply to#1507032
On Mon, Oct 24, 2016 at 11:23:28AM +0200, Ingo Molnar wrote:
> 
> * Jiri Olsa <jolsa@redhat.com> wrote:
> 
> > > If I do 'perf report' I get two events:
> > > 
> > >  Available samples
> > >  24K cpu/mem-loads,ldlat=30/P
> > >  45K cpu/mem-stores/P
> > > 
> > > and both have some real data.
> > > 
> > > What am I missing?
> > 
> > hm, most likely you did not generate any remote HITMs.. if it was on the laptop?
> 
> Yeah.
> 
> > you might get some results for local HITMs with -d option:
> > 
> >   $ perf c2c report -d lcl
> > 
> > the default display/filter is for Remote HITMs.. perhaps we could be
> > smart enough and switch to local when we found no data for remote
> 
> Yeah, this did the trick.
> 
> Could we please make sure there's always actionable output by the tool? I.e. it 
> should either clearly refuse to work (due to lack of hw), or it should produce 
> something meaningful.

ok, will do

thanks,
jirka

[toc] | [prev] | [standalone]


Page 2 of 2 — ← Prev page 1 [2]

Back to top | Article view | linux.kernel


csiph-web