[i-g-t,2/2] tests/kms_flip: Change 2x tests execution order

Submitted by Mika Kahola on June 12, 2018, 11:19 a.m.

Details

Message ID 1528802370-18478-3-git-send-email-mika.kahola@intel.com
State New
Headers show
Series "tests/kms_flip: Binary mode optimizations" ( rev: 2 1 ) in IGT

Not browsing as part of any series.

Commit Message

Mika Kahola June 12, 2018, 11:19 a.m.
In order to optimize execution of kms_flip binary mode tests, let's change
the execution order so that 2x tests will be executed after basic tests.

On GLK platform the normal run with 1 display takes x seconds. With this patch
applied the exection time reduced to x seconds even though 2x tests were skipped
due to lack of second monitor.

Signed-off-by: Mika Kahola <mika.kahola@intel.com>
---
 tests/kms_flip.c | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/tests/kms_flip.c b/tests/kms_flip.c
index 09aaac2..511ed8c 100644
--- a/tests/kms_flip.c
+++ b/tests/kms_flip.c
@@ -1635,7 +1635,9 @@  int main(int argc, char **argv)
 			      tests[i].flags & TEST_BASIC ? "basic-" : "",
 			      tests[i].name)
 			run_test(opt.duration, tests[i].flags);
+	}
 
+	for (i = 0; i < sizeof(tests) / sizeof (tests[0]); i++) {
 		if (tests[i].flags & TEST_NO_2X_OUTPUT)
 			continue;
 
@@ -1657,8 +1659,13 @@  int main(int argc, char **argv)
 
 		igt_subtest_f( "%s-interruptible", tests[i].name)
 			run_test(opt.duration, tests[i].flags);
+	}
 
-		if (tests[i].flags & TEST_NO_2X_OUTPUT)
+	for (i = 0; i < sizeof(tests) / sizeof (tests[0]); i++) {
+		/* relative blocking vblank waits that get constantly interrupt
+		 * take forver. So don't do them. */
+		if ((tests[i].flags & TEST_VBLANK_BLOCK) &&
+		    !(tests[i].flags & TEST_VBLANK_ABSOLUTE))
 			continue;
 
 		/* code doesn't disable all crtcs, so skip rpm tests */

Comments

On Tue, Jun 12, 2018 at 02:19:30PM +0300, Mika Kahola wrote:
> In order to optimize execution of kms_flip binary mode tests, let's change
> the execution order so that 2x tests will be executed after basic tests.
> 
> On GLK platform the normal run with 1 display takes x seconds. With this patch
> applied the exection time reduced to x seconds even though 2x tests were skipped
> due to lack of second monitor.

Reduced from x seconds to x seconds?
On Wed, 2018-06-13 at 14:05 +0300, Petri Latvala wrote:
> On Tue, Jun 12, 2018 at 02:19:30PM +0300, Mika Kahola wrote:
> > 
> > In order to optimize execution of kms_flip binary mode tests, let's
> > change
> > the execution order so that 2x tests will be executed after basic
> > tests.
> > 
> > On GLK platform the normal run with 1 display takes x seconds. With
> > this patch
> > applied the exection time reduced to x seconds even though 2x tests
> > were skipped
> > due to lack of second monitor.
> Reduced from x seconds to x seconds?
Oops, I forgot to add the actual test result.

> 
>