OSDN Git Service

perf vendor events amd: Restrict model detection for zen1 based processors
authorVijay Thakkar <vijaythakkar@me.com>
Wed, 18 Mar 2020 19:00:00 +0000 (15:00 -0400)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 24 Mar 2020 13:35:53 +0000 (10:35 -0300)
This patch changes the previous blanket detection of AMD Family 17h
processors to be more specific to Zen1 core based products only by
replacing model detection regex pattern [[:xdigit:]]+ with
([12][0-9A-F]|[0-9A-F]), restricting to models 0 though 2f only.

This change is required to allow for the addition of separate PMU events
for Zen2 core based models in the following patches as those belong to
family 17h but have different PMCs. Current PMU events directory has
also been renamed to "amdzen1" from "amdfam17h" to reflect this
specificity.

Note that although this change does not break PMU counters for existing
zen1 based systems, it does disable the current set of counters for zen2
based systems. Counters for zen2 have been added in the following
patches in this patchset.

Signed-off-by: Vijay Thakkar <vijaythakkar@me.com>
Acked-by: Kim Phillips <kim.phillips@amd.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Jon Grimm <jon.grimm@amd.com>
Cc: Martin Liška <mliska@suse.cz>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lore.kernel.org/lkml/20200318190002.307290-2-vijaythakkar@me.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/pmu-events/arch/x86/amdzen1/branch.json [moved from tools/perf/pmu-events/arch/x86/amdfam17h/branch.json with 100% similarity]
tools/perf/pmu-events/arch/x86/amdzen1/cache.json [moved from tools/perf/pmu-events/arch/x86/amdfam17h/cache.json with 100% similarity]
tools/perf/pmu-events/arch/x86/amdzen1/core.json [moved from tools/perf/pmu-events/arch/x86/amdfam17h/core.json with 100% similarity]
tools/perf/pmu-events/arch/x86/amdzen1/floating-point.json [moved from tools/perf/pmu-events/arch/x86/amdfam17h/floating-point.json with 100% similarity]
tools/perf/pmu-events/arch/x86/amdzen1/memory.json [moved from tools/perf/pmu-events/arch/x86/amdfam17h/memory.json with 100% similarity]
tools/perf/pmu-events/arch/x86/amdzen1/other.json [moved from tools/perf/pmu-events/arch/x86/amdfam17h/other.json with 100% similarity]
tools/perf/pmu-events/arch/x86/mapfile.csv

index 745ced0..82a9db0 100644 (file)
@@ -36,4 +36,4 @@ GenuineIntel-6-55-[56789ABCDEF],v1,cascadelakex,core
 GenuineIntel-6-7D,v1,icelake,core
 GenuineIntel-6-7E,v1,icelake,core
 GenuineIntel-6-86,v1,tremontx,core
-AuthenticAMD-23-[[:xdigit:]]+,v1,amdfam17h,core
+AuthenticAMD-23-([12][0-9A-F]|[0-9A-F]),v1,amdzen1,core