mesa/src
Marek Olšák 4d486888ee winsys/amdgpu: rewrite BO fence tracking by adding a new queue fence system
This decreases the time spent in amdgpu_cs_submit_ib from 15.4% to 8.3%
in VP2020/Catia1, which is a decrease of CPU load for that thread by 46%.
Overall, it increases performance by a small number in CPU-bound benchmarks.
The biggest improvement I have seen is VP2020/Catia2, where it increases
FPS by 12%.

It no longer stores pipe_fence_handle references inside amdgpu_winsys_bo.

The idea is to have a global fixed list of queues (only 1 queue per IP
for now) where each queue generates its own sequence numbers (generated
by the winsys, not the kernel). Each queue also has a ring of fences.
The sequence numbers are used as indices into the ring of fences, which
is how sequence numbers are converted to fences.

With that, each BO only has to keep a list of sequence numbers, 1 for each
queue. The maximum number of queues is set to 6. Since the system can
handle integer wraparounds of sequence numbers correctly, we only need
16-bit sequence numbers in BOs to have accurate busyness tracking. Thus,
each BO uses only 12 bytes to represent all its fences for all queues.
There is also a 1-byte bitmask saying which sequence numbers are
initialized.

amdgpu_winsys.h contains the complete description. It has several
limitations that exist to minimize the memory footprint and updating of
BO fences.

Acked-by: Yogesh Mohan Marimuthu <yogesh.mohanmarimuthu@amd.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26643>
2024-01-06 20:55:30 +00:00
..
amd aco: add new post-RA scheduler for ILP 2024-01-06 11:30:42 +00:00
android_stub
asahi asahi: Implement lod queries 2024-01-04 01:51:07 +00:00
broadcom ci/v3d: add support for rpi5 2024-01-05 16:10:50 +00:00
c11 util/meson: Getting mesa util core to be self contained 2023-08-02 03:41:24 +00:00
compiler glsl: Fixes glcpp/tests with mingw/gcc 2024-01-05 21:15:58 +00:00
drm-shim compiler,vulkan,drm-shim: Remove unused include directories from meson.build 2023-10-27 01:35:10 +00:00
egl egl/wayland: fix formatting and add trailing comma 2024-01-06 02:19:02 +00:00
etnaviv util: Add align_uintptr and use it treewide to replace ALIGN that works on size_t and uintptr_t 2024-01-05 21:54:35 +00:00
freedreno ir3/legalize: Fix helper propagation with b.any/b.all/getone 2024-01-05 11:37:09 +00:00
gallium winsys/amdgpu: rewrite BO fence tracking by adding a new queue fence system 2024-01-06 20:55:30 +00:00
gbm gbm: delete some zink handling 2023-10-09 18:43:09 +00:00
getopt
glx glx: Handle IGNORE_GLX_SWAP_METHOD_OML regardless of GLX_USE_APPLEGL 2023-12-18 17:52:09 +00:00
gtest gtest: backport ansi color fix 2023-08-18 21:33:14 +00:00
imagination pvr: alloc WSI memory via GPU when there isn't a valid display FD 2023-12-12 12:41:13 +00:00
imgui
intel intel/dev: update workaround definitions to latest defect status 2024-01-05 22:51:46 +00:00
loader loader: Remove a line of unused include 2024-01-03 08:06:01 +00:00
mapi glthread: add a string table of function names 2023-12-08 04:25:52 +00:00
mesa util: Add align_uintptr and use it treewide to replace ALIGN that works on size_t and uintptr_t 2024-01-05 21:54:35 +00:00
microsoft nir: remove redundant passes from nir_opt_if() 2024-01-03 20:48:05 +00:00
nouveau nouveau: Use align64 instead of ALIGN for 64 bit value parameter 2024-01-06 02:05:09 +00:00
panfrost panfrost: Avoid use align as variable, replace it with other names 2024-01-05 02:42:05 +00:00
tool perfetto/pps-producer: add optimized cpu/gpu timestamp correlation support 2023-11-09 13:22:48 +00:00
util util: create parents of disk cache directory if needed 2024-01-06 01:19:29 +00:00
virtio virgl: Only send the same amount of data than declared in pipe_sampler_state 2024-01-04 11:00:12 +00:00
vulkan util: Add align_uintptr and use it treewide to replace ALIGN that works on size_t and uintptr_t 2024-01-05 21:54:35 +00:00
.clang-format nir: add _safe variants of nir_foreach_reg_load/store 2023-12-15 17:19:28 +00:00
meson.build meson: Only include virtio when DRM available 2023-11-07 18:22:56 +00:00