[igt-dev] [PATCH i-g-t] tests/i915/gem_render_copy_redux: reduce looping if on simulation

Juha-Pekka Heikkila juhapekka.heikkila at gmail.com
Tue Jan 25 14:29:20 UTC 2022


On simulation it's interesting plumbing generally works and don't
waste time executing long loops.

Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila at gmail.com>
---
 tests/i915/gem_render_copy_redux.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/tests/i915/gem_render_copy_redux.c b/tests/i915/gem_render_copy_redux.c
index 6c8d7f755..0ef482b99 100644
--- a/tests/i915/gem_render_copy_redux.c
+++ b/tests/i915/gem_render_copy_redux.c
@@ -207,13 +207,13 @@ igt_main
 	}
 
 	igt_subtest("normal") {
-		int loop = 100;
+		int loop = igt_run_in_simulation() ? 3 : 100;
 		while (loop--)
 			copy(&data);
 	}
 
 	igt_subtest("interruptible") {
-		int loop = 100;
+		int loop = igt_run_in_simulation() ? 3 : 100;
 		igt_fork_signal_helper();
 		while (loop--)
 			copy(&data);
@@ -221,13 +221,13 @@ igt_main
 	}
 
 	igt_subtest("flink") {
-		int loop = 100;
+		int loop = igt_run_in_simulation() ? 3 : 100;
 		while (loop--)
 			copy_flink(&data);
 	}
 
 	igt_subtest("flink-interruptible") {
-		int loop = 100;
+		int loop = igt_run_in_simulation() ? 3 : 100;
 		igt_fork_signal_helper();
 		while (loop--)
 			copy_flink(&data);
-- 
2.28.0



More information about the igt-dev mailing list