[Mesa-dev] [PATCH 1/4] nir/split_var_copies: handle IMAGE and SAMPLER for bindless vars

Jason Ekstrand jason at jlekstrand.net
Wed Apr 4 00:23:59 UTC 2018


I have a very strong feeling that this isn't the only place where
reading/writing IMAGE and SAMPLER variables is going to cause NIR
heartburn.  For example, we have special cases in nir_validate for
SUBROUTINE variables and we probably need IMAGE and SAMPLER support
everywhere we have SUBROUTINE plus some (since you can write to them now as
well).


On Tue, Apr 3, 2018 at 6:21 AM, Karol Herbst <kherbst at redhat.com> wrote:

> Signed-off-by: Karol Herbst <kherbst at redhat.com>
> ---
>  src/compiler/nir/nir_split_var_copies.c | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/src/compiler/nir/nir_split_var_copies.c
> b/src/compiler/nir/nir_split_var_copies.c
> index bc3ceedbdb8..231a89add4d 100644
> --- a/src/compiler/nir/nir_split_var_copies.c
> +++ b/src/compiler/nir/nir_split_var_copies.c
> @@ -241,6 +241,10 @@ split_var_copies_block(nir_block *block, struct
> split_var_copies_state *state)
>              ralloc_steal(state->dead_ctx, instr);
>           }
>           break;
> +      /* for bindless those are uint64 */
> +      case GLSL_TYPE_IMAGE:
> +      case GLSL_TYPE_SAMPLER:
> +         assert(src_head->var->data.bindless);
>        case GLSL_TYPE_INT:
>        case GLSL_TYPE_UINT:
>        case GLSL_TYPE_INT16:
> --
> 2.14.3
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20180403/aa36607a/attachment.html>


More information about the mesa-dev mailing list