Rob Clark <[email protected]> writes: > From: Rob Clark <[email protected]> > > Signed-off-by: Rob Clark <[email protected]> > --- > src/mesa/Makefile.sources | 2 + > src/mesa/state_tracker/st_nir.h | 31 ++++ > src/mesa/state_tracker/st_nir_lower_builtin.c | 245 > ++++++++++++++++++++++++++ > 3 files changed, 278 insertions(+) > create mode 100644 src/mesa/state_tracker/st_nir.h > create mode 100644 src/mesa/state_tracker/st_nir_lower_builtin.c > > diff --git a/src/mesa/state_tracker/st_nir_lower_builtin.c > b/src/mesa/state_tracker/st_nir_lower_builtin.c > new file mode 100644 > index 0000000..e8b31f7 > --- /dev/null > +++ b/src/mesa/state_tracker/st_nir_lower_builtin.c
> +static const struct gl_builtin_uniform_element *
> +get_element(const struct gl_builtin_uniform_desc *desc, nir_deref_var *deref)
> +{
> + nir_deref *tail = &deref->deref;
> +
> + if ((desc->num_elements == 1) && (desc->elements[0].field == NULL))
> + return NULL;
> +
> + /* we handle array's in get_variable(): */
s/array's/arrays/
Other than that, while this is kind of gross, I guess we have to do it
as long as we're doing uniform storage the same as TGSI, which seems
like the right way to go for now.
Reviewed-by: Eric Anholt <[email protected]>
signature.asc
Description: PGP signature
_______________________________________________ mesa-dev mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/mesa-dev
