Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Stephane Eranian
On Thu, Sep 3, 2015 at 1:42 PM, Arnaldo Carvalho de Melo wrote: > Em Thu, Sep 03, 2015 at 10:12:12AM -0700, Stephane Eranian escreveu: >> On Thu, Sep 3, 2015 at 9:53 AM, Arnaldo Carvalho de Melo >> wrote: >> > Em Thu, Sep 03, 2015 at 02:25:44PM +0200, Jiri Olsa escreveu: >> >> On Thu, Sep 03,

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Arnaldo Carvalho de Melo
Em Thu, Sep 03, 2015 at 10:12:12AM -0700, Stephane Eranian escreveu: > On Thu, Sep 3, 2015 at 9:53 AM, Arnaldo Carvalho de Melo > wrote: > > Em Thu, Sep 03, 2015 at 02:25:44PM +0200, Jiri Olsa escreveu: > >> On Thu, Sep 03, 2015 at 05:16:41AM -0700, Stephane Eranian wrote: > >> > On Thu, Sep 3,

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Stephane Eranian
On Thu, Sep 3, 2015 at 9:53 AM, Arnaldo Carvalho de Melo wrote: > Em Thu, Sep 03, 2015 at 02:25:44PM +0200, Jiri Olsa escreveu: >> On Thu, Sep 03, 2015 at 05:16:41AM -0700, Stephane Eranian wrote: >> > On Thu, Sep 3, 2015 at 5:13 AM, Jiri Olsa wrote: >> > > yes, but for 'count' not 'aggr' > >> >

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Arnaldo Carvalho de Melo
Em Thu, Sep 03, 2015 at 02:25:44PM +0200, Jiri Olsa escreveu: > On Thu, Sep 03, 2015 at 05:16:41AM -0700, Stephane Eranian wrote: > > On Thu, Sep 3, 2015 at 5:13 AM, Jiri Olsa wrote: > > > yes, but for 'count' not 'aggr' > > Ah, yes, sorry, has to be count and not aggr. Sent the wrong version. >

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Jiri Olsa
On Thu, Sep 03, 2015 at 05:16:41AM -0700, Stephane Eranian wrote: > On Thu, Sep 3, 2015 at 5:13 AM, Jiri Olsa 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 wrote: > >> > On Thu, Sep 03, 2015 at 04:48:52AM -0700,

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Stephane Eranian
On Thu, Sep 3, 2015 at 5:13 AM, Jiri Olsa 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 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 wrote:

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Jiri Olsa
On Thu, Sep 03, 2015 at 05:05:32AM -0700, Stephane Eranian wrote: > On Thu, Sep 3, 2015 at 5:01 AM, Jiri Olsa 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 wrote: > >> > On Wed, Sep 02, 2015 at 03:17:51PM +0200,

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Stephane Eranian
On Thu, Sep 3, 2015 at 5:01 AM, Jiri Olsa 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 wrote: >> > On Wed, Sep 02, 2015 at 03:17:51PM +0200, Stephane Eranian wrote: >> > >> > SNIP >> > >> >> + /* >> >> + * we do

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Jiri Olsa
On Thu, Sep 03, 2015 at 04:48:52AM -0700, Stephane Eranian wrote: > On Thu, Sep 3, 2015 at 3:01 AM, Jiri Olsa 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 > >> +

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Stephane Eranian
On Thu, Sep 3, 2015 at 3:01 AM, Jiri Olsa 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

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Jiri Olsa
On Wed, Sep 02, 2015 at 01:26:57PM -0700, Andi Kleen wrote: > On Wed, Sep 02, 2015 at 03:17:51PM +0200, Stephane Eranian wrote: > > Per-pkg events need to be captured once per processor > > socket. The code in check_per_pkg() ensures only one > > value per processor package is used. However there

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Jiri Olsa
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 > + *

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Stephane Eranian
On Thu, Sep 3, 2015 at 9:53 AM, Arnaldo Carvalho de Melo wrote: > Em Thu, Sep 03, 2015 at 02:25:44PM +0200, Jiri Olsa escreveu: >> On Thu, Sep 03, 2015 at 05:16:41AM -0700, Stephane Eranian wrote: >> > On Thu, Sep 3, 2015 at 5:13 AM, Jiri Olsa wrote: >> > >

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Arnaldo Carvalho de Melo
Em Thu, Sep 03, 2015 at 02:25:44PM +0200, Jiri Olsa escreveu: > On Thu, Sep 03, 2015 at 05:16:41AM -0700, Stephane Eranian wrote: > > On Thu, Sep 3, 2015 at 5:13 AM, Jiri Olsa wrote: > > > yes, but for 'count' not 'aggr' > > Ah, yes, sorry, has to be count and not aggr. Sent

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Arnaldo Carvalho de Melo
Em Thu, Sep 03, 2015 at 10:12:12AM -0700, Stephane Eranian escreveu: > On Thu, Sep 3, 2015 at 9:53 AM, Arnaldo Carvalho de Melo > wrote: > > Em Thu, Sep 03, 2015 at 02:25:44PM +0200, Jiri Olsa escreveu: > >> On Thu, Sep 03, 2015 at 05:16:41AM -0700, Stephane Eranian wrote: > >> >

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Stephane Eranian
On Thu, Sep 3, 2015 at 1:42 PM, Arnaldo Carvalho de Melo wrote: > Em Thu, Sep 03, 2015 at 10:12:12AM -0700, Stephane Eranian escreveu: >> On Thu, Sep 3, 2015 at 9:53 AM, Arnaldo Carvalho de Melo >> wrote: >> > Em Thu, Sep 03, 2015 at 02:25:44PM +0200, Jiri Olsa

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Jiri Olsa
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 > + *

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Jiri Olsa
On Wed, Sep 02, 2015 at 01:26:57PM -0700, Andi Kleen wrote: > On Wed, Sep 02, 2015 at 03:17:51PM +0200, Stephane Eranian wrote: > > Per-pkg events need to be captured once per processor > > socket. The code in check_per_pkg() ensures only one > > value per processor package is used. However there

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Jiri Olsa
On Thu, Sep 03, 2015 at 04:48:52AM -0700, Stephane Eranian wrote: > On Thu, Sep 3, 2015 at 3:01 AM, Jiri Olsa 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

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Jiri Olsa
On Thu, Sep 03, 2015 at 05:16:41AM -0700, Stephane Eranian wrote: > On Thu, Sep 3, 2015 at 5:13 AM, Jiri Olsa 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 wrote: > >> > On Thu, Sep

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Stephane Eranian
On Thu, Sep 3, 2015 at 5:01 AM, Jiri Olsa 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 wrote: >> > On Wed, Sep 02, 2015 at 03:17:51PM +0200, Stephane Eranian wrote: >> > >> > SNIP >> >

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Jiri Olsa
On Thu, Sep 03, 2015 at 05:05:32AM -0700, Stephane Eranian wrote: > On Thu, Sep 3, 2015 at 5:01 AM, Jiri Olsa 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 wrote: > >> > On Wed, Sep

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Stephane Eranian
On Thu, Sep 3, 2015 at 3:01 AM, Jiri Olsa 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 >> +

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-03 Thread Stephane Eranian
On Thu, Sep 3, 2015 at 5:13 AM, Jiri Olsa 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 wrote: >> > On Thu, Sep 03, 2015 at 04:48:52AM -0700, Stephane Eranian wrote: >> >> On Thu, Sep 3,

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-02 Thread Andi Kleen
On Wed, Sep 02, 2015 at 03:17:51PM +0200, Stephane Eranian wrote: > Per-pkg events need to be captured once per processor > socket. The code in check_per_pkg() ensures only one > value per processor package is used. However there is > a problem with this function in case the first CPU of > the

[PATCH] perf stat: fix per-pkg event reporting bug

2015-09-02 Thread Stephane Eranian
Per-pkg events need to be captured once per processor socket. The code in check_per_pkg() ensures only one value per processor package is used. However there is a problem with this function in case the first CPU of the package does not measure anything for the per-pkg event, but other CPUs do.

Re: [PATCH] perf stat: fix per-pkg event reporting bug

2015-09-02 Thread Andi Kleen
On Wed, Sep 02, 2015 at 03:17:51PM +0200, Stephane Eranian wrote: > Per-pkg events need to be captured once per processor > socket. The code in check_per_pkg() ensures only one > value per processor package is used. However there is > a problem with this function in case the first CPU of > the

[PATCH] perf stat: fix per-pkg event reporting bug

2015-09-02 Thread Stephane Eranian
Per-pkg events need to be captured once per processor socket. The code in check_per_pkg() ensures only one value per processor package is used. However there is a problem with this function in case the first CPU of the package does not measure anything for the per-pkg event, but other CPUs do.