]> git.baikalelectronics.ru Git - kernel.git/commitdiff
perf vendor events power9: Add hv_24x7 core level metric events
authorKajol Jain <kjain@linux.ibm.com>
Mon, 7 Sep 2020 06:41:33 +0000 (12:11 +0530)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 10 Sep 2020 12:19:53 +0000 (09:19 -0300)
This patch adds hv_24x7 core level events in nest_metric.json file and
also add PerChip/PerCore field in metric events.

Result:

power9 platform:

command:# ./perf stat --metric-only -M PowerBUS_Frequency -C 0 -I 1000
     1.000070601                        1.9                        2.0
     2.000253881                        2.0                        1.9
     3.000364810                        2.0                        2.0

Signed-off-by: Kajol Jain <kjain@linux.ibm.com>
Acked-by: Ian Rogers <irogers@google.com>
Acked-by: Jiri Olsa <jolsa@redhat.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Jin Yao <yao.jin@linux.intel.com>
Cc: John Garry <john.garry@huawei.com>
Cc: Madhavan Srinivasan <maddy@linux.ibm.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Clarke <pc@us.ibm.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Ravi Bangoria <ravi.bangoria@linux.ibm.com>
Link: http://lore.kernel.org/lkml/20200907064133.75090-6-kjain@linux.ibm.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/pmu-events/arch/powerpc/power9/nest_metrics.json

index 8383a37647ad03f51dc8799981ddf7b5b9cf69f0..7a5d1bf543f82237f56569af021657fa14048ad2 100644 (file)
@@ -1,37 +1,46 @@
 [
     {
-        "MetricExpr": "(hv_24x7@PM_MCS01_128B_RD_DISP_PORT01\\,chip\\=?@ + hv_24x7@PM_MCS01_128B_RD_DISP_PORT23\\,chip\\=?@ + hv_24x7@PM_MCS23_128B_RD_DISP_PORT01\\,chip\\=?@ + hv_24x7@PM_MCS23_128B_RD_DISP_PORT23\\,chip\\=?@)",
-        "MetricName": "Memory_RD_BW_Chip",
-        "MetricGroup": "Memory_BW",
-        "ScaleUnit": "1.6e-2MB"
+       "MetricExpr": "(hv_24x7@PM_MCS01_128B_RD_DISP_PORT01\\,chip\\=?@ + hv_24x7@PM_MCS01_128B_RD_DISP_PORT23\\,chip\\=?@ + hv_24x7@PM_MCS23_128B_RD_DISP_PORT01\\,chip\\=?@ + hv_24x7@PM_MCS23_128B_RD_DISP_PORT23\\,chip\\=?@)",
+       "MetricName": "Memory_RD_BW_Chip",
+       "MetricGroup": "Memory_BW",
+       "ScaleUnit": "1.6e-2MB",
+       "AggregationMode": "PerChip"
     },
     {
        "MetricExpr": "(hv_24x7@PM_MCS01_128B_WR_DISP_PORT01\\,chip\\=?@ + hv_24x7@PM_MCS01_128B_WR_DISP_PORT23\\,chip\\=?@ + hv_24x7@PM_MCS23_128B_WR_DISP_PORT01\\,chip\\=?@ + hv_24x7@PM_MCS23_128B_WR_DISP_PORT23\\,chip\\=?@ )",
-        "MetricName": "Memory_WR_BW_Chip",
-        "MetricGroup": "Memory_BW",
-        "ScaleUnit": "1.6e-2MB"
+       "MetricName": "Memory_WR_BW_Chip",
+       "MetricGroup": "Memory_BW",
+       "ScaleUnit": "1.6e-2MB",
+       "AggregationMode": "PerChip"
     },
     {
        "MetricExpr": "(hv_24x7@PM_PB_CYC\\,chip\\=?@ )",
-        "MetricName": "PowerBUS_Frequency",
-        "ScaleUnit": "2.5e-7GHz"
+       "MetricName": "PowerBUS_Frequency",
+       "ScaleUnit": "2.5e-7GHz",
+       "AggregationMode": "PerChip"
+    },
+    {
+       "MetricExpr": "(hv_24x7@CPM_CS_32MHZ_CYC\\,domain\\=3\\,core\\=?@ )",
+       "MetricName": "CPM_CS_32MHZ_CYC",
+       "ScaleUnit": "1MHz",
+       "AggregationMode": "PerCore"
     },
     {
        "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",
+       "MetricGroup" : "memory-bandwidth",
        "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",
+       "MetricGroup" : "memory-bandwidth",
        "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",
+       "MetricGroup" : "memory-bandwidth",
        "ScaleUnit": "6.1e-5MB"
     },
     {
@@ -48,7 +57,7 @@
     {
        "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",
+       "MetricGroup" : "memory-bandwidth",
        "ScaleUnit": "6.1e-5MB"
     }
 ]