[Mesa-dev] [RFC PATCH 14/26] glsl: do not make bindless image read-only variables

Timothy Arceri tarceri at itsqueeze.com
Wed Apr 12 00:18:23 UTC 2017


On 12/04/17 02:48, Samuel Pitoiset wrote:
> Bindless images can be explicitely converted to and from uvec2
> using scalar constructors.
>
> Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
> ---
>  src/compiler/glsl/ast_to_hir.cpp | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/compiler/glsl/ast_to_hir.cpp b/src/compiler/glsl/ast_to_hir.cpp
> index f52ba8181a..bcdf212497 100644
> --- a/src/compiler/glsl/ast_to_hir.cpp
> +++ b/src/compiler/glsl/ast_to_hir.cpp
> @@ -3411,7 +3411,7 @@ apply_image_qualifier_to_variable(const struct ast_type_qualifier *qual,
>        var->data.image_coherent |= qual->flags.q.coherent;
>        var->data.image_volatile |= qual->flags.q._volatile;
>        var->data.image_restrict |= qual->flags.q.restrict_flag;
> -      var->data.read_only = true;
> +      var->data.read_only = base_type->is_image();
>
>        if (qual->flags.q.explicit_image_format) {
>           if (var->data.mode == ir_var_function_in) {
>

Just curious. If we remove this what stops values being directly 
assigned to images when not using the constructors?


More information about the mesa-dev mailing list