Skip to content

Media scalability tooling

Tvrtko Ursulin igt-dev intel-gfx 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest17 patches 2 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/17lib: Update uapi headersinclude/drm-uapi/amdgpu_drm.h include/drm-uapi/drm.h include/drm-uapi/drm_fourcc.h +11 more+1613 -1560 replies
2/17trace.pl: Virtual engine supportscripts/trace.pl+200 -300 replies
3/17trace.pl: Virtual engine preemption supportscripts/trace.pl+9 -50 replies
4/17wsim/media-bench: i915 balancingbenchmarks/gem_wsim.c scripts/media-bench.pl+251 -470 replies
5/17gem_wsim: Use IGT uapi headersbenchmarks/gem_wsim.c+17 -510 replies
6/17gem_wsim: Fix shadowed localbenchmarks/gem_wsim.c+0 -10 replies
7/17gem_wsim: Factor out common error handlingbenchmarks/gem_wsim.c+88 -1560 replies
8/17gem_wsim: More wsim_errbenchmarks/gem_wsim.c+15 -390 replies
9/17gem_wsim: Submit fence supportbenchmarks/gem_wsim.c benchmarks/wsim/README+33 -40 replies
10/17gem_wsim: Extract str to engine lookupbenchmarks/gem_wsim.c+21 -130 replies
11/17gem_wsim: Engine map supportbenchmarks/gem_wsim.c benchmarks/wsim/README+192 -370 replies
12/17gem_wsim: Save some lines by changing to implicit NULL checkingbenchmarks/gem_wsim.c+15 -240 replies
13/17gem_wsim: Compact int command parsing with a macrobenchmarks/gem_wsim.c+25 -550 replies
14/17gem_wsim: Engine map load balance commandbenchmarks/gem_wsim.c benchmarks/wsim/README+73 -70 replies
15/17gem_wsim: Engine bond commandbenchmarks/gem_wsim.c benchmarks/wsim/README+143 -72 replies
16/17gem_wsim: Some more example workloadsbenchmarks/wsim/frame-split-60fps.wsim benchmarks/wsim/high-composited-game.wsim benchmarks/wsim/media-1080p-player.wsim +1 more+41 -00 replies
17/17gem_wsim: Infinite batch supportbenchmarks/gem_wsim.c benchmarks/wsim/README benchmarks/wsim/frame-split-60fps.wsim+102 -320 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [igt-dev] [PATCH i-g-t 00/17] Media scalability tooling

From: Tvrtko Ursulin <[email protected]>

A bunch of patches to trace.pl and gem_wsim which enable simulation and load balancing analysis of the Virtual Engine work done separately by Chris Wilson.

Culmination is being able to simulate a so called frame split media workloads.

Example workload for this looks like this (annotated only for cover letter):

X.1.0 ; disable preemption on context 1
M.1.VCS1 ; configure engine map on context 1
B.1 ; turn on load balancing on context 1
X.2.0 ; \
M.2.VCS2 ; -> same as above but for context 2
B.2 ; /
b.2.1.VCS1 ; bond VCS2 in context 2 with VCS1
f ; create an unsignaled fence
1.DEFAULT.*.f-1.0 ; submit an infinite batch to ctx 1, with input fence
2.DEFAULT.4000-6000.s-1.0 ; submit a 4-6ms batch to ctx 2, with submit fence from the previous step

  a.-3			    ; advance the fence created 3 lines above
  s.-2			    ; wait for ctx 2 batch to complete
  T.-4			    ; terminate ctx 1 infinite batch

3.RCS.2000-4000.-5/-4.0 ; submit 2-4ms ctx 3 batch to RCS, with data dependencies
3.VECS.2000.-1.0 ; submit 2ms ctx 3 batch to VECS, data dependency on previous batch
4.BCS.1000.-1.0 ; submit 1ms ctx 4 batch to BCS, data dependency on previous batch
s.-2 ; wait for ctx 3 batch to complete
p.16667 ; start next iteration to hit 60fps simulation

And can be run for instance like this:

./gem_wsim -n <calibration> -w wsim/frame_split_60fps.wsim -r 60 -c 3

This runs three clients of the same workload, 60 iterations each.

This can then also be captured with trace.pl and a HTML representation of the execution timeline analysed:

../scripts/trace.pl --trace ./gem_wsim ...
perf script | ../scripts/trace.pl -s -c --gpu-timeline --html >timeline.html

[Vis npm module is required to be present in the same directory as the HTML ]
[file, see trace.pl --help for instructions. ]

Tvrtko Ursulin (17):
lib: Update uapi headers
trace.pl: Virtual engine support
trace.pl: Virtual engine preemption support wsim/media-bench: i915 balancing
gem_wsim: Use IGT uapi headers
gem_wsim: Fix shadowed local
gem_wsim: Factor out common error handling
gem_wsim: More wsim_err
gem_wsim: Submit fence support
gem_wsim: Extract str to engine lookup
gem_wsim: Engine map support
gem_wsim: Save some lines by changing to implicit NULL checking
gem_wsim: Compact int command parsing with a macro
gem_wsim: Engine map load balance command
gem_wsim: Engine bond command
gem_wsim: Some more example workloads
gem_wsim: Infinite batch support

 benchmarks/gem_wsim.c                       | 1060 +++++++++++++------
 benchmarks/wsim/README                      |  111 +-
 benchmarks/wsim/frame-split-60fps.wsim      |   18 +
 benchmarks/wsim/high-composited-game.wsim   |   11 +
 benchmarks/wsim/media-1080p-player.wsim     |    5 +
 benchmarks/wsim/medium-composited-game.wsim |    9 +
 include/drm-uapi/amdgpu_drm.h               |   52 +-
 include/drm-uapi/drm.h                      |   16 +
 include/drm-uapi/drm_fourcc.h               |  224 ++++
 include/drm-uapi/drm_mode.h                 |   26 +-
 include/drm-uapi/etnaviv_drm.h              |    6 +
 include/drm-uapi/exynos_drm.h               |  240 +++++
 include/drm-uapi/i915_drm.h                 |  239 ++++-
 include/drm-uapi/msm_drm.h                  |    2 +
 include/drm-uapi/sync_file.h                |   98 --
 include/drm-uapi/tegra_drm.h                |  492 ++++++++-
 include/drm-uapi/v3d_drm.h                  |  194 ++++
 include/drm-uapi/vc4_drm.h                  |   13 +-
 include/drm-uapi/virtgpu_drm.h              |    1 +
 include/drm-uapi/vmwgfx_drm.h               |  166 ++-
 scripts/media-bench.pl                      |    9 +-
 scripts/trace.pl                            |  244 ++++-
 22 files changed, 2705 insertions(+), 531 deletions(-)
 create mode 100644 benchmarks/wsim/frame-split-60fps.wsim
 create mode 100644 benchmarks/wsim/high-composited-game.wsim
 create mode 100644 benchmarks/wsim/media-1080p-player.wsim
 create mode 100644 benchmarks/wsim/medium-composited-game.wsim
 delete mode 100644 include/drm-uapi/sync_file.h
 create mode 100644 include/drm-uapi/v3d_drm.h
Signature · 6 lines
2.17.1

_______________________________________________
igt-dev mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/igt-dev