[Mesa-dev] [PATCH 1/2] glsl: enable 'shared' keyword also for layout qualifiers
Lofstedt, Marta
marta.lofstedt at intel.com
Thu Nov 12 05:48:34 PST 2015
Reviewed-by: Marta Lofstedt <marta.lofstedt at intel.com>
> -----Original Message-----
> From: mesa-dev [mailto:mesa-dev-bounces at lists.freedesktop.org] On
> Behalf Of Samuel Iglesias Gonsálvez
> Sent: Thursday, November 12, 2015 2:23 PM
> To: mesa-dev at lists.freedesktop.org
> Subject: [Mesa-dev] [PATCH 1/2] glsl: enable 'shared' keyword also for layout
> qualifiers
>
> 'shared' was added in ARB_uniform_buffer_object and also used in
> ARB_shader_storage_buffer_object.
>
> A later patch will fix the shader layout qualifier regressions in dEQP.
>
> Signed-off-by: Samuel Iglesias Gonsálvez <siglesias at igalia.com>
> ---
> src/glsl/glsl_lexer.ll | 9 ++++++++-
> 1 file changed, 8 insertions(+), 1 deletion(-)
>
> diff --git a/src/glsl/glsl_lexer.ll b/src/glsl/glsl_lexer.ll index e59f93e..fc58ea0
> 100644
> --- a/src/glsl/glsl_lexer.ll
> +++ b/src/glsl/glsl_lexer.ll
> @@ -414,7 +414,14 @@ writeonly KEYWORD_WITH_ALT(420, 300, 420,
> 310, yyextra->ARB_shader_image_lo
>
> atomic_uint KEYWORD_WITH_ALT(420, 300, 420, 310, yyextra-
> >ARB_shader_atomic_counters_enable, ATOMIC_UINT);
>
> -shared KEYWORD_WITH_ALT(430, 310, 430, 310, yyextra-
> >ARB_compute_shader_enable, SHARED);
> +shared {
> + if ((yyextra->is_version(430, 310))
> + || yyextra-
> >ARB_uniform_buffer_object_enable
> + || yyextra-
> >ARB_shader_storage_buffer_object_enable
> + || yyextra->ARB_compute_shader_enable) {
> + return SHARED;
> + }
> + }
>
> struct return STRUCT;
> void return VOID_TOK;
> --
> 2.5.0
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
More information about the mesa-dev
mailing list