glsl: Add support for the framebuffer fetch layout(noncoherent) qualifier.
[mesa.git] / src / compiler / glsl / ast_type.cpp
index ee8697ba21809c02b53968c29a5d8dfd38132ec3..14ea936f244e6413c4a57ab2f9e47d10927daefd 100644 (file)
@@ -186,10 +186,7 @@ validate_point_mode(MAYBE_UNUSED const ast_type_qualifier &qualifier,
 }
 
 static void
-merge_bindless_qualifier(YYLTYPE *loc,
-                         _mesa_glsl_parse_state *state,
-                         const ast_type_qualifier &qualifier,
-                         const ast_type_qualifier &new_qualifier)
+merge_bindless_qualifier(_mesa_glsl_parse_state *state)
 {
    if (state->default_uniform_qualifier->flags.q.bindless_sampler) {
       state->bindless_sampler_specified = true;
@@ -273,6 +270,7 @@ ast_type_qualifier::merge_qualifier(YYLTYPE *loc,
    input_layout_mask.flags.q.precise = 1;
    input_layout_mask.flags.q.sample = 1;
    input_layout_mask.flags.q.smooth = 1;
+   input_layout_mask.flags.q.non_coherent = 1;
 
    if (state->has_bindless()) {
       /* Allow to use image qualifiers with shader inputs/outputs. */
@@ -484,7 +482,7 @@ ast_type_qualifier::merge_qualifier(YYLTYPE *loc,
        q.flags.q.bindless_image ||
        q.flags.q.bound_sampler ||
        q.flags.q.bound_image)
-      merge_bindless_qualifier(loc, state, *this, q);
+      merge_bindless_qualifier(state);
 
    return r;
 }
@@ -778,7 +776,7 @@ ast_type_qualifier::validate_flags(YYLTYPE *loc,
                     "%s '%s':"
                     "%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s"
                     "%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s"
-                    "%s%s%s%s%s%s%s%s%s%s%s%s%s%s\n",
+                    "%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s\n",
                     message, name,
                     bad.flags.q.invariant ? " invariant" : "",
                     bad.flags.q.precise ? " precise" : "",
@@ -841,7 +839,8 @@ ast_type_qualifier::validate_flags(YYLTYPE *loc,
                     bad.flags.q.bindless_image ? " bindless_image" : "",
                     bad.flags.q.bound_sampler ? " bound_sampler" : "",
                     bad.flags.q.bound_image ? " bound_image" : "",
-                    bad.flags.q.post_depth_coverage ? " post_depth_coverage" : "");
+                    bad.flags.q.post_depth_coverage ? " post_depth_coverage" : "",
+                    bad.flags.q.non_coherent ? " noncoherent" : "");
    return false;
 }