Skip to contentSkip to conversation

perf/tools/pmu-events/powerpc: Added nest imc metric events

PATCH Applied Kajol Jain 3 participants 3 messages Jul 3, 2020 – Jul 6, 2020 perf events

lore
Share & tools
lore

Kajol Jain

author
#0 lore raw

PATCH 1/1 perf/tools/pmu-events/powerpc: Added nest imc metric events

Added nest imc metric events.

---
 .../arch/powerpc/power9/nest_metrics.json     | 35 +++++++++++++++++++
 1 file changed, 35 insertions(+)
tools/perf/pmu-events/arch/powerpc/power9/nest_metrics.json +35 -0
index c121e526442a..8383a37647ad 100644
@@ -15,5 +15,40 @@
 	"MetricExpr": "(hv_24x7@PM_PB_CYC\\,chip\\=?@ )",
         "MetricName": "PowerBUS_Frequency",
         "ScaleUnit": "2.5e-7GHz"
+    },
+    {
+	"MetricExpr" : "nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT23@",
+	"MetricName" : "mcs01-read",
+	"MetricGroup" : "memory_bw",
+	"ScaleUnit": "6.1e-5MB"
+    },
+    {
+	"MetricExpr" : "nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT23@",
+	"MetricName" : "mcs23-read",
+	"MetricGroup" : "memory_bw",
+	"ScaleUnit": "6.1e-5MB"
+    },
+    {
+	"MetricExpr" : "nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT23@",
+	"MetricName" : "mcs01-write",
+	"MetricGroup" : "memory_bw",
+	"ScaleUnit": "6.1e-5MB"
+    },
+    {
+	"MetricExpr" : "nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT23@",
+	"MetricName" : "mcs23-write",
+	"MetricGroup" : "memory-bandwidth",
+	"ScaleUnit": "6.1e-5MB"
+    },
+    {
+	"MetricExpr" : "nest_powerbus0_imc@PM_PB_CYC@",
+	"MetricName" : "powerbus_freq",
+	"ScaleUnit": "1e-9GHz"
+    },
+    {
+	"MetricExpr" : "(nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT23@ + nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT23@ + nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT23@ + nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT23@)",
+	"MetricName" : "Memory-bandwidth-MCS",
+	"MetricGroup" : "memory_bw",
+	"ScaleUnit": "6.1e-5MB"
     }
 ]
Signature · 1 line
2.17.1
reviewer Acked-by on v1 1/1
#1 lore raw
Quoted 2 lines · Kajol Jain

Added nest imc metric events.

Quoted 10 lines
---
 .../arch/powerpc/power9/nest_metrics.json     | 35 +++++++++++++++++++
 1 file changed, 35 insertions(+)
tools/perf/pmu-events/arch/powerpc/power9/nest_metrics.json +0 -0
index c121e526442a..8383a37647ad 100644

tools/perf/pmu-events/arch/powerpc/power9/nest_metrics.json line 23

Quoted 9 lines
tools/perf/pmu-events/arch/powerpc/power9/nest_metrics.json +6 -0
@@ -15,5 +15,40 @@
        "MetricExpr": "(hv_24x7@PM_PB_CYC\\,chip\\=?@ )",
         "MetricName": "PowerBUS_Frequency",
         "ScaleUnit": "2.5e-7GHz"
+    },
+    {
+       "MetricExpr" : "nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT23@",
+       "MetricName" : "mcs01-read",
+       "MetricGroup" : "memory_bw",
+       "ScaleUnit": "6.1e-5MB"

nit: I'm guessing this is from:
64.0/(1024.0*1024.0) = 6.103515625e-05
and for reference:
64.0/(1000.0*1000.0) = 6.3999999999999997e-05
should the unit be MiB?
https://en.wikipedia.org/wiki/Kibibyte

Searching around I only see knightslanding using MiB but it seems to be using it in the 1000^2 case which probably means it should be MB:
knightslanding/uncore-memory.json: "ScaleUnit": "6.4e-05MiB"

Given there is some confusion I wonder if it makes sense to just make this 0.015625B and then we have a utility function that selects the best unit for "bytes" with config options similar to --big-num?

Thanks,
Ian

Quoted 34 lines
tools/perf/pmu-events/arch/powerpc/power9/nest_metrics.json +29 -1
+    },
+    {
+       "MetricExpr" : "nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT23@",
+       "MetricName" : "mcs23-read",
+       "MetricGroup" : "memory_bw",
+       "ScaleUnit": "6.1e-5MB"
+    },
+    {
+       "MetricExpr" : "nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT23@",
+       "MetricName" : "mcs01-write",
+       "MetricGroup" : "memory_bw",
+       "ScaleUnit": "6.1e-5MB"
+    },
+    {
+       "MetricExpr" : "nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT23@",
+       "MetricName" : "mcs23-write",
+       "MetricGroup" : "memory-bandwidth",
+       "ScaleUnit": "6.1e-5MB"
+    },
+    {
+       "MetricExpr" : "nest_powerbus0_imc@PM_PB_CYC@",
+       "MetricName" : "powerbus_freq",
+       "ScaleUnit": "1e-9GHz"
+    },
+    {
+       "MetricExpr" : "(nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT23@ + nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT23@ + nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT23@ + nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT23@)",
+       "MetricName" : "Memory-bandwidth-MCS",
+       "MetricGroup" : "memory_bw",
+       "ScaleUnit": "6.1e-5MB"
     }
 ]
--

2.17.1

maintainer Applied
#2 lore raw

Em Sun, Jul 05, 2020 at 06:30:30PM -0700, Ian Rogers escreveu:

Quoted 5 lines · Kajol Jain
Quoted 2 lines

Added nest imc metric events.

Thanks, applied.

- Arnaldo

Quoted 72 lines
Quoted 10 lines
---
 .../arch/powerpc/power9/nest_metrics.json     | 35 +++++++++++++++++++
 1 file changed, 35 insertions(+)
tools/perf/pmu-events/arch/powerpc/power9/nest_metrics.json +0 -0
index c121e526442a..8383a37647ad 100644

tools/perf/pmu-events/arch/powerpc/power9/nest_metrics.json line 23

Quoted 9 lines
tools/perf/pmu-events/arch/powerpc/power9/nest_metrics.json +6 -0
@@ -15,5 +15,40 @@
        "MetricExpr": "(hv_24x7@PM_PB_CYC\\,chip\\=?@ )",
         "MetricName": "PowerBUS_Frequency",
         "ScaleUnit": "2.5e-7GHz"
+    },
+    {
+       "MetricExpr" : "nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT23@",
+       "MetricName" : "mcs01-read",
+       "MetricGroup" : "memory_bw",
+       "ScaleUnit": "6.1e-5MB"

nit: I'm guessing this is from:
64.0/(1024.0*1024.0) = 6.103515625e-05
and for reference:
64.0/(1000.0*1000.0) = 6.3999999999999997e-05
should the unit be MiB?
https://en.wikipedia.org/wiki/Kibibyte

Searching around I only see knightslanding using MiB but it seems to be using it in the 1000^2 case which probably means it should be MB:
knightslanding/uncore-memory.json: "ScaleUnit": "6.4e-05MiB"

Given there is some confusion I wonder if it makes sense to just make this 0.015625B and then we have a utility function that selects the best unit for "bytes" with config options similar to --big-num?

Thanks,
Ian

Quoted 34 lines
tools/perf/pmu-events/arch/powerpc/power9/nest_metrics.json +29 -1
+    },
+    {
+       "MetricExpr" : "nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT23@",
+       "MetricName" : "mcs23-read",
+       "MetricGroup" : "memory_bw",
+       "ScaleUnit": "6.1e-5MB"
+    },
+    {
+       "MetricExpr" : "nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT23@",
+       "MetricName" : "mcs01-write",
+       "MetricGroup" : "memory_bw",
+       "ScaleUnit": "6.1e-5MB"
+    },
+    {
+       "MetricExpr" : "nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT23@",
+       "MetricName" : "mcs23-write",
+       "MetricGroup" : "memory-bandwidth",
+       "ScaleUnit": "6.1e-5MB"
+    },
+    {
+       "MetricExpr" : "nest_powerbus0_imc@PM_PB_CYC@",
+       "MetricName" : "powerbus_freq",
+       "ScaleUnit": "1e-9GHz"
+    },
+    {
+       "MetricExpr" : "(nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_RD_DISP_PORT23@ + nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_RD_DISP_PORT23@ + nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT01@ + nest_mcs01_imc@PM_MCS01_128B_WR_DISP_PORT23@ + nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT01@ + nest_mcs23_imc@PM_MCS23_128B_WR_DISP_PORT23@)",
+       "MetricName" : "Memory-bandwidth-MCS",
+       "MetricGroup" : "memory_bw",
+       "ScaleUnit": "6.1e-5MB"
     }
 ]
--

2.17.1

Signature · 1 line
- Arnaldo