Thread (7 messages) 7 messages, 4 authors, 2021-03-26

Re: [igt-dev] [i-g-t v2] tests/i915/perf: Added check for testcase to get discarded on less than gen12 platform

From: Lionel Landwerlin <hidden>
Date: 2021-03-26 10:08:27

On 26/03/2021 11:03, Anand Moon wrote:
quoted hunk ↗ jump to hunk
Added check for testcase to get discarded on less than gen12 platform

v2: Added check in gen12 sub testcase to return.

Cc: Lionel Landwerlin <redacted>
Cc: Umesh Nerlige Ramappa <redacted>
Signed-off-by: Anand Moon <redacted>
---
  tests/i915/perf.c | 11 +++++++++--
  1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/tests/i915/perf.c b/tests/i915/perf.c
index 664fd0a9..b78a714e 100644
--- a/tests/i915/perf.c
+++ b/tests/i915/perf.c
@@ -2389,6 +2389,9 @@ gen12_test_oa_tlb_invalidate(void)
  	int num_reports1, num_reports2, num_expected_reports;
  	int64_t duration;
  
+	if (intel_gen(devid) < 12)
+		return;
+
  	/* Capture reports for 5 seconds twice and then make sure you get around
  	 * the same number of reports. In the case of failure, the number of
  	 * reports will vary largely since the beginning of the OA buffer
@@ -3003,6 +3006,9 @@ gen12_test_mi_rpc(void)
  	size_t format_size_32;
  	struct oa_format format = get_oa_format(test_set->perf_oa_format);
  
+	if (intel_gen(devid) < 12)
+		return;
+
  	/* Ensure perf_stream_paranoid is set to 1 by default */
  	write_u64_file("/proc/sys/dev/i915/perf_stream_paranoid", 1);
  
@@ -4115,6 +4121,9 @@ gen12_test_single_ctx_render_target_writes_a_counter(void)
  	int child_ret;
  	struct igt_helper_process child = {};
  
+	if (intel_gen(devid) < 12)
+		return;
+
  	/* Ensure perf_stream_paranoid is set to 1 by default */
  	write_u64_file("/proc/sys/dev/i915/perf_stream_paranoid", 1);
  
@@ -5062,8 +5071,6 @@ igt_main
  	}
  
  	igt_subtest_group {
-		igt_fixture igt_require(intel_gen(devid) >= 12);
-
  		igt_describe("Test MI REPORT PERF COUNT for Gen 12");
  		igt_subtest("gen12-mi-rpc")
  			gen12_test_mi_rpc();
Could you maybe explain how those tests are run on gen < 12 when there 
is a igt_fixture igt_require(intel_gen(devid) >= 12); that is supposed 
to prevent that from happening?


Thanks,


-Lionel

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help