Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1218220
| From | Jiri Olsa <jolsa@redhat.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] perf stat: fix per-pkg event reporting bug |
| Date | 2015-09-03 14:30 +0200 |
| Message-ID | <q4BOq-3tf-27@gated-at.bofh.it> (permalink) |
| References | (2 earlier) <q4BbI-2uW-7@gated-at.bofh.it> <q4Bv3-36H-5@gated-at.bofh.it> <q4Bv3-36H-7@gated-at.bofh.it> <q4BEL-3hX-31@gated-at.bofh.it> <q4BEL-3hX-41@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Thu, Sep 03, 2015 at 05:16:41AM -0700, Stephane Eranian wrote:
> On Thu, Sep 3, 2015 at 5:13 AM, Jiri Olsa <jolsa@redhat.com> wrote:
> > On Thu, Sep 03, 2015 at 05:05:32AM -0700, Stephane Eranian wrote:
> >> On Thu, Sep 3, 2015 at 5:01 AM, Jiri Olsa <jolsa@redhat.com> wrote:
> >> > On Thu, Sep 03, 2015 at 04:48:52AM -0700, Stephane Eranian wrote:
> >> >> On Thu, Sep 3, 2015 at 3:01 AM, Jiri Olsa <jolsa@redhat.com> wrote:
> >> >> > On Wed, Sep 02, 2015 at 03:17:51PM +0200, Stephane Eranian wrote:
> >> >> >
> >> >> > SNIP
> >> >> >
> >> >> >> + /*
> >> >> >> + * we do not consider an event that has not run as a good
> >> >> >> + * instance to mark a package as used (skip=1). Otherwise
> >> >> >> + * we may run into a situation where the first CPU in a package
> >> >> >> + * is not running anything, yet the second is, and this function
> >> >> >> + * would mark the package as used after the first CPU and would
> >> >> >> + * not read the values from the second CPU.
> >> >> >> + */
> >> >> >> + if (!(vals->run && vals->ena))
> >> >> >> + return 0;
> >> >> >> +
> >> >> >> s = cpu_map__get_socket(cpus, cpu);
> >> >> >> if (s < 0)
> >> >> >> return -1;
> >> >> >> @@ -235,7 +247,7 @@ process_counter_values(struct perf_stat_config *config, struct perf_evsel *evsel
> >> >> >> static struct perf_counts_values zero;
> >> >> >> bool skip = false;
> >> >> >>
> >> >> >> - if (check_per_pkg(evsel, cpu, &skip)) {
> >> >> >> + if (check_per_pkg(evsel, aggr, cpu, &skip)) {
> >> >> >
> >> >> > should we pass 'count' instead o 'aggr' ?
> >> >> >
> >> >> the reason I passed counts_values is in case this function needs to be
> >> >> called from other places which do
> >> >> not use aggr mode.
> >> >
> >> > sure, but 'aggr' is being computed within process_counter_values
> >> >
> >> > process_counter_values gets 'count' argument with values read
> >> > for given cpu/thread for further processing, and it seems to
> >> > me that 'count' values should be passed to check_per_pkg
> >> >
> >> You do not want to aggregate values, you want to look at the individual events
> >> for each CPU because you need to look at their run/ena fields.
> >
> > yes, but for 'count' not 'aggr'
> >
> Ah, yes, sorry, has to be count and not aggr. Sent the wrong version.
> Can you fix it? Or do you want me to resubmit?
well, Arnaldo will queue it.. leaving up to him ;-)
jirka
--
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/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH] perf stat: fix per-pkg event reporting bug Stephane Eranian <eranian@google.com> - 2015-09-02 15:20 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Andi Kleen <ak@linux.intel.com> - 2015-09-02 22:30 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Jiri Olsa <jolsa@redhat.com> - 2015-09-03 12:10 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Jiri Olsa <jolsa@redhat.com> - 2015-09-03 12:10 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Stephane Eranian <eranian@google.com> - 2015-09-03 13:50 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Jiri Olsa <jolsa@redhat.com> - 2015-09-03 14:10 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Stephane Eranian <eranian@google.com> - 2015-09-03 14:10 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Jiri Olsa <jolsa@redhat.com> - 2015-09-03 14:20 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Stephane Eranian <eranian@google.com> - 2015-09-03 14:20 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Jiri Olsa <jolsa@redhat.com> - 2015-09-03 14:30 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Arnaldo Carvalho de Melo <acme@redhat.com> - 2015-09-03 19:00 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Stephane Eranian <eranian@google.com> - 2015-09-03 19:20 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Arnaldo Carvalho de Melo <acme@redhat.com> - 2015-09-03 22:50 +0200
Re: [PATCH] perf stat: fix per-pkg event reporting bug Stephane Eranian <eranian@google.com> - 2015-09-03 23:40 +0200
csiph-web