From: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 11/25] drm/i915: Spin after waking up for an interrupt
Date: Tue, 28 Jun 2016 10:25:51 +0100 [thread overview]
Message-ID: <5772429F.6060001@linux.intel.com> (raw)
In-Reply-To: <20160628091738.GI25424@nuc-i3427.alporthouse.com>
On 28/06/16 10:17, Chris Wilson wrote:
> On Tue, Jun 28, 2016 at 09:55:17AM +0100, Chris Wilson wrote:
>> On Mon, Jun 27, 2016 at 11:32:10AM +0100, Tvrtko Ursulin wrote:
>>>
>>> On 25/06/16 11:12, Chris Wilson wrote:
>>>> When waiting for an interrupt (waiting for the GPU to complete some
>>>> work), we know we are the single waiter for the GPU. We also know when
>>>
>>> You mean we know we were the first waiter, if we have been woken up?
>>> Or perhaps the single waiter for this request? (more or less, maybe
>>> close enough) Or also s/", we know we are/, and we know we are" ?
>>
>> Single waiter for the engine. s/and//; it follows from and is not
>> conditional. To be here we know we are the only piece of code performing
>> this check. There may be threads entering i915_wait_request that also
>> get to spin before adding themselves to the waitqueue, but of all waiters,
>> we are the only one allowed to spin on this engine.
>
> Changed to:
>
> When waiting for an interrupt (waiting for the engine to complete some
> work), we know we are the only waiter to be woken on this engine. We also
> know when the GPU has nearly completed our request (or at least started
> processing it), so after being woken and we detect that the GPU is
> active and working on our request, allow us the bottom-half (the first
> waiter who wakes up to handle checking the seqno after the interrupt) to
> spin for a very short while to reduce client latencies.
>
> The impact is minimal, there was an improvement to the realtime-vs-many
> clients case, but exporting the function proves useful later. However,
> it is tempting to adjust irq_seqno_barrier to include the spin. The
> problem is first ensuring that the "start-of-request" seqno is coherent
> as we use that as our basis for judging when it is ok to spin. If we
> could, spinning there could dramatically shorten some sleeps, and allow
> us to make the barriers more conservative to handle missed seqno writes
> on more platforms (all gen7+ are known to have the occasional issue, at
> least).
Super clear now;
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Regards,
Tvrtko
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2016-06-28 9:25 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-25 10:12 A trail of breadcrumbs Chris Wilson
2016-06-25 10:12 ` [PATCH 01/25] drm/i915: Preserve current RPS frequency across init Chris Wilson
2016-06-25 10:12 ` [PATCH 02/25] drm/i915: Remove superfluous powersave work flushing Chris Wilson
2016-06-25 10:12 ` [PATCH 03/25] drm/i915: Defer enabling rc6 til after we submit the first batch/context Chris Wilson
2016-06-25 10:12 ` [PATCH 04/25] drm: Restore double clflush on the last partial cacheline Chris Wilson
2016-06-25 10:12 ` [PATCH 05/25] drm/i915/shrinker: Flush active on objects before counting Chris Wilson
2016-06-25 10:12 ` [PATCH 06/25] drm/i915: Delay queuing hangcheck to wait-request Chris Wilson
2016-06-25 10:12 ` [PATCH 07/25] drm/i915: Remove the dedicated hangcheck workqueue Chris Wilson
2016-06-25 10:12 ` [PATCH 08/25] drm/i915: Make queueing the hangcheck work inline Chris Wilson
2016-06-25 10:12 ` [PATCH 09/25] drm/i915: Separate GPU hang waitqueue from advance Chris Wilson
2016-06-25 10:12 ` [PATCH 10/25] drm/i915: Slaughter the thundering i915_wait_request herd Chris Wilson
2016-06-25 10:12 ` [PATCH 11/25] drm/i915: Spin after waking up for an interrupt Chris Wilson
2016-06-27 10:32 ` Tvrtko Ursulin
2016-06-28 8:55 ` Chris Wilson
2016-06-28 9:17 ` Chris Wilson
2016-06-28 9:25 ` Tvrtko Ursulin [this message]
2016-06-25 10:12 ` [PATCH 12/25] drm/i915: Use HWS for seqno tracking everywhere Chris Wilson
2016-06-25 10:12 ` [PATCH 13/25] drm/i915: Stop mapping the scratch page into CPU space Chris Wilson
2016-06-25 10:12 ` [PATCH 14/25] drm/i915: Allocate scratch page from stolen Chris Wilson
2016-06-25 10:12 ` [PATCH 15/25] drm/i915: Refactor scratch object allocation for gen2 w/a buffer Chris Wilson
2016-06-25 10:12 ` [PATCH 16/25] drm/i915: Add a delay between interrupt and inspecting the final seqno (ilk) Chris Wilson
2016-06-25 10:13 ` [PATCH 17/25] drm/i915: Check the CPU cached value in HWS of seqno after waking the waiter Chris Wilson
2016-06-25 10:13 ` [PATCH 18/25] drm/i915: Only apply one barrier after a breadcrumb interrupt is posted Chris Wilson
2016-06-27 10:35 ` Tvrtko Ursulin
2016-06-25 10:13 ` [PATCH 19/25] drm/i915: Stop setting wraparound seqno on initialisation Chris Wilson
2016-06-25 10:13 ` [PATCH 20/25] drm/i915: Only query timestamp when measuring elapsed time Chris Wilson
2016-06-27 10:37 ` Tvrtko Ursulin
2016-06-25 10:13 ` [PATCH 21/25] drm/i915: Convert trace-irq to the breadcrumb waiter Chris Wilson
2016-06-27 11:38 ` Tvrtko Ursulin
2016-06-28 8:49 ` Chris Wilson
2016-06-25 10:13 ` [PATCH 22/25] drm/i915: Embed signaling node into the GEM request Chris Wilson
2016-06-27 11:54 ` Tvrtko Ursulin
2016-06-25 10:13 ` [PATCH 23/25] drm/i915: Move the get/put irq locking into the caller Chris Wilson
2016-06-27 12:11 ` Tvrtko Ursulin
2016-06-28 8:42 ` Chris Wilson
2016-06-25 10:13 ` [PATCH 24/25] drm/i915: Simplify enabling user-interrupts with L3-remapping Chris Wilson
2016-06-25 10:13 ` [PATCH 25/25] drm/i915: Remove debug noise on detecting fault-injection of missed interrupts Chris Wilson
2016-06-25 10:43 ` ✗ Ro.CI.BAT: warning for series starting with [01/25] drm/i915: Preserve current RPS frequency across init 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=5772429F.6060001@linux.intel.com \
--to=tvrtko.ursulin@linux.intel.com \
--cc=chris@chris-wilson.co.uk \
--cc=intel-gfx@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