nir/load_libclc: run some opt passes for everybody

Cuts down serialized size from 2850288 to 1377780 bytes.

Reduces clinfo with Rusticl time by 40% for debug builds.

(Old data, but the point stands)

Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15996>
This commit is contained in:
Karol Herbst
2022-04-17 00:06:54 +02:00
committed by Marge Bot
parent 3a981acf55
commit 570c263ea3
6 changed files with 47 additions and 36 deletions

View File

@@ -39,7 +39,8 @@ load_clc_shader(struct brw_compiler *compiler, struct disk_cache *disk_cache,
return compiler->clc_shader;
nir_shader *nir = nir_load_libclc_shader(64, disk_cache,
spirv_options, nir_options);
spirv_options, nir_options,
disk_cache != NULL);
if (nir == NULL)
return NULL;