[PATCH v2 5/5] perf vendor events: Add JSON metrics for Yitian 710 DDR

Jing Zhang posted 5 patches 2 years, 9 months ago
There is a newer version of this series
[PATCH v2 5/5] perf vendor events: Add JSON metrics for Yitian 710 DDR
Posted by Jing Zhang 2 years, 9 months ago
Add JSON metrics for T-HEAD Yitian 710 SoC DDR.

Signed-off-by: Jing Zhang <renyu.zj@linux.alibaba.com>
---
 .../arch/arm64/freescale/yitian710/sys/metrics.json  | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)
 create mode 100644 tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json

diff --git a/tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json b/tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json
new file mode 100644
index 0000000..1a92477
--- /dev/null
+++ b/tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json
@@ -0,0 +1,20 @@
+[
+	{
+		"MetricName": "ddr_read_bandwidth.all",
+		"BriefDescription": "The ddr read bandwidth(MB/s).",
+		"MetricGroup": "ddr",
+		"MetricExpr": "hif_rd * 64 / 1e6 / duration_time",
+		"ScaleUnit": "1MB/s",
+		"Unit": "ali_drw",
+		"Compat": "ali_drw_pmu"
+	},
+	{
+		"MetricName": "ddr_write_bandwidth.all",
+		"BriefDescription": "The ddr write bandwidth(MB/s).",
+		"MetricGroup": "ddr",
+		"MetricExpr": "(hif_wr + hif_rmw) * 64 / 1e6 / duration_time",
+		"ScaleUnit": "1MB/s",
+		"Unit": "ali_drw",
+		"Compat": "ali_drw_pmu"
+	}
+]
-- 
1.8.3.1
Re: [PATCH v2 5/5] perf vendor events: Add JSON metrics for Yitian 710 DDR
Posted by Shuai Xue 2 years, 9 months ago

On 2023/4/24 17:44, Jing Zhang wrote:
> Add JSON metrics for T-HEAD Yitian 710 SoC DDR.
> 
> Signed-off-by: Jing Zhang <renyu.zj@linux.alibaba.com>


Could you also update the Documentation/admin-guide/perf/alibaba_pmu.rst
with some example of how to use these metrics?

Best Regards,
Shuai


> ---
>  .../arch/arm64/freescale/yitian710/sys/metrics.json  | 20 ++++++++++++++++++++
>  1 file changed, 20 insertions(+)
>  create mode 100644 tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json
> 
> diff --git a/tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json b/tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json
> new file mode 100644
> index 0000000..1a92477
> --- /dev/null
> +++ b/tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json
> @@ -0,0 +1,20 @@
> +[
> +	{
> +		"MetricName": "ddr_read_bandwidth.all",
> +		"BriefDescription": "The ddr read bandwidth(MB/s).",
> +		"MetricGroup": "ddr",
> +		"MetricExpr": "hif_rd * 64 / 1e6 / duration_time",
> +		"ScaleUnit": "1MB/s",
> +		"Unit": "ali_drw",
> +		"Compat": "ali_drw_pmu"
> +	},
> +	{
> +		"MetricName": "ddr_write_bandwidth.all",
> +		"BriefDescription": "The ddr write bandwidth(MB/s).",
> +		"MetricGroup": "ddr",
> +		"MetricExpr": "(hif_wr + hif_rmw) * 64 / 1e6 / duration_time",
> +		"ScaleUnit": "1MB/s",
> +		"Unit": "ali_drw",
> +		"Compat": "ali_drw_pmu"
> +	}
> +]
Re: [PATCH v2 5/5] perf vendor events: Add JSON metrics for Yitian 710 DDR
Posted by Jing Zhang 2 years, 9 months ago

在 2023/5/4 下午3:31, Shuai Xue 写道:
> 
> 
> On 2023/4/24 17:44, Jing Zhang wrote:
>> Add JSON metrics for T-HEAD Yitian 710 SoC DDR.
>>
>> Signed-off-by: Jing Zhang <renyu.zj@linux.alibaba.com>
> 
> 
> Could you also update the Documentation/admin-guide/perf/alibaba_pmu.rst
> with some example of how to use these metrics?
> 

Yes,will do.

Thanks,
Jing


> Best Regards,
> Shuai
> 
> 
>> ---
>>  .../arch/arm64/freescale/yitian710/sys/metrics.json  | 20 ++++++++++++++++++++
>>  1 file changed, 20 insertions(+)
>>  create mode 100644 tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json
>>
>> diff --git a/tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json b/tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json
>> new file mode 100644
>> index 0000000..1a92477
>> --- /dev/null
>> +++ b/tools/perf/pmu-events/arch/arm64/freescale/yitian710/sys/metrics.json
>> @@ -0,0 +1,20 @@
>> +[
>> +	{
>> +		"MetricName": "ddr_read_bandwidth.all",
>> +		"BriefDescription": "The ddr read bandwidth(MB/s).",
>> +		"MetricGroup": "ddr",
>> +		"MetricExpr": "hif_rd * 64 / 1e6 / duration_time",
>> +		"ScaleUnit": "1MB/s",
>> +		"Unit": "ali_drw",
>> +		"Compat": "ali_drw_pmu"
>> +	},
>> +	{
>> +		"MetricName": "ddr_write_bandwidth.all",
>> +		"BriefDescription": "The ddr write bandwidth(MB/s).",
>> +		"MetricGroup": "ddr",
>> +		"MetricExpr": "(hif_wr + hif_rmw) * 64 / 1e6 / duration_time",
>> +		"ScaleUnit": "1MB/s",
>> +		"Unit": "ali_drw",
>> +		"Compat": "ali_drw_pmu"
>> +	}
>> +]
Re: [PATCH v2 5/5] perf vendor events: Add JSON metrics for Yitian 710 DDR
Posted by John Garry 2 years, 9 months ago
On 24/04/2023 10:44, Jing Zhang wrote:
> Add JSON metrics for T-HEAD Yitian 710 SoC DDR.
> 
> Signed-off-by: Jing Zhang<renyu.zj@linux.alibaba.com>

Reviewed-by: John Garry <john.g.garry@oracle.com>