]> asedeno.scripts.mit.edu Git - linux.git/commit
drm/i915/execlists: Virtual engine bonding
authorChris Wilson <chris@chris-wilson.co.uk>
Tue, 21 May 2019 21:11:33 +0000 (22:11 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Wed, 22 May 2019 07:40:46 +0000 (08:40 +0100)
commitee1136908e9b28173f9794be25465a13b2bb9b18
treee2faa5f8dfadff847f70e1b2cf25d9f353fbd795
parentf71e01a78bee1c93dbadbc0b6a11d7bd74237fa1
drm/i915/execlists: Virtual engine bonding

Some users require that when a master batch is executed on one particular
engine, a companion batch is run simultaneously on a specific slave
engine. For this purpose, we introduce virtual engine bonding, allowing
maps of master:slaves to be constructed to constrain which physical
engines a virtual engine may select given a fence on a master engine.

For the moment, we continue to ignore the issue of preemption deferring
the master request for later. Ideally, we would like to then also remove
the slave and run something else rather than have it stall the pipeline.
With load balancing, we should be able to move workload around it, but
there is a similar stall on the master pipeline while it may wait for
the slave to be executed. At the cost of more latency for the bonded
request, it may be interesting to launch both on their engines in
lockstep. (Bubbles abound.)

Opens: Also what about bonding an engine as its own master? It doesn't
break anything internally, so allow the silliness.

v2: Emancipate the bonds
v3: Couple in delayed scheduling for the selftests
v4: Handle invalid mutually exclusive bonding
v5: Mention what the uapi does
v6: s/nbond/num_bonds/

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190521211134.16117-9-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gt/intel_engine_types.h
drivers/gpu/drm/i915/gt/intel_lrc.c
drivers/gpu/drm/i915/gt/intel_lrc.h
drivers/gpu/drm/i915/gt/selftest_lrc.c
drivers/gpu/drm/i915/i915_gem_context.c
drivers/gpu/drm/i915/selftests/lib_sw_fence.c
include/uapi/drm/i915_drm.h