[Piglit] [PATCH] arb_shader_storage_buffer_object: add memory qualifers test

Timothy Arceri t_arceri at yahoo.com.au
Fri Aug 14 17:43:49 PDT 2015


On Thu, 2015-08-13 at 10:57 +0300, Tapani Pälli wrote:
> Test checks that parser is able to deal with memory qualifiers given
> to shader storage block.
> 
> Signed-off-by: Tapani Pälli <tapani.palli at intel.com>
> ---
>  .../preprocessor/memory-qualifiers.vert                      | 12 
> ++++++++++++
>  1 file changed, 12 insertions(+)
>  create mode 100644 
> tests/spec/arb_shader_storage_buffer_object/preprocessor/memory
> -qualifiers.vert

Please move this to the compiler directory this isnt a preprocessor test.

Also maybe call this buffer-memory-qualifiers.vert to distingish it from
qualifiers on members.

> 
> diff --git a/tests/spec/arb_shader_storage_buffer_object/preprocessor/memory
> -qualifiers.vert 
> b/tests/spec/arb_shader_storage_buffer_object/preprocessor/memory
> -qualifiers.vert
> new file mode 100644
> index 0000000..f996cee
> --- /dev/null
> +++ b/tests/spec/arb_shader_storage_buffer_object/preprocessor/memory
> -qualifiers.vert
> @@ -0,0 +1,12 @@
> +// [config]
> +// expect_result: pass
> +// glsl_version: 3.30
> +// require_extensions: GL_ARB_shader_storage_buffer_object
> +// [end config]
> +
> +#version 330
> +#extension GL_ARB_shader_storage_buffer_object: require
> +coherent restrict volatile buffer Buffer {
> +	vec4 foo;
> +} buf;
> +int foo(void) { return 1; }

I think the last line would look better as

vec4 foo(void) { return buf.foo; }

With those few comments addressed

Reviewed-by: Timothy Arceri <t_arceri at yahoo.com.au>


More information about the Piglit mailing list