mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-22 04:28:10 +02:00
Right now there is a call to rc_get_variables, which performs a global analysis of the whole shader, for every IF encountered. As a result, shaders with a lot of IFs are compiled very slowly. The patological cases are shaders using relative adressing, where the lowered array access can result in tens of IFs. This patch restructures the pass to call the rc_get_variables just once at the beginning and later reuse the gathered info. We can do this, because even though we transform the shader in the meantime (like for example adding extra MOVs) the transformations are not siginificant enough to influence the relevant variable info we are using. This reduces CPU time for my shader-db by more than a half. I also checked that the generated code for all shaders in shader-db is identical. Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com> Reviewed-by: Filip Gawin <filip@gawin.net> Acked-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18678> |
||
|---|---|---|
| .. | ||
| amd | ||
| android_stub | ||
| asahi | ||
| broadcom | ||
| c11 | ||
| compiler | ||
| drm-shim | ||
| egl | ||
| etnaviv | ||
| freedreno | ||
| gallium | ||
| gbm | ||
| getopt | ||
| glx | ||
| gtest | ||
| hgl | ||
| imagination | ||
| imgui | ||
| intel | ||
| loader | ||
| mapi | ||
| mesa | ||
| microsoft | ||
| nouveau | ||
| panfrost | ||
| tool | ||
| util | ||
| virtio | ||
| vulkan | ||
| meson.build | ||