nir: Add a nir_foreach_gl_uniform_variable helper for GL linking
authorJason Ekstrand <jason@jlekstrand.net>
Mon, 20 Jul 2020 19:09:50 +0000 (14:09 -0500)
committerMarge Bot <eric+marge@anholt.net>
Wed, 29 Jul 2020 17:38:58 +0000 (17:38 +0000)
commite3e1c50067e0a1e219bc4d30333b953c6baa0c08
tree52aef8015c0ab553ce60e45b8146ac0aea54d069
parentfeb32f898c6d36f3c81c3ce2d5a3f8ddd915e332
nir: Add a nir_foreach_gl_uniform_variable helper for GL linking

There are a bunch of cases where we really do want to walk the list that
is nir->uniforms because we want all things declared "uniform" in the
GLSL.  Add a helper for this but restrict it to the GL linking code.

Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5966>
src/compiler/glsl/gl_nir_link_uniform_initializers.c
src/compiler/glsl/gl_nir_link_uniforms.c
src/compiler/glsl/gl_nir_linker.h