public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Nidhi Gupta <nidhi1.gupta@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: Nidhi Gupta <nidhi1.gupta@intel.com>
Subject: [igt-dev] [PATCH i-g-t 4/6] tests/kms_plane_scaling: Restrict the execution of subtest to single pipe
Date: Mon,  9 Jan 2023 19:10:44 +0530	[thread overview]
Message-ID: <20230109134046.85340-5-nidhi1.gupta@intel.com> (raw)
In-Reply-To: <20230109134046.85340-1-nidhi1.gupta@intel.com>

To reduce the overall execution time of the test, now
all the subtests will be executed on single pipe instead
of all the pipes.

Signed-off-by: Nidhi Gupta <nidhi1.gupta@intel.com>
---
 tests/kms_plane_scaling.c | 113 ++++++++++++++++++++++----------------
 1 file changed, 67 insertions(+), 46 deletions(-)

diff --git a/tests/kms_plane_scaling.c b/tests/kms_plane_scaling.c
index 887a55e6..755b4684 100644
--- a/tests/kms_plane_scaling.c
+++ b/tests/kms_plane_scaling.c
@@ -860,17 +860,20 @@ igt_main_args("", long_opts, help_str, opt_handler, &data)
 		for (int index = 0; index < ARRAY_SIZE(scaler_with_pixel_format_tests); index++) {
 			igt_describe(scaler_with_pixel_format_tests[index].describe);
 			igt_subtest_with_dynamic(scaler_with_pixel_format_tests[index].name) {
-			for_each_pipe_with_single_output(&data.display, pipe, output)
-				igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output)) {
-					drmModeModeInfo *mode;
-
-					mode = igt_output_get_mode(output);
-
-					test_scaler_with_pixel_format_pipe(&data,
-							get_width(mode, scaler_with_pixel_format_tests[index].sf),
-							get_height(mode, scaler_with_pixel_format_tests[index].sf),
-							scaler_with_pixel_format_tests[index].is_upscale,
-							pipe, output);
+				for_each_pipe_with_single_output(&data.display, pipe, output) {
+					igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output)) {
+						drmModeModeInfo *mode;
+
+						mode = igt_output_get_mode(output);
+
+						test_scaler_with_pixel_format_pipe(&data,
+								get_width(mode, scaler_with_pixel_format_tests[index].sf),
+								get_height(mode, scaler_with_pixel_format_tests[index].sf),
+								scaler_with_pixel_format_tests[index].is_upscale,
+								pipe, output);
+					}
+					/*Restrict the execution of subtest to single pipe*/
+					break;
 				}
 			}
 		}
@@ -878,17 +881,20 @@ igt_main_args("", long_opts, help_str, opt_handler, &data)
 		for (int index = 0; index < ARRAY_SIZE(scaler_with_rotation_tests); index++) {
 			igt_describe(scaler_with_rotation_tests[index].describe);
 			igt_subtest_with_dynamic(scaler_with_rotation_tests[index].name) {
-			for_each_pipe_with_single_output(&data.display, pipe, output)
-				igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output)) {
-					drmModeModeInfo *mode;
-
-					mode = igt_output_get_mode(output);
-
-					test_scaler_with_rotation_pipe(&data,
-							get_width(mode, scaler_with_rotation_tests[index].sf),
-							get_height(mode, scaler_with_rotation_tests[index].sf),
-							scaler_with_rotation_tests[index].is_upscale,
-							pipe, output);
+				for_each_pipe_with_single_output(&data.display, pipe, output) {
+					igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output)) {
+						drmModeModeInfo *mode;
+
+						mode = igt_output_get_mode(output);
+
+						test_scaler_with_rotation_pipe(&data,
+								get_width(mode, scaler_with_rotation_tests[index].sf),
+								get_height(mode, scaler_with_rotation_tests[index].sf),
+								scaler_with_rotation_tests[index].is_upscale,
+								pipe, output);
+					}
+					/*Restrict the execution of subtest to single pipe*/
+					break;
 				}
 			}
 		}
@@ -896,17 +902,20 @@ igt_main_args("", long_opts, help_str, opt_handler, &data)
 		for (int index = 0; index < ARRAY_SIZE(scaler_with_modifiers_tests); index++) {
 			igt_describe(scaler_with_modifiers_tests[index].describe);
 			igt_subtest_with_dynamic(scaler_with_modifiers_tests[index].name) {
-			for_each_pipe_with_single_output(&data.display, pipe, output)
-				igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output)) {
-					drmModeModeInfo *mode;
-
-					mode = igt_output_get_mode(output);
-
-					test_scaler_with_modifier_pipe(&data,
-							get_width(mode, scaler_with_rotation_tests[index].sf),
-							get_height(mode, scaler_with_rotation_tests[index].sf),
-							scaler_with_rotation_tests[index].is_upscale,
-							pipe, output);
+				for_each_pipe_with_single_output(&data.display, pipe, output) {
+					igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output)) {
+						drmModeModeInfo *mode;
+
+						mode = igt_output_get_mode(output);
+
+						test_scaler_with_modifier_pipe(&data,
+								get_width(mode, scaler_with_rotation_tests[index].sf),
+								get_height(mode, scaler_with_rotation_tests[index].sf),
+								scaler_with_rotation_tests[index].is_upscale,
+								pipe, output);
+					}
+					/*Restrict the execution of subtest to single pipe*/
+					break;
 				}
 			}
 		}
@@ -921,6 +930,8 @@ igt_main_args("", long_opts, help_str, opt_handler, &data)
 				igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output))
 					test_scaler_with_pixel_format_pipe(&data, mode->hdisplay + 100,
 							mode->vdisplay + 100, false, pipe, output);
+				/*Restrict the execution of subtest to single pipe*/
+				break;
 			}
 		}
 
@@ -934,6 +945,8 @@ igt_main_args("", long_opts, help_str, opt_handler, &data)
 				igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output))
 					test_scaler_with_rotation_pipe(&data, mode->hdisplay + 100,
 							mode->vdisplay + 100, false, pipe, output);
+				/*Restrict the execution of subtest to single pipe*/
+				break;
 			}
 		}
 
@@ -947,34 +960,42 @@ igt_main_args("", long_opts, help_str, opt_handler, &data)
 				igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output))
 					test_scaler_with_modifier_pipe(&data, mode->hdisplay + 100,
 							mode->vdisplay + 100, false, pipe, output);
+				/*Restrict the execution of subtest to single pipe*/
+				break;
 			}
 		}
 
 		for (int index = 0; index < ARRAY_SIZE(scaler_with_2_planes_tests); index++) {
 			igt_describe(scaler_with_2_planes_tests[index].describe);
 			igt_subtest_with_dynamic(scaler_with_2_planes_tests[index].name) {
-			for_each_pipe_with_single_output(&data.display, pipe, output)
-				igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output)) {
-					drmModeModeInfo *mode;
-
-					mode = igt_output_get_mode(output);
-
-					test_planes_scaling_combo(&data,
-							get_width(mode, scaler_with_2_planes_tests[index].sf_plane1),
-							get_height(mode, scaler_with_2_planes_tests[index].sf_plane1),
-							get_width(mode, scaler_with_2_planes_tests[index].sf_plane2),
-							get_height(mode, scaler_with_2_planes_tests[index].sf_plane2),
-							pipe, output, scaler_with_2_planes_tests[index].test_type);
+				for_each_pipe_with_single_output(&data.display, pipe, output) {
+					igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output)) {
+						drmModeModeInfo *mode;
+
+						mode = igt_output_get_mode(output);
+
+						test_planes_scaling_combo(&data,
+								get_width(mode, scaler_with_2_planes_tests[index].sf_plane1),
+								get_height(mode, scaler_with_2_planes_tests[index].sf_plane1),
+								get_width(mode, scaler_with_2_planes_tests[index].sf_plane2),
+								get_height(mode, scaler_with_2_planes_tests[index].sf_plane2),
+								pipe, output, scaler_with_2_planes_tests[index].test_type);
+					}
+					/*Restrict the execution of subtest to single pipe*/
+					break;
 				}
 			}
 		}
 
 		igt_describe("Negative test for number of scalers per pipe.");
 		igt_subtest_with_dynamic("invalid-num-scalers") {
-			for_each_pipe_with_valid_output(&data.display, pipe, output)
+			for_each_pipe_with_valid_output(&data.display, pipe, output) {
 				igt_dynamic_f("pipe-%s-%s-invalid-num-scalers",
 					       kmstest_pipe_name(pipe), igt_output_name(output))
 					test_invalid_num_scalers(&data, pipe, output);
+				/*Restrict the execution of subtest to single pipe*/
+				break;
+			}
 		}
 	}
 
-- 
2.25.1

  parent reply	other threads:[~2023-01-09 13:42 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-09 13:40 [igt-dev] [PATCH i-g-t 0/6] Modified few kms tests to reduce execution time Nidhi Gupta
2023-01-09 13:40 ` [igt-dev] [PATCH i-g-t 1/6] tests/i915/kms_mmap_write_crc: Restrict the number of iteration to reduce the " Nidhi Gupta
2023-01-09 13:40 ` [igt-dev] [PATCH i-g-t 2/6] tests/kms_plane_alpha_blend: Restrict the execution of subtest to single pipe Nidhi Gupta
2023-01-09 13:40 ` [igt-dev] [PATCH i-g-t 3/6] tests/kms_color: Restrict the execution of subtests " Nidhi Gupta
2023-01-09 13:40 ` Nidhi Gupta [this message]
2023-01-09 13:40 ` [igt-dev] [PATCH i-g-t 5/6] tests/kms_pipe_crc_basic: Restrict the execution of subtest " Nidhi Gupta
2023-01-09 13:40 ` [igt-dev] [PATCH i-g-t 6/6] tests/kms_async_flips: Restrict the execution of the " Nidhi Gupta
2023-01-09 18:04 ` [igt-dev] ✓ Fi.CI.BAT: success for Modified few kms tests to reduce execution time Patchwork
2023-01-10  0:23 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230109134046.85340-5-nidhi1.gupta@intel.com \
    --to=nidhi1.gupta@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox