Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-21 Thread Arnaldo Carvalho de Melo
Em Thu, Nov 15, 2018 at 04:01:46PM -0500, Liang, Kan escreveu: > > > On 11/15/2018 3:44 PM, Jiri Olsa wrote: > > On Wed, Nov 14, 2018 at 01:24:15PM -0800, kan.li...@linux.intel.com wrote: > > > From: Kan Liang > > > > > > Perf tools cannot find the proper event list for Cascadelake server. > >

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-20 Thread Liang, Kan
On 11/15/2018 9:14 PM, Arnaldo Carvalho de Melo wrote: Em Thu, Nov 15, 2018 at 04:01:46PM -0500, Liang, Kan escreveu: On 11/15/2018 3:44 PM, Jiri Olsa wrote: On Wed, Nov 14, 2018 at 01:24:15PM -0800, kan.li...@linux.intel.com wrote: From: Kan Liang Perf tools cannot find the proper even

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-15 Thread Arnaldo Carvalho de Melo
Em Thu, Nov 15, 2018 at 04:01:46PM -0500, Liang, Kan escreveu: > > > On 11/15/2018 3:44 PM, Jiri Olsa wrote: > > On Wed, Nov 14, 2018 at 01:24:15PM -0800, kan.li...@linux.intel.com wrote: > > > From: Kan Liang > > > > > > Perf tools cannot find the proper event list for Cascadelake server. > >

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-15 Thread Liang, Kan
On 11/15/2018 3:44 PM, Jiri Olsa wrote: On Wed, Nov 14, 2018 at 01:24:15PM -0800, kan.li...@linux.intel.com wrote: From: Kan Liang Perf tools cannot find the proper event list for Cascadelake server. Because Cascadelake server and Skylake server have the same CPU model number, which are use

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-15 Thread Jiri Olsa
On Wed, Nov 14, 2018 at 01:24:15PM -0800, kan.li...@linux.intel.com wrote: > From: Kan Liang > > Perf tools cannot find the proper event list for Cascadelake server. > Because Cascadelake server and Skylake server have the same CPU model > number, which are used by perf tools to find the event li

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-15 Thread Jiri Olsa
On Thu, Nov 15, 2018 at 10:53:42AM -0500, Liang, Kan wrote: > > > > > > + /* > > > > > + * Full CPUID format is required to identify a platform. > > > > > + * Error out if the cpuid string is incomplete. > > > > > + */ > > > > > + if (full_mapcpuid && !full_cpuid) { > > > >

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-15 Thread Liang, Kan
+ /* +* Full CPUID format is required to identify a platform. +* Error out if the cpuid string is incomplete. +*/ + if (full_mapcpuid && !full_cpuid) { + pr_info("Invalid CPUID %s. Full CPUID is required, " + "vendor-family

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-15 Thread Jiri Olsa
On Thu, Nov 15, 2018 at 10:18:27AM -0500, Liang, Kan wrote: SNIP > > > > +int strcmp_cpuid_str(const char *mapcpuid, const char *cpuid) > > > > +{ > > > > +    regex_t re; > > > > +    regmatch_t pmatch[1]; > > > > +    int match; > > > > +    bool full_mapcpuid = is_full_cpuid(mapcpuid); > > > >

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-15 Thread Jiri Olsa
On Thu, Nov 15, 2018 at 09:26:50AM -0500, Liang, Kan wrote: > > > On 11/15/2018 8:53 AM, Jiri Olsa wrote: > > On Wed, Nov 14, 2018 at 01:24:15PM -0800, kan.li...@linux.intel.com wrote: > > > > SNIP > > > > > diff --git a/tools/perf/arch/x86/util/header.c > > > b/tools/perf/arch/x86/util/header

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-15 Thread Liang, Kan
On 11/15/2018 9:26 AM, Liang, Kan wrote: On 11/15/2018 8:53 AM, Jiri Olsa wrote: On Wed, Nov 14, 2018 at 01:24:15PM -0800, kan.li...@linux.intel.com wrote: SNIP diff --git a/tools/perf/arch/x86/util/header.c b/tools/perf/arch/x86/util/header.c index fb0d71afee8b..b428a4b00bf7 100644 --

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-15 Thread Liang, Kan
On 11/15/2018 8:53 AM, Jiri Olsa wrote: On Wed, Nov 14, 2018 at 01:24:15PM -0800, kan.li...@linux.intel.com wrote: SNIP diff --git a/tools/perf/arch/x86/util/header.c b/tools/perf/arch/x86/util/header.c index fb0d71afee8b..b428a4b00bf7 100644 --- a/tools/perf/arch/x86/util/header.c +++ b/t

Re: [PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-15 Thread Jiri Olsa
On Wed, Nov 14, 2018 at 01:24:15PM -0800, kan.li...@linux.intel.com wrote: SNIP > diff --git a/tools/perf/arch/x86/util/header.c > b/tools/perf/arch/x86/util/header.c > index fb0d71afee8b..b428a4b00bf7 100644 > --- a/tools/perf/arch/x86/util/header.c > +++ b/tools/perf/arch/x86/util/header.c > @

[PATCH 1/2] perf vendor events: Add stepping in CPUID string for x86

2018-11-14 Thread kan . liang
From: Kan Liang Perf tools cannot find the proper event list for Cascadelake server. Because Cascadelake server and Skylake server have the same CPU model number, which are used by perf tools to find the event list. The stepping for Skylake server is up to 4. The stepping for Cascadelake server