All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mika Kahola <mika.kahola@intel.com>
To: igt-dev@lists.freedesktop.org
Subject: [igt-dev] [PATCH i-g-t] tests/kms_plane_multiple: Limit plane testing to 3 planes by default
Date: Tue,  8 Jun 2021 15:47:39 +0300	[thread overview]
Message-ID: <20210608124739.1113321-1-mika.kahola@intel.com> (raw)

To speed up test execution, let's limit planes to be tested to 3
by default. This reduces the test execution time especially in case
of platforms that offer higher number of overlay planes.

For example, the subtest atomic-pipe-A-tiling-x the execution times
on ADL-P

With 6 planes:
Testing connector eDP-1 using pipe A with 6 planes for 1 iteration with seed 1
Subtest atomic-pipe-A-tiling-x: SUCCESS (2,168s)

With 3 planes:
Testing connector eDP-1 using pipe A with 3 planes for 1 iteration with seed 1
Subtest atomic-pipe-A-tiling-x: SUCCESS (1,878s)

The downside of this is of course the reduced test coverage as all
available planes are not tested by default simultaneusly.

For VLK-11391

Signed-off-by: Mika Kahola <mika.kahola@intel.com>
---
 tests/kms_plane_multiple.c | 13 +++++++++++--
 1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/tests/kms_plane_multiple.c b/tests/kms_plane_multiple.c
index 93c6ea7d2..f177aac8a 100644
--- a/tests/kms_plane_multiple.c
+++ b/tests/kms_plane_multiple.c
@@ -35,6 +35,7 @@ IGT_TEST_DESCRIPTION("Test atomic mode setting with multiple planes.");
 #define SIZE_PLANE      256
 #define SIZE_CURSOR     128
 #define LOOP_FOREVER     -1
+#define DEFAULT_N_PLANES  3
 
 typedef struct {
 	float red;
@@ -56,8 +57,10 @@ struct {
 	int iterations;
 	unsigned int seed;
 	bool user_seed;
+	bool all_planes;
 } opt = {
 	.iterations = 1,
+	.all_planes = false,
 };
 
 /*
@@ -358,7 +361,8 @@ static void
 test_plane_position(data_t *data, enum pipe pipe, uint64_t tiling)
 {
 	igt_output_t *output;
-	int n_planes = data->display.pipes[pipe].n_planes;
+	int n_planes = opt.all_planes ?
+			data->display.pipes[pipe].n_planes : DEFAULT_N_PLANES;
 
 	output = igt_get_single_output_for_pipe(&data->display, pipe);
 	igt_require(output);
@@ -398,6 +402,9 @@ static data_t data;
 static int opt_handler(int option, int option_index, void *input)
 {
 	switch (option) {
+	case 'a':
+		opt.all_planes = true;
+		break;
 	case 'i':
 		opt.iterations = strtol(optarg, NULL, 0);
 
@@ -420,11 +427,13 @@ static int opt_handler(int option, int option_index, void *input)
 
 const char *help_str =
 	"  --iterations Number of iterations for test coverage. -1 loop forever, default 64 iterations\n"
-	"  --seed       Seed for random number generator\n";
+	"  --seed       Seed for random number generator\n"
+	"  --all-planes Test with all available planes";
 
 struct option long_options[] = {
 	{ "iterations", required_argument, NULL, 'i'},
 	{ "seed",    required_argument, NULL, 's'},
+	{ "all-planes", no_argument, NULL, 'a'},
 	{ 0, 0, 0, 0 }
 };
 
-- 
2.27.0

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

             reply	other threads:[~2021-06-08 12:46 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-08 12:47 Mika Kahola [this message]
2021-06-08 13:34 ` [igt-dev] ✓ Fi.CI.BAT: success for tests/kms_plane_multiple: Limit plane testing to 3 planes by default Patchwork
2021-06-08 17:54 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2021-08-13  7:38 [igt-dev] [PATCH i-g-t] " Mika Kahola
2021-08-13 10:48 ` Juha-Pekka Heikkila
2021-08-13 10:53 ` Karthik B S

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=20210608124739.1113321-1-mika.kahola@intel.com \
    --to=mika.kahola@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.