All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mika Kuoppala <mika.kuoppala@linux.intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, intel-gfx@lists.freedesktop.org
Cc: igt-dev@lists.freedesktop.org, Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Subject: Re: [igt-dev] [PATCH i-g-t] i915/gem_exec_balancer: Wait for both engines to complete before resubmitting
Date: Tue, 05 Nov 2019 13:34:23 +0200	[thread overview]
Message-ID: <87imnyo8u8.fsf@gaia.fi.intel.com> (raw)
In-Reply-To: <20191104201710.3778-1-chris@chris-wilson.co.uk>

Chris Wilson <chris@chris-wilson.co.uk> writes:

> As the scratch buf is shared between the two requests on both engines,
> we need to wait for both to finish using the buffer before we reset it.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> ---
>  tests/i915/gem_exec_balancer.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tests/i915/gem_exec_balancer.c b/tests/i915/gem_exec_balancer.c
> index e52f5df95..70c4529b4 100644
> --- a/tests/i915/gem_exec_balancer.c
> +++ b/tests/i915/gem_exec_balancer.c
> @@ -840,7 +840,7 @@ static void bonded_slice(int i915)
>  			gem_execbuf(i915, &eb);
>  			close(eb.rsvd2);
>  
> -			gem_sync(i915, obj[2].handle);
> +			gem_sync(i915, obj[0].handle);

Ok, let me try to make sense of it all. First off, the need for
obj[IGT_SPIN_SCRATCH].handle grows.

But as the semaphore will wait the spinner to start and then end it.
It is not enough to wait the semaphore batch to sync. That is clear.

But on syncing the scratch: the obj[1].handle is causing write
hazard to obj[0] so if we wait obj[0], then it is implied that
obj[1].handle has finished?

-Mika

>  		}
>  
>  		*stop = 1;
> -- 
> 2.24.0
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

WARNING: multiple messages have this Message-ID (diff)
From: Mika Kuoppala <mika.kuoppala@linux.intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, intel-gfx@lists.freedesktop.org
Cc: igt-dev@lists.freedesktop.org
Subject: Re: [PATCH i-g-t] i915/gem_exec_balancer: Wait for both engines to complete before resubmitting
Date: Tue, 05 Nov 2019 13:34:23 +0200	[thread overview]
Message-ID: <87imnyo8u8.fsf@gaia.fi.intel.com> (raw)
In-Reply-To: <20191104201710.3778-1-chris@chris-wilson.co.uk>

Chris Wilson <chris@chris-wilson.co.uk> writes:

> As the scratch buf is shared between the two requests on both engines,
> we need to wait for both to finish using the buffer before we reset it.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> ---
>  tests/i915/gem_exec_balancer.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tests/i915/gem_exec_balancer.c b/tests/i915/gem_exec_balancer.c
> index e52f5df95..70c4529b4 100644
> --- a/tests/i915/gem_exec_balancer.c
> +++ b/tests/i915/gem_exec_balancer.c
> @@ -840,7 +840,7 @@ static void bonded_slice(int i915)
>  			gem_execbuf(i915, &eb);
>  			close(eb.rsvd2);
>  
> -			gem_sync(i915, obj[2].handle);
> +			gem_sync(i915, obj[0].handle);

Ok, let me try to make sense of it all. First off, the need for
obj[IGT_SPIN_SCRATCH].handle grows.

But as the semaphore will wait the spinner to start and then end it.
It is not enough to wait the semaphore batch to sync. That is clear.

But on syncing the scratch: the obj[1].handle is causing write
hazard to obj[0] so if we wait obj[0], then it is implied that
obj[1].handle has finished?

-Mika

>  		}
>  
>  		*stop = 1;
> -- 
> 2.24.0
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

WARNING: multiple messages have this Message-ID (diff)
From: Mika Kuoppala <mika.kuoppala@linux.intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, intel-gfx@lists.freedesktop.org
Cc: igt-dev@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH i-g-t] i915/gem_exec_balancer: Wait for both engines to complete before resubmitting
Date: Tue, 05 Nov 2019 13:34:23 +0200	[thread overview]
Message-ID: <87imnyo8u8.fsf@gaia.fi.intel.com> (raw)
Message-ID: <20191105113423.nix1xUdRC7dMumKw62Dn3xEN6P-ZZz7WRDJFekszA-o@z> (raw)
In-Reply-To: <20191104201710.3778-1-chris@chris-wilson.co.uk>

Chris Wilson <chris@chris-wilson.co.uk> writes:

> As the scratch buf is shared between the two requests on both engines,
> we need to wait for both to finish using the buffer before we reset it.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> ---
>  tests/i915/gem_exec_balancer.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tests/i915/gem_exec_balancer.c b/tests/i915/gem_exec_balancer.c
> index e52f5df95..70c4529b4 100644
> --- a/tests/i915/gem_exec_balancer.c
> +++ b/tests/i915/gem_exec_balancer.c
> @@ -840,7 +840,7 @@ static void bonded_slice(int i915)
>  			gem_execbuf(i915, &eb);
>  			close(eb.rsvd2);
>  
> -			gem_sync(i915, obj[2].handle);
> +			gem_sync(i915, obj[0].handle);

Ok, let me try to make sense of it all. First off, the need for
obj[IGT_SPIN_SCRATCH].handle grows.

But as the semaphore will wait the spinner to start and then end it.
It is not enough to wait the semaphore batch to sync. That is clear.

But on syncing the scratch: the obj[1].handle is causing write
hazard to obj[0] so if we wait obj[0], then it is implied that
obj[1].handle has finished?

-Mika

>  		}
>  
>  		*stop = 1;
> -- 
> 2.24.0
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  parent reply	other threads:[~2019-11-05 11:34 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-04 20:17 [igt-dev] [PATCH i-g-t] i915/gem_exec_balancer: Wait for both engines to complete before resubmitting Chris Wilson
2019-11-04 20:17 ` [Intel-gfx] " Chris Wilson
2019-11-04 20:17 ` Chris Wilson
2019-11-04 20:57 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2019-11-05  7:36 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2019-11-05 11:34 ` Mika Kuoppala [this message]
2019-11-05 11:34   ` [Intel-gfx] [PATCH i-g-t] " Mika Kuoppala
2019-11-05 11:34   ` Mika Kuoppala
2019-11-05 11:39   ` [igt-dev] " Chris Wilson
2019-11-05 11:39     ` [Intel-gfx] " Chris Wilson
2019-11-05 11:39     ` Chris Wilson
2019-11-05 11:46     ` [igt-dev] " Mika Kuoppala
2019-11-05 11:46       ` [Intel-gfx] " Mika Kuoppala
2019-11-05 11:46       ` Mika Kuoppala
2019-11-05 11:48       ` [igt-dev] " Chris Wilson
2019-11-05 11:48         ` [Intel-gfx] " Chris Wilson
2019-11-05 11:48         ` Chris Wilson

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=87imnyo8u8.fsf@gaia.fi.intel.com \
    --to=mika.kuoppala@linux.intel.com \
    --cc=chris@chris-wilson.co.uk \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=tvrtko.ursulin@intel.com \
    /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.