[PATCH i-g-t 05/23] lib/xe/oa: Generate LNL metrics/registers files
Ashutosh Dixit
ashutosh.dixit at intel.com
Fri May 24 03:14:21 UTC 2024
Generate metrics/registers .c and .h files with the XE_OA_FORMAT_PEC64u64
format (called 576B_PEC64LL) used in MetricsXML_P31.xml.
Signed-off-by: Ashutosh Dixit <ashutosh.dixit at intel.com>
---
lib/xe/oa-configs/oa-metricset-codegen.py | 19 ++++++++++++++++---
1 file changed, 16 insertions(+), 3 deletions(-)
diff --git a/lib/xe/oa-configs/oa-metricset-codegen.py b/lib/xe/oa-configs/oa-metricset-codegen.py
index be9483af02..ea0d13cc97 100644
--- a/lib/xe/oa-configs/oa-metricset-codegen.py
+++ b/lib/xe/oa-configs/oa-metricset-codegen.py
@@ -116,7 +116,7 @@ def generate_metric_sets(args, gen):
if gen.chipset.startswith("acm") or gen.chipset.startswith("mtl"):
if set.oa_format == "128B_MPEC8_NOA16":
c(textwrap.dedent("""\
- metric_set->perf_oa_format = I915_OAM_FORMAT_MPEC8u32_B8_C8;
+ metric_set->perf_oa_format = XE_OAM_FORMAT_MPEC8u32_B8_C8;
metric_set->perf_raw_size = 128;
metric_set->gpu_time_offset = 0;
@@ -128,7 +128,7 @@ def generate_metric_sets(args, gen):
"""))
else:
c(textwrap.dedent("""\
- metric_set->perf_oa_format = I915_OA_FORMAT_A24u40_A14u32_B8_C8;
+ metric_set->perf_oa_format = XE_OA_FORMAT_A24u40_A14u32_B8_C8;
metric_set->perf_raw_size = 256;
metric_set->gpu_time_offset = 0;
@@ -138,9 +138,22 @@ def generate_metric_sets(args, gen):
metric_set->c_offset = metric_set->b_offset + 8;
metric_set->perfcnt_offset = metric_set->c_offset + 8;
"""))
+ elif gen.chipset == "lnl":
+ c(textwrap.dedent("""\
+ metric_set->perf_oa_format = XE_OA_FORMAT_PEC64u64;
+
+ metric_set->perf_raw_size = 576;
+ metric_set->gpu_time_offset = 0;
+ metric_set->gpu_clock_offset = 1;
+ metric_set->a_offset = 2;
+ // metric_set->b_offset = metric_set->a_offset + 38;
+ // metric_set->c_offset = metric_set->b_offset + 8;
+ metric_set->perfcnt_offset = metric_set->a_offset + 64;
+
+ """))
else:
c(textwrap.dedent("""\
- metric_set->perf_oa_format = I915_OA_FORMAT_A32u40_A4u32_B8_C8;
+ metric_set->perf_oa_format = XE_OA_FORMAT_A32u40_A4u32_B8_C8;
metric_set->perf_raw_size = 256;
metric_set->gpu_time_offset = 0;
--
2.41.0
More information about the igt-dev
mailing list