[Mesa-dev] [PATCH] st/glsl_to_nir: add more nir opts to st_nir_opts()

Eric Anholt eric at anholt.net
Wed Jan 31 21:20:34 UTC 2018


Timothy Arceri <tarceri at itsqueeze.com> writes:

> All of the current gallium nir driver use these optimisations but
> they do so in their backends. Having these called in the backend
> only can cause a number of problems:
>
> - Shader compile times are greater because the opts need to do
>   significant passes over all shader variants.
> - The shader cache is partially defeated due to the significant
>   optimisation passes over variants.
> - We might miss out on nir linking optimisation opportunities.
>
> Adding these passes to st_nir_opts() alleviates these problems.

Maybe some driver gaining NIR input would want vector math instead of
scalar, but if all of our drivers agree at the moment, then let's put it
here.

Reviewed-by: Eric Anholt <eric at anholt.net>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20180131/7400b437/attachment.sig>


More information about the mesa-dev mailing list