[Intel-gfx] [PATCH 3/6] drm/i915/perf: lock powergating configuration to default when active
Chris Wilson
chris at chris-wilson.co.uk
Mon Sep 17 11:50:11 UTC 2018
Quoting Tvrtko Ursulin (2018-09-17 12:30:55)
> From: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
>
> If some of the contexts submitting workloads to the GPU have been
> configured to shutdown slices/subslices, we might loose the NOA
> configurations written in the NOA muxes.
>
> One possible solution to this problem is to reprogram the NOA muxes
> when we switch to a new context. We initially tried this in the
> workaround batchbuffer but some concerns where raised about the cost
> of reprogramming at every context switch. This solution is also not
> without consequences from the userspace point of view. Reprogramming
> of the muxes can only happen once the powergating configuration has
> changed (which happens after context switch). This means for a window
> of time during the recording, counters recorded by the OA unit might
> be invalid. This requires userspace dealing with OA reports to discard
> the invalid values.
>
> Minimizing the reprogramming could be implemented by tracking of the
> last programmed configuration somewhere in GGTT and use MI_PREDICATE
> to discard some of the programming commands, but the command streamer
> would still have to parse all the MI_LRI instructions in the
> workaround batchbuffer.
>
> Another solution, which this change implements, is to simply disregard
> the user requested configuration for the period of time when i915/perf
> is active. There is no known issue with this apart from a performance
> penality for some media workloads that benefit from running on a
> partially powergated GPU. We already prevent RC6 from affecting the
> programming so it doesn't sound completely unreasonable to hold on
> powergating for the same reason.
>
> v2: Leave RPCS programming in intel_lrc.c (Lionel)
>
> v3: Update for s/union intel_sseu/struct intel_sseu/ (Lionel)
> More to_intel_context() (Tvrtko)
> s/dev_priv/i915/ (Tvrtko)
>
> Tvrtko Ursulin:
>
> v4:
> * Rebase for make_rpcs changes.
>
> v5:
> * Apply OA restriction from make_rpcs directly.
>
> v6:
> * Rebase for context image setup changes.
>
> v7:
> * Move stream assignment before metric enable.
>
> v8:
> * Rebase.
>
> Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin at intel.com>
Reviewed-by: Chris Wilson <chris at chris-wilson.co.uk>
-Chris
More information about the Intel-gfx
mailing list