All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t] gem_bad_reloc: Don't flip-flop between SKIP and PASS
@ 2014-12-04 13:58 Damien Lespiau
  2014-12-04 14:05 ` Damien Lespiau
  2014-12-04 16:18 ` Chris Wilson
  0 siblings, 2 replies; 4+ messages in thread
From: Damien Lespiau @ 2014-12-04 13:58 UTC (permalink / raw)
  To: intel-gfx

Here is a cheap way for this test to give consistent results. This
doesn't change the usefulness of this test, hopefully.

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
---
 tests/gem_bad_reloc.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/tests/gem_bad_reloc.c b/tests/gem_bad_reloc.c
index df0100f..ef6b52a 100644
--- a/tests/gem_bad_reloc.c
+++ b/tests/gem_bad_reloc.c
@@ -87,7 +87,13 @@ static int negative_reloc(int fd, unsigned flags)
 	gem_close(fd, gem_exec[1].handle);
 
 	igt_info("Found offset %ld for 4k batch\n", (long)gem_exec[0].offset);
-	igt_require(gem_exec[0].offset < BIAS);
+	/*
+	 * Ideally we'd like to be able to control where the kernel is going to
+	 * place the buffer. We don't SKIP here because it causes the test
+	 * to "randomly" flip-flop between the SKIP and PASS states.
+	 */
+	if (gem_exec[0].offset < BIAS)
+		return 0;
 
 	memset(gem_reloc, 0, sizeof(gem_reloc));
 	for (i = 0; i < sizeof(gem_reloc)/sizeof(gem_reloc[0]); i++) {
-- 
1.8.3.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH i-g-t] gem_bad_reloc: Don't flip-flop between SKIP and PASS
  2014-12-04 13:58 [PATCH i-g-t] gem_bad_reloc: Don't flip-flop between SKIP and PASS Damien Lespiau
@ 2014-12-04 14:05 ` Damien Lespiau
  2014-12-04 16:18 ` Chris Wilson
  1 sibling, 0 replies; 4+ messages in thread
From: Damien Lespiau @ 2014-12-04 14:05 UTC (permalink / raw)
  To: intel-gfx

On Thu, Dec 04, 2014 at 01:58:54PM +0000, Damien Lespiau wrote:
> Here is a cheap way for this test to give consistent results. This
> doesn't change the usefulness of this test, hopefully.
> 
> Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>

And:

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=85270

-- 
Damien
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH i-g-t] gem_bad_reloc: Don't flip-flop between SKIP and PASS
  2014-12-04 13:58 [PATCH i-g-t] gem_bad_reloc: Don't flip-flop between SKIP and PASS Damien Lespiau
  2014-12-04 14:05 ` Damien Lespiau
@ 2014-12-04 16:18 ` Chris Wilson
  2014-12-04 16:40   ` Damien Lespiau
  1 sibling, 1 reply; 4+ messages in thread
From: Chris Wilson @ 2014-12-04 16:18 UTC (permalink / raw)
  To: Damien Lespiau; +Cc: intel-gfx

On Thu, Dec 04, 2014 at 01:58:54PM +0000, Damien Lespiau wrote:
> Here is a cheap way for this test to give consistent results. This
> doesn't change the usefulness of this test, hopefully.
> 
> Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
> ---
>  tests/gem_bad_reloc.c | 8 +++++++-
>  1 file changed, 7 insertions(+), 1 deletion(-)
> 
> diff --git a/tests/gem_bad_reloc.c b/tests/gem_bad_reloc.c
> index df0100f..ef6b52a 100644
> --- a/tests/gem_bad_reloc.c
> +++ b/tests/gem_bad_reloc.c
> @@ -87,7 +87,13 @@ static int negative_reloc(int fd, unsigned flags)
>  	gem_close(fd, gem_exec[1].handle);
>  
>  	igt_info("Found offset %ld for 4k batch\n", (long)gem_exec[0].offset);
> -	igt_require(gem_exec[0].offset < BIAS);
> +	/*
> +	 * Ideally we'd like to be able to control where the kernel is going to
> +	 * place the buffer. We don't SKIP here because it causes the test
> +	 * to "randomly" flip-flop between the SKIP and PASS states.
> +	 */

Riddle me thus: the test scripts try to ensure that every test run has
the identical environment. Yet between runs we have different layouts of
framebuffer objects...

To improve this test, what you could actually try is disabling all
CRTCs. That should give consistent results.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH i-g-t] gem_bad_reloc: Don't flip-flop between SKIP and PASS
  2014-12-04 16:18 ` Chris Wilson
@ 2014-12-04 16:40   ` Damien Lespiau
  0 siblings, 0 replies; 4+ messages in thread
From: Damien Lespiau @ 2014-12-04 16:40 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx

On Thu, Dec 04, 2014 at 04:18:39PM +0000, Chris Wilson wrote:
> On Thu, Dec 04, 2014 at 01:58:54PM +0000, Damien Lespiau wrote:
> > Here is a cheap way for this test to give consistent results. This
> > doesn't change the usefulness of this test, hopefully.
> > 
> > Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
> > ---
> >  tests/gem_bad_reloc.c | 8 +++++++-
> >  1 file changed, 7 insertions(+), 1 deletion(-)
> > 
> > diff --git a/tests/gem_bad_reloc.c b/tests/gem_bad_reloc.c
> > index df0100f..ef6b52a 100644
> > --- a/tests/gem_bad_reloc.c
> > +++ b/tests/gem_bad_reloc.c
> > @@ -87,7 +87,13 @@ static int negative_reloc(int fd, unsigned flags)
> >  	gem_close(fd, gem_exec[1].handle);
> >  
> >  	igt_info("Found offset %ld for 4k batch\n", (long)gem_exec[0].offset);
> > -	igt_require(gem_exec[0].offset < BIAS);
> > +	/*
> > +	 * Ideally we'd like to be able to control where the kernel is going to
> > +	 * place the buffer. We don't SKIP here because it causes the test
> > +	 * to "randomly" flip-flop between the SKIP and PASS states.
> > +	 */
> 
> Riddle me thus: the test scripts try to ensure that every test run has
> the identical environment. Yet between runs we have different layouts of
> framebuffer objects...
> 
> To improve this test, what you could actually try is disabling all
> CRTCs. That should give consistent results.

I actually didn't manage to reproduce the erratic behaviour described in
the bug. So maybe we've already fixed what caused the flip-flopping in
the first place. Or maybe I can't reproduce it because I'm running in a
clean environment wihout having run a few dozen kms tests beforehand.

In any case, I'd rather go for the quick option that doesn't make the
worse in a too awful way and is won't regress (it's also less work, I'm
lazy).

-- 
Damien
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-12-04 16:52 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-12-04 13:58 [PATCH i-g-t] gem_bad_reloc: Don't flip-flop between SKIP and PASS Damien Lespiau
2014-12-04 14:05 ` Damien Lespiau
2014-12-04 16:18 ` Chris Wilson
2014-12-04 16:40   ` Damien Lespiau

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.