perf/x86/intel/uncore: Fix the lack of ch_mask format for SPR
Subsystems (2)
PATCH 1/1 perf/x86/intel/uncore: Fix the lack of ch_mask format for SPR
perf stat errors out with UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL event because of lack of ch_mask format in drivers, and perf test "104: perf all PMU test (exclusive)" failed.
$perf stat -e perf stat -e UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL sleep 1
Initial error:
event syntax error: 'UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL'
\___ unknown term 'ch_mask' for pmu 'uncore_cha_0'
104: perf all PMU test (exclusive) : FAILED!
Add ch_mask format for SPR to fix it.
--- arch/x86/events/intel/uncore_snbep.c | 1 + 1 file changed, 1 insertion(+)
arch/x86/events/intel/uncore_snbep.c +1 -0
@@ -5967,6 +5967,7 @@ static int spr_cha_hw_config(struct intel_uncore_box *box, struct perf_event *ev &format_attr_inv.attr, &format_attr_thresh8.attr, &format_attr_filter_tid5.attr, + &format_attr_ch_mask.attr, NULL, }; static const struct attribute_group spr_uncore_chabox_format_group = {
Signature · 1 line
1.8.3.1
Quoted 7 lines · Jing Zhang
perf stat errors out with UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL event because of lack of
ch_maskformat in drivers, and perf test "104: perf all PMU test (exclusive)" failed.$perf stat -e perf stat -e UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL sleep 1
Quoted 8 lines
Initial error:
event syntax error: 'UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL'
\___ unknown term 'ch_mask' for pmu 'uncore_cha_0'104: perf all PMU test (exclusive) : FAILED!
Add
ch_maskformat for SPR to fix it.
I don't think there is a ch_mask. It should be extended umask. The issue of the CHA extended umask should has been fixed by
https://lore.kernel.org/lkml/172052531679.2215.16140288595428337453.tip-bot2@tip-bot2/
Thanks,
Kan
Quoted 18 lines
Fixes 949b11381f81 ("perf/x86/intel/uncore: Add Sapphire Rapids server CHA support")Signed-off-by Jing Zhang <[email protected]>--- arch/x86/events/intel/uncore_snbep.c | 1 + 1 file changed, 1 insertion(+)arch/x86/events/intel/uncore_snbep.c +1
-0@@ -5967,6 +5967,7 @@ static int spr_cha_hw_config(struct intel_uncore_box *box, struct perf_event *ev &format_attr_inv.attr, &format_attr_thresh8.attr, &format_attr_filter_tid5.attr, + &format_attr_ch_mask.attr, NULL, }; static const struct attribute_group spr_uncore_chabox_format_group = {
Quoted 14 lines · Kan
Quoted 11 lines · Jing Zhang
perf stat errors out with UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL event because of lack of
ch_maskformat in drivers, and perf test "104: perf all PMU test (exclusive)" failed.$perf stat -e perf stat -e UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL sleep 1
Initial error:
event syntax error: 'UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL'
\___ unknown term 'ch_mask' for pmu 'uncore_cha_0'
Quoted 9 lines
Quoted 4 lines
104: perf all PMU test (exclusive) : FAILED!
Add
ch_maskformat for SPR to fix it.I don't think there is a
ch_mask. It should be extended umask. The issue of the CHA extended umask should has been fixed by
https://lore.kernel.org/lkml/172052531679.2215.16140288595428337453.tip-bot2@tip-bot2/
I think it is not the same issue. I have this patch but still error.
in "tools/perf/pmu-events/arch/x86/sapphirerapids/uncore-cache.json", the event "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL" is described as:
{
"BriefDescription": "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL",
"Counter": "0,1,2,3",
"EventCode": "0x35",
"EventName": "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL",
"Experimental": "1",
"PerPkg": "1",
"PortMask": "0x000",
"UMask": "0x10c0008101",
"Unit": "CHA"
},the PortMask is ch_mask, but driver not output ch_mask on SPR, it causes error.
Thanks,
Jing
Quoted 24 lines
Thanks,
KanQuoted 18 lines
Fixes 949b11381f81 ("perf/x86/intel/uncore: Add Sapphire Rapids server CHA support")Signed-off-by Jing Zhang <[email protected]>--- arch/x86/events/intel/uncore_snbep.c | 1 + 1 file changed, 1 insertion(+)arch/x86/events/intel/uncore_snbep.c +1
-0@@ -5967,6 +5967,7 @@ static int spr_cha_hw_config(struct intel_uncore_box *box, struct perf_event *ev &format_attr_inv.attr, &format_attr_thresh8.attr, &format_attr_filter_tid5.attr, + &format_attr_ch_mask.attr, NULL, }; static const struct attribute_group spr_uncore_chabox_format_group = {
Quoted 43 lines · Jing Zhang
Quoted 14 lines · Kan
Quoted 11 lines · Jing Zhang
perf stat errors out with UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL event because of lack of
ch_maskformat in drivers, and perf test "104: perf all PMU test (exclusive)" failed.$perf stat -e perf stat -e UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL sleep 1
Initial error:
event syntax error: 'UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL'
\___ unknown term 'ch_mask' for pmu 'uncore_cha_0'Quoted 9 lines
Quoted 4 lines
104: perf all PMU test (exclusive) : FAILED!
Add
ch_maskformat for SPR to fix it.I don't think there is a
ch_mask. It should be extended umask. The issue of the CHA extended umask should has been fixed by
https://lore.kernel.org/lkml/172052531679.2215.16140288595428337453.tip-bot2@tip-bot2/I think it is not the same issue. I have this patch but still error.
in "
tools/perf/pmu-events/arch/x86/sapphirerapids/uncore-cache.json", the event "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL" is described as:{ "BriefDescription": "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL", "Counter": "0,1,2,3", "EventCode": "0x35", "EventName": "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL", "Experimental": "1", "PerPkg": "1", "PortMask": "0x000", "UMask": "0x10c0008101", "Unit": "CHA" },
Quoted 1 line
the PortMask is
ch_mask, but driver not outputch_maskon SPR, it causes error.
There is no ch_mask on SPR. It should be Extended Umask. The convertor tool should avoid generating the PortMask and FCMask for SPR/EMR/GNR.
+ Thomas
Could you please take a look? We may have to re-generate the event list.
Thanks,
Kan
Quoted 29 lines
Thanks,
JingQuoted 24 lines
Thanks,
KanQuoted 18 lines
Fixes 949b11381f81 ("perf/x86/intel/uncore: Add Sapphire Rapids server CHA support")Signed-off-by Jing Zhang <[email protected]>--- arch/x86/events/intel/uncore_snbep.c | 1 + 1 file changed, 1 insertion(+)arch/x86/events/intel/uncore_snbep.c +1
-0@@ -5967,6 +5967,7 @@ static int spr_cha_hw_config(struct intel_uncore_box *box, struct perf_event *ev &format_attr_inv.attr, &format_attr_thresh8.attr, &format_attr_filter_tid5.attr, + &format_attr_ch_mask.attr, NULL, }; static const struct attribute_group spr_uncore_chabox_format_group = {
Quoted 46 lines · Kan
Quoted 43 lines · Jing Zhang
Quoted 14 lines · Kan
Quoted 11 lines · Jing Zhang
perf stat errors out with UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL event because of lack of
ch_maskformat in drivers, and perf test "104: perf all PMU test (exclusive)" failed.$perf stat -e perf stat -e UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL sleep 1
Initial error:
event syntax error: 'UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL'
\___ unknown term 'ch_mask' for pmu 'uncore_cha_0'Quoted 9 lines
Quoted 4 lines
104: perf all PMU test (exclusive) : FAILED!
Add
ch_maskformat for SPR to fix it.I don't think there is a
ch_mask. It should be extended umask. The issue of the CHA extended umask should has been fixed by
https://lore.kernel.org/lkml/172052531679.2215.16140288595428337453.tip-bot2@tip-bot2/I think it is not the same issue. I have this patch but still error.
in "
tools/perf/pmu-events/arch/x86/sapphirerapids/uncore-cache.json", the event "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL" is described as:{ "BriefDescription": "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL", "Counter": "0,1,2,3", "EventCode": "0x35", "EventName": "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL", "Experimental": "1", "PerPkg": "1", "PortMask": "0x000", "UMask": "0x10c0008101", "Unit": "CHA" },
Quoted 5 lines
Quoted 1 line
the PortMask is
ch_mask, but driver not outputch_maskon SPR, it causes error.There is no
ch_maskon SPR. It should be Extended Umask. The convertor tool should avoid generating the PortMask and FCMask for SPR/EMR/GNR.
Oh, I see. Maybe the event description is inaccurate.
Thanks,
Jing
Quoted 38 lines
+ Thomas
Could you please take a look? We may have to re-generate the event list.
Thanks,
KanQuoted 29 lines
Thanks,
JingQuoted 24 lines
Thanks,
KanQuoted 18 lines
Fixes 949b11381f81 ("perf/x86/intel/uncore: Add Sapphire Rapids server CHA support")Signed-off-by Jing Zhang <[email protected]>--- arch/x86/events/intel/uncore_snbep.c | 1 + 1 file changed, 1 insertion(+)arch/x86/events/intel/uncore_snbep.c +1
-0@@ -5967,6 +5967,7 @@ static int spr_cha_hw_config(struct intel_uncore_box *box, struct perf_event *ev &format_attr_inv.attr, &format_attr_thresh8.attr, &format_attr_filter_tid5.attr, + &format_attr_ch_mask.attr, NULL, }; static const struct attribute_group spr_uncore_chabox_format_group = {
Quoted 67 lines · Jing Zhang
Quoted 56 lines · Kan
Quoted 53 lines · Jing Zhang
Quoted 22 lines · Kan
Quoted 19 lines · Jing Zhang
perf stat errors out with UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL event because of lack of
ch_maskformat in drivers, and perf test "104: perf
all PMU test (exclusive)" failed.$perf stat -e perf stat -e
UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL
sleep 1Initial error:
event syntax error:
'UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL'
\___ unknown term 'ch_mask' for pmu 'uncore_cha_0'104: perf all PMU test
(exclusive) : FAILED!Quoted 7 lines
Quoted 2 lines
Add
ch_maskformat for SPR to fix it.I don't think there is a
ch_mask. It should be extended umask. The issue of the CHA extended umask should has been fixed by
https://lore.kernel.org/lkml/172052531679.2215.16140288595428337453.tip-bot2@tip-bot2/I think it is not the same issue. I have this patch but still error.
in "
tools/perf/pmu-events/arch/x86/sapphirerapids/uncore-cache.json",
the event "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL" is described as:
{
"BriefDescription":
"UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL",
"Counter": "0,1,2,3",
"EventCode": "0x35",
"EventName": "UNC_CHA_TOR_INSERTS.IA_HIT_CXL_ACC_LOCAL", "Experimental": "1",
"PerPkg": "1",
"PortMask": "0x000",
"UMask": "0x10c0008101",
"Unit": "CHA"
},Quoted 7 lines
Quoted 2 lines
the PortMask is
ch_mask, but driver not outputch_maskon SPR, it causes error.There is no
ch_maskon SPR. It should be Extended Umask. The convertor tool should avoid generating the PortMask and FCMask for
SPR/EMR/GNR.
Quoted 10 lines
Oh, I see. Maybe the event description is inaccurate.
Thanks,
JingQuoted 5 lines
+ Thomas
Could you please take a look? We may have to re-generate the event list.
Jing, could you please retest with the latest perf-tools-next:
https://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools-next.git/?h=perf-tools-next
and with this patch series applied:
https://lore.kernel.org/lkml/[email protected]/
Please let us know if that resolves the issue for you.
Thanks,
Tom
Quoted 38 lines
Quoted 38 lines
Thanks,
KanQuoted 33 lines
Thanks,
JingQuoted 28 lines
Thanks,
KanQuoted 22 lines
Fixes 949b11381f81 ("perf/x86/intel/uncore: Add SapphireRapids server CHA support")
Signed-off-by Jing Zhang <[email protected]>---
arch/x86/events/intel/uncore_snbep.c | 1 +1 file changed, 1 insertion(+)arch/x86/events/intel/uncore_snbep.c +0
-0@@ -5967,6 +5967,7 @@ static int spr_cha_hw_config(struct
intel_uncore_box*box, structperf_event*ev
&format_attr_inv.attr,
&format_attr_thresh8.attr,
&format_attr_filter_tid5.attr,arch/x86/events/intel/uncore_snbep.c +1
-0+ &format_attr_ch_mask.attr,NULL,
};
static const structattribute_groupspr_uncore_chabox_format_group= {