Quoting Michał Winiarski (2017-09-11 15:17:31)
> To create an upper bound on number of GuC workitems, we need to change
> the way that requests are being submitted. Rather than submitting each
> request as an individual workitem, we can do coalescing in a similar way
> we're handlig execlist submission ports. We also need to stop pretending
> that we're doing "lite-restore" in GuC submission (we would create a
> workitem each time we hit this condition). This allows us to completely
> remove the reservation, replacing it with a compile time check.
> 
> v2: Also coalesce when replaying on reset (Daniele)
?
You are using the pattern I expected, just calling i915_guc_submit()
with the ports[] reset to count=0 to trigger the resubmit.

> v3: Consistent wq_resv - per-request (Daniele)
> v4: Squash removing wq_resv
> 
> References: https://bugs.freedesktop.org/show_bug.cgi?id=101873
> Cc: Chris Wilson <ch...@chris-wilson.co.uk>
> Cc: Daniele Ceraolo Spurio <daniele.ceraolospu...@intel.com>
> Cc: Jeff McGee <jeff.mc...@intel.com>
> Cc: Michal Wajdeczko <michal.wajdec...@intel.com>
> Cc: Oscar Mateo <oscar.ma...@intel.com>
> Signed-off-by: Michał Winiarski <michal.winiar...@intel.com>

Looks good, very similar to the way I did the rq coalescing, but with
the improvement of restricting it to ARRAY_SIZE(port[]) and so asserting
that wq cannot overflow. If you get adventurous you can replace the
spinlock with cmpxchg.

Fancy having a go at a lockless guc_wq_item_append? Kill off the
redundant stats for simplicity.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

Reply via email to