mesa/src
Iago Toral Quiroga 871b0a7f6a broadcom/compiler: don't sort nodes for register allocation
Nodes are allocated in order to registers so initially sorting
was used to ensure that nodes with smaller life ranges would
be assigned first and therefore be more likely to get
accumulators.

However, since d81a6e5f1d now we don't rely on order to make
decisions about accumulators and instead we make policy decisions
based on actual liveness, so sorting is no longer strictly
relevant to this decision.

Furthermore, we are not re-sorting nodes after each spill either,
since that would probably require that we rebuild the interference
graph after each spill (the graph identifies nodes by their index).

Shader-db results show a significant improvement in instruction
counts, due to more optimal accumulator assignments. The reason for
this is that we use a round-robin policy for choosing the next
accumulator to assign. The idea behind this is preventing nearby
temps to be assigned to the same accumulator so that QPU scheduling
is more flexible, but if we  sort our nodes, we are basically not
assigning temps in program order any more and the round-robin policy
becomes less effective:

total instructions in shared programs: 13000420 -> 12663189 (-2.59%)
instructions in affected programs: 11791267 -> 11454036 (-2.86%)
helped: 62890
HURT: 19987

total threads in shared programs: 415874 -> 415870 (<.01%)
threads in affected programs: 20 -> 16 (-20.00%)
helped: 2
HURT: 4

total uniforms in shared programs: 3711652 -> 3711624 (<.01%)
uniforms in affected programs: 43430 -> 43402 (-0.06%)
helped: 134
HURT: 173

total max-temps in shared programs: 2144876 -> 2138822 (-0.28%)
max-temps in affected programs: 123334 -> 117280 (-4.91%)
helped: 4112
HURT: 1195

total spills in shared programs: 3870 -> 3860 (-0.26%)
spills in affected programs: 1013 -> 1003 (-0.99%)
helped: 14
HURT: 12

total fills in shared programs: 5560 -> 5573 (0.23%)
fills in affected programs: 1765 -> 1778 (0.74%)
helped: 14
HURT: 17

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15168>
2022-03-02 08:09:11 +00:00
..
amd ac: add an environment variable that parses IBs in files 2022-03-01 22:30:24 +00:00
android_stub android_stub: update platform headers to include atrace 2021-10-09 00:42:32 +00:00
asahi asahi: Wire in pure integer texture formats 2022-02-18 23:48:33 +00:00
broadcom broadcom/compiler: don't sort nodes for register allocation 2022-03-02 08:09:11 +00:00
compiler nir: pass nir_shader into nir_recompute_io_bases instead of func_impl 2022-03-01 21:59:55 +00:00
drm-shim
egl egl/wayland: Don't replace existing backbuffer in get_buffers 2022-02-07 09:57:41 +00:00
etnaviv etnaviv: add support for INTEL_blackhole_render 2022-01-31 16:52:29 +00:00
freedreno turnip: Implement VK_EXT_physical_device_drm 2022-03-01 07:10:40 +00:00
gallium radeonsi: fix an assertion failure with register shadowing 2022-03-01 22:30:24 +00:00
gbm gbm: improve documentation about the lifetime of resources 2022-02-22 14:42:52 +01:00
getopt
glx glx/drisw: handle GL_RESET_NOTIFICATION_STRATEGY 2022-02-28 16:10:00 +00:00
gtest gtest: Fix output of array ASSERT/EXPECT macros 2021-11-11 09:53:09 -08:00
hgl
imgui
intel anv: Disable aux if the explicit modifier lacks it 2022-03-01 20:05:50 +00:00
loader gallium/dri: add missing PIPE_BIND_DRI_PRIME handling 2022-02-08 00:13:07 +00:00
mapi glthread: call _mesa_glthread_BindBuffer unconditionally 2022-02-01 06:11:22 +00:00
mesa st/mesa: do nir_lower_io() for inputs & outputs with transform feedback info 2022-03-01 21:59:56 +00:00
microsoft ci: Disable windows-vs2019 2022-02-23 15:12:41 +00:00
nouveau
panfrost pan/va: Add missing copyright notice 2022-03-01 19:43:23 +00:00
tool ci: Use a dlclose-disabling preload library for leak checking in Vulkan. 2022-01-27 23:47:46 +00:00
util radeonsi/drirc: use force_gl_vendor for Maya 2022-03-01 07:43:26 +01:00
virtio venus: Implement guest vram blob type. 2022-03-01 17:25:56 +00:00
vulkan vulkan/wsi: use buffer-image code-path on Windows 2022-02-22 10:04:34 +00:00
meson.build meson: start building intel earlier. 2022-01-20 06:41:17 +00:00