diff -Nru libpfm4-4.11.1+git4-gfa84c27/debian/changelog libpfm4-4.11.1+git8-gc96ebc0/debian/changelog --- libpfm4-4.11.1+git4-gfa84c27/debian/changelog 2020-11-06 22:27:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/debian/changelog 2021-01-07 15:07:20.000000000 +0000 @@ -1,3 +1,11 @@ +libpfm4 (4.11.1+git8-gc96ebc0-1) unstable; urgency=medium + + * New upstream GIT snapshot. + * Bump watch version to 4. No changes needed. + * Bump Standards-Version to 4.5.1. No changes needed. + + -- Andreas Beckmann Thu, 07 Jan 2021 16:07:20 +0100 + libpfm4 (4.11.1+git4-gfa84c27-1) unstable; urgency=medium * New upstream GIT snapshot. diff -Nru libpfm4-4.11.1+git4-gfa84c27/debian/control libpfm4-4.11.1+git8-gc96ebc0/debian/control --- libpfm4-4.11.1+git4-gfa84c27/debian/control 2020-11-06 22:27:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/debian/control 2021-01-07 15:07:20.000000000 +0000 @@ -10,7 +10,7 @@ libncurses-dev, swig, Rules-Requires-Root: no -Standards-Version: 4.5.0 +Standards-Version: 4.5.1 Homepage: http://perfmon2.sourceforge.net/ Vcs-Browser: https://salsa.debian.org/hpc-team/libpfm4 Vcs-Git: https://salsa.debian.org/hpc-team/libpfm4.git diff -Nru libpfm4-4.11.1+git4-gfa84c27/debian/copyright libpfm4-4.11.1+git8-gc96ebc0/debian/copyright --- libpfm4-4.11.1+git4-gfa84c27/debian/copyright 2020-11-06 22:27:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/debian/copyright 2021-01-07 15:07:20.000000000 +0000 @@ -35,13 +35,15 @@ 2012 Maynard Johnson 2013 Michael Werner 2015 Noor + 2020 Ondrej Sykora 2016 Peinan Zhang - 2011-2016 Phil Mucci + 2011-2019 Phil Mucci 2010 Robert Richter - 2009-2018 Stephane Eranian - 2010-2017 Steve Kaufmann + 2019 Shay Gal-On + 2009-2020 Stephane Eranian + 2010-2020 Steve Kaufmann 2018 Steve Walk - 2017 Thomas Richter + 2017-2020 Thomas Richter 2018 Tomáš Chvátal 2015 Tony Jones 2009-2017 Vince Weaver @@ -54,7 +56,7 @@ 2010-2011 Arun Sharma 2011-2012 Stephane Eranian 2013 Vincent Danjean - 2013-2019 Andreas Beckmann + 2013-2021 Andreas Beckmann License: BSD-like License: BSD-like diff -Nru libpfm4-4.11.1+git4-gfa84c27/debian/watch libpfm4-4.11.1+git8-gc96ebc0/debian/watch --- libpfm4-4.11.1+git4-gfa84c27/debian/watch 2020-11-06 22:27:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/debian/watch 2021-01-07 15:07:20.000000000 +0000 @@ -1,3 +1,3 @@ -version=3 +version=4 http://sf.net/perfmon2/libpfm-(4\..*)\.tar\.gz diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/events/intel_icl_events.h libpfm4-4.11.1+git8-gc96ebc0/lib/events/intel_icl_events.h --- libpfm4-4.11.1+git4-gfa84c27/lib/events/intel_icl_events.h 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/events/intel_icl_events.h 2020-12-10 03:49:59.000000000 +0000 @@ -533,45 +533,10 @@ }; static const intel_x86_umask_t intel_icl_mem_trans_retired[]={ - { .uname = "LOAD_LATENCY_GT_512", - .udesc = "Counts randomly selected loads when the latency from first dispatch to completion is greater than 512 cycles.", - .ucode = 0x20000ull, - .uflags = INTEL_X86_NCOMBO | INTEL_X86_PEBS, - }, - { .uname = "LOAD_LATENCY_GT_256", - .udesc = "Counts randomly selected loads when the latency from first dispatch to completion is greater than 256 cycles.", - .ucode = 0x10000ull, - .uflags = INTEL_X86_NCOMBO | INTEL_X86_PEBS, - }, - { .uname = "LOAD_LATENCY_GT_128", - .udesc = "Counts randomly selected loads when the latency from first dispatch to completion is greater than 128 cycles.", - .ucode = 0x8000ull, - .uflags = INTEL_X86_NCOMBO | INTEL_X86_PEBS, - }, - { .uname = "LOAD_LATENCY_GT_64", - .udesc = "Counts randomly selected loads when the latency from first dispatch to completion is greater than 64 cycles.", - .ucode = 0x4000ull, - .uflags = INTEL_X86_NCOMBO | INTEL_X86_PEBS, - }, - { .uname = "LOAD_LATENCY_GT_32", - .udesc = "Counts randomly selected loads when the latency from first dispatch to completion is greater than 32 cycles.", - .ucode = 0x2000ull, - .uflags = INTEL_X86_NCOMBO | INTEL_X86_PEBS, - }, - { .uname = "LOAD_LATENCY_GT_16", - .udesc = "Counts randomly selected loads when the latency from first dispatch to completion is greater than 16 cycles.", - .ucode = 0x1000ull, - .uflags = INTEL_X86_NCOMBO | INTEL_X86_PEBS, - }, - { .uname = "LOAD_LATENCY_GT_8", - .udesc = "Counts randomly selected loads when the latency from first dispatch to completion is greater than 8 cycles.", - .ucode = 0x0800ull, - .uflags = INTEL_X86_NCOMBO | INTEL_X86_PEBS, - }, - { .uname = "LOAD_LATENCY_GT_4", - .udesc = "Counts randomly selected loads when the latency from first dispatch to completion is greater than 4 cycles.", - .ucode = 0x0400ull, - .uflags = INTEL_X86_NCOMBO | INTEL_X86_PEBS, + { .uname = "LOAD_LATENCY", + .udesc = "Memory load instructions retired above programmed clocks, minimum threshold value is 3 (Precise Event and ldlat required)", + .ucode = 0x100, + .uflags = INTEL_X86_NCOMBO | INTEL_X86_PEBS | INTEL_X86_LDLAT | INTEL_X86_DFL, }, }; @@ -1816,13 +1781,13 @@ static const intel_x86_umask_t intel_icl_cpu_clk_unhalted[]={ { .uname = "DISTRIBUTED", .udesc = "Cycle counts are evenly distributed between active threads in the Core.", - .ucode = 0x0200ull, - .uflags = INTEL_X86_NCOMBO, + .ucode = 0x02ecull, + .uflags = INTEL_X86_NCOMBO | INTEL_X86_CODE_OVERRIDE, }, { .uname = "REF_DISTRIBUTED", .udesc = "Core crystal clock cycles. Cycle counts are evenly distributed between active threads in the Core.", - .ucode = 0x0800ull, - .uflags = INTEL_X86_NCOMBO, + .ucode = 0x08ecull, + .uflags = INTEL_X86_NCOMBO | INTEL_X86_CODE_OVERRIDE, }, { .uname = "ONE_THREAD_ACTIVE", .udesc = "Core crystal clock cycles when this thread is unhalted and the other thread is halted.", @@ -1844,11 +1809,6 @@ .ucode = 0x0300ull, .uflags = INTEL_X86_NCOMBO, }, - { .uname = "THREAD", - .udesc = "Core cycles when the thread is not in halt state", - .ucode = 0x0200ull, - .uflags = INTEL_X86_NCOMBO, - }, }; static const intel_x86_umask_t intel_icl_inst_retired[]={ @@ -2491,7 +2451,7 @@ }, { .name = "CPU_CLK_UNHALTED", .desc = "Count core clock cycles whenever the clock signal on the specific core is running (not halted).", - .code = 0x0000, + .code = 0x003c, .modmsk = INTEL_V5_ATTRS, .cntmsk = 0x200000000ull, .ngrp = 1, diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_amd64.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_amd64.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_amd64.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_amd64.c 2020-12-10 03:49:59.000000000 +0000 @@ -687,6 +687,7 @@ info->is_dfl = 0; } info->is_precise = 0; + info->support_hw_smpl = 0; info->equiv = NULL; info->ctrl = PFM_ATTR_CTRL_PMU; info->idx = idx; /* namespace specific index */ @@ -709,6 +710,7 @@ info->pmu = pmu->pmu; info->is_precise = 0; + info->support_hw_smpl = 0; info->nattrs = amd64_num_umasks(this, idx); info->nattrs += amd64_num_mods(this, idx); diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_amd64_perf_event.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_amd64_perf_event.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_amd64_perf_event.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_amd64_perf_event.c 2020-12-10 03:49:59.000000000 +0000 @@ -134,6 +134,10 @@ compact = 1; } + /* hardware sampling not supported */ + if (e->pattrs[i].idx == PERF_ATTR_HWS) + compact = 1; + if (compact) { pfmlib_compact_pattrs(e, i); i--; @@ -161,6 +165,11 @@ compact = 1; } + /* hardware sampling not supported on AMD */ + if (e->pattrs[i].idx == PERF_ATTR_HWS) + compact = 1; + + if (compact) { pfmlib_compact_pattrs(e, i); i--; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_arm.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_arm.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_arm.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_arm.c 2020-12-10 03:49:59.000000000 +0000 @@ -322,6 +322,7 @@ info->dfl_val64 = 0; info->is_precise = 0; + info->support_hw_smpl = 0; return PFM_SUCCESS; } @@ -345,6 +346,7 @@ info->idx = idx; /* private index */ info->pmu = pmu->pmu; info->is_precise = 0; + info->support_hw_smpl = 0; /* no attributes defined for ARM yet */ info->nattrs = 0; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_arm_perf_event.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_arm_perf_event.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_arm_perf_event.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_arm_perf_event.c 2020-12-10 03:49:59.000000000 +0000 @@ -84,6 +84,9 @@ if (e->pattrs[i].idx == PERF_ATTR_PR) compact = 1; } + /* hardware sampling not supported */ + if (e->pattrs[i].idx == PERF_ATTR_HWS) + compact = 1; if (compact) { pfmlib_compact_pattrs(e, i); diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_intel_netburst.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_intel_netburst.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_intel_netburst.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_intel_netburst.c 2020-12-10 03:49:59.000000000 +0000 @@ -349,6 +349,8 @@ info->ctrl = PFM_ATTR_CTRL_PMU; info->idx = idx; /* namespace specific index */ info->dfl_val64 = 0; + info->is_precise = 0; + info->support_hw_smpl = 0; return PFM_SUCCESS; } @@ -369,6 +371,9 @@ info->idx = idx; /* private index */ info->pmu = pmu->pmu; + info->is_precise = 0; + info->support_hw_smpl = 0; + info->nattrs = netburst_get_numasks(idx); info->nattrs += NETBURST_MODS_COUNT; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_intel_netburst_perf_event.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_intel_netburst_perf_event.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_intel_netburst_perf_event.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_intel_netburst_perf_event.c 2020-12-10 03:49:59.000000000 +0000 @@ -93,6 +93,11 @@ compact = 1; } + /* hardware sampling not supported */ + if (e->pattrs[i].idx == PERF_ATTR_HWS) + compact = 1; + + if (compact) { pfmlib_compact_pattrs(e, i); i--; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_intel_snbep_unc.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_intel_snbep_unc.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_intel_snbep_unc.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_intel_snbep_unc.c 2020-12-10 03:49:59.000000000 +0000 @@ -900,6 +900,7 @@ info->ctrl = PFM_ATTR_CTRL_PMU; info->idx = idx; /* namespace specific index */ info->dfl_val64 = 0; + info->support_hw_smpl = 0; return PFM_SUCCESS; } diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_intel_snbep_unc_perf_event.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_intel_snbep_unc_perf_event.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_intel_snbep_unc_perf_event.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_intel_snbep_unc_perf_event.c 2020-12-10 03:49:59.000000000 +0000 @@ -159,6 +159,10 @@ compact = 1; } + /* hardware sampling not supported */ + if (e->pattrs[i].idx == PERF_ATTR_HWS) + compact = 1; + if (compact) { pfmlib_compact_pattrs(e, i); i--; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_mips.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_mips.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_mips.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_mips.c 2020-12-10 03:49:59.000000000 +0000 @@ -346,6 +346,7 @@ info->code = attr_idx; info->is_dfl = 0; info->is_precise = 0; + info->support_hw_smpl = 0; info->ctrl = PFM_ATTR_CTRL_PMU;; return PFM_SUCCESS; @@ -364,6 +365,7 @@ info->idx = idx; /* private index */ info->pmu = pmu->pmu; info->is_precise = 0; + info->support_hw_smpl = 0; /* no attributes defined for MIPS yet */ info->nattrs = pfm_mips_get_event_nattrs(this, idx); diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_mips_perf_event.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_mips_perf_event.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_mips_perf_event.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_mips_perf_event.c 2020-12-10 03:49:59.000000000 +0000 @@ -104,6 +104,11 @@ compact = 1; } + /* hardware sampling not supported */ + if (e->pattrs[i].idx == PERF_ATTR_HWS) + compact = 1; + + if (compact) { pfmlib_compact_pattrs(e, i); i--; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_perf_event_pmu.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_perf_event_pmu.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_perf_event_pmu.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_perf_event_pmu.c 2020-12-10 03:49:59.000000000 +0000 @@ -765,6 +765,7 @@ info->ctrl = PFM_ATTR_CTRL_PMU; info->is_precise = !!(um->uflags & PERF_FL_PRECISE); + info->support_hw_smpl = info->is_precise; info->is_dfl = 0; info->idx = attr_idx; info->dfl_val64 = 0; @@ -783,6 +784,7 @@ info->idx = idx; info->pmu = pmu->pmu; info->is_precise = !!(perf_pe[idx].flags & PERF_FL_PRECISE); + info->support_hw_smpl = info->is_precise; /* unit masks + modifiers */ info->nattrs = perf_pe[idx].numasks; @@ -990,6 +992,10 @@ compact = 1; } + /* hardware sampling not supported */ + if (e->pattrs[i].idx == PERF_ATTR_HWS) + compact = 1; + if (compact) { pfmlib_compact_pattrs(e, i); i--; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_perf_event_raw.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_perf_event_raw.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_perf_event_raw.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_perf_event_raw.c 2020-12-10 03:49:59.000000000 +0000 @@ -108,6 +108,7 @@ info->idx = 0; info->pmu = pmu->pmu; info->is_precise = 0; + info->support_hw_smpl = 0; /* unit masks + modifiers */ info->nattrs = 0; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_powerpc.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_powerpc.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_powerpc.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_powerpc.c 2020-12-10 03:49:59.000000000 +0000 @@ -49,6 +49,7 @@ info->idx = pidx; /* private index */ info->pmu = pmu->pmu; info->is_precise = 0; + info->support_hw_smpl = 0; info->nattrs = 0; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_powerpc_perf_event.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_powerpc_perf_event.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_powerpc_perf_event.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_powerpc_perf_event.c 2020-12-10 03:49:59.000000000 +0000 @@ -138,6 +138,10 @@ compact = 1; } + /* hardware sampling not supported */ + if (e->pattrs[i].idx == PERF_ATTR_HWS) + compact = 1; + if (compact) { pfmlib_compact_pattrs(e, i); i--; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_s390x_cpumf.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_s390x_cpumf.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_s390x_cpumf.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_s390x_cpumf.c 2020-12-10 03:49:59.000000000 +0000 @@ -376,6 +376,7 @@ .validate_table = pfm_cpumcf_validate_table, .get_event_info = pfm_cpumf_get_event_info, .get_event_attr_info = pfm_cpumf_get_event_attr_info, + PFMLIB_VALID_PERF_PATTRS(pfm_s390x_perf_validate_pattrs), }; pfmlib_pmu_t s390x_cpum_sf_support = { @@ -402,4 +403,5 @@ .validate_table = pfm_cpumf_validate_table, .get_event_info = pfm_cpumf_get_event_info, .get_event_attr_info = pfm_cpumf_get_event_attr_info, + PFMLIB_VALID_PERF_PATTRS(pfm_s390x_perf_validate_pattrs), }; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_s390x_perf_event.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_s390x_perf_event.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_s390x_perf_event.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_s390x_perf_event.c 2020-12-10 03:49:59.000000000 +0000 @@ -87,3 +87,33 @@ return rc; } + +void +pfm_s390x_perf_validate_pattrs(void *this, pfmlib_event_desc_t *e) +{ + int i, compact; + + for (i=0; i < e->npattrs; i++) { + compact = 0; + + /* umasks never conflict */ + if (e->pattrs[i].type == PFM_ATTR_UMASK) + continue; + + if (e->pattrs[i].ctrl == PFM_ATTR_CTRL_PERF_EVENT) { + /* No precise mode on s390x */ + if (e->pattrs[i].idx == PERF_ATTR_PR) + compact = 1; + + } + + /* hardware sampling not supported */ + if (e->pattrs[i].idx == PERF_ATTR_HWS) + compact = 1; + + if (compact) { + pfmlib_compact_pattrs(e, i); + i--; + } + } +} diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_s390x_priv.h libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_s390x_priv.h --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_s390x_priv.h 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_s390x_priv.h 2020-12-10 03:49:59.000000000 +0000 @@ -11,5 +11,6 @@ #define min(a, b) ((a) < (b) ? (a) : (b)) extern int pfm_s390x_get_perf_encoding(void *this, pfmlib_event_desc_t *e); +extern void pfm_s390x_perf_validate_pattrs(void *this, pfmlib_event_desc_t *e); #endif /* __PFMLIB_S390X_PRIV_H__ */ diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_sparc.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_sparc.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_sparc.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_sparc.c 2020-12-10 03:49:59.000000000 +0000 @@ -288,6 +288,7 @@ info->is_dfl = 0; info->is_precise = 0; + info->support_hw_smpl = 0; info->ctrl = PFM_ATTR_CTRL_PMU;; return PFM_SUCCESS; @@ -308,6 +309,7 @@ info->idx = idx; /* private index */ info->pmu = pmu->pmu; info->is_precise = 0; + info->support_hw_smpl = 0; info->nattrs = pe[idx].numasks; diff -Nru libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_sparc_perf_event.c libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_sparc_perf_event.c --- libpfm4-4.11.1+git4-gfa84c27/lib/pfmlib_sparc_perf_event.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/lib/pfmlib_sparc_perf_event.c 2020-12-10 03:49:59.000000000 +0000 @@ -77,6 +77,10 @@ compact = 1; } + /* hardware sampling not supported */ + if (e->pattrs[i].idx == PERF_ATTR_HWS) + compact = 1; + if (compact) { pfmlib_compact_pattrs(e, i); i--; diff -Nru libpfm4-4.11.1+git4-gfa84c27/tests/validate_x86.c libpfm4-4.11.1+git8-gc96ebc0/tests/validate_x86.c --- libpfm4-4.11.1+git4-gfa84c27/tests/validate_x86.c 2020-09-25 19:01:51.000000000 +0000 +++ libpfm4-4.11.1+git8-gc96ebc0/tests/validate_x86.c 2020-12-10 03:49:59.000000000 +0000 @@ -7040,6 +7040,20 @@ .fstr = "icl::MEM_LOAD_RETIRED:L3_MISS:k=1:u=1:e=0:i=0:c=0:intx=0:intxcp=0", }, { SRC_LINE, + .name = "icl::CPU_CLK_UNHALTED.DISTRIBUTED", + .ret = PFM_SUCCESS, + .count = 1, + .codes[0] = 0x5302ec, + .fstr = "icl::CPU_CLK_UNHALTED:DISTRIBUTED:k=1:u=1:e=0:i=0:c=0:intx=0:intxcp=0", + }, + { SRC_LINE, + .name = "icl::CPU_CLK_UNHALTED.REF_DISTRIBUTED", + .ret = PFM_SUCCESS, + .count = 1, + .codes[0] = 0x5308ec, + .fstr = "icl::CPU_CLK_UNHALTED:REF_DISTRIBUTED:k=1:u=1:e=0:i=0:c=0:intx=0:intxcp=0", + }, + { SRC_LINE, .name = "icl::FRONTEND_RETIRED:ITLB_MISS", .ret = PFM_SUCCESS, .count = 2, @@ -7241,6 +7255,30 @@ .codes[0] = 0x530100, .fstr = "icl::INST_RETIRED:ANY:k=1:u=1:e=0:i=0:c=0:intx=0:intxcp=0", }, + { SRC_LINE, + .name = "icl::mem_trans_retired:load_latency:ldlat=3:u", + .ret = PFM_SUCCESS, + .count = 2, + .codes[0] = 0x5101cd, + .codes[1] = 3, + .fstr = "icl::MEM_TRANS_RETIRED:LOAD_LATENCY:k=0:u=1:e=0:i=0:c=0:ldlat=3:intx=0:intxcp=0", + }, + { SRC_LINE, + .name = "icl::mem_trans_retired:load_latency:ldlat=1000000", + .ret = PFM_ERR_ATTR_VAL, + }, + { SRC_LINE, + .name = "icl::mem_trans_retired:load_latency", + .ret = PFM_SUCCESS, + .count = 2, + .codes[0] = 0x5301cd, + .codes[1] = 3, + .fstr = "icl::MEM_TRANS_RETIRED:LOAD_LATENCY:k=1:u=1:e=0:i=0:c=0:ldlat=3:intx=0:intxcp=0", + }, + { SRC_LINE, + .name = "icl::mem_trans_retired:load_latency:ldlat=2:intx=0:intxcp=0", + .ret = PFM_ERR_ATTR_VAL, + }, }; #define NUM_TEST_EVENTS (int)(sizeof(x86_test_events)/sizeof(test_event_t))