On 01/24/2014 01:25 PM, Ian Romanick wrote:
> From: Ian Romanick <[email protected]>
> 
> This currently fails on Mesa.
> 
> Signed-off-by: Ian Romanick <[email protected]>
> ---
>  tests/all.py                                          |  6 ++++++
>  .../amd_shader_trinary_minmax/compiler/define.frag    | 19 
> +++++++++++++++++++
>  .../amd_shader_trinary_minmax/compiler/define.vert    | 19 
> +++++++++++++++++++
>  3 files changed, 44 insertions(+)
>  create mode 100644 tests/spec/amd_shader_trinary_minmax/compiler/define.frag
>  create mode 100644 tests/spec/amd_shader_trinary_minmax/compiler/define.vert
> 
> diff --git a/tests/all.py b/tests/all.py
> index b9dc92a..89dd7a3 100644
> --- a/tests/all.py
> +++ b/tests/all.py
> @@ -1407,6 +1407,12 @@ 
> import_glsl_parser_tests(spec['AMD_conservative_depth'],
>                        os.path.join(testsDir, 'spec', 
> 'amd_conservative_depth'),
>                        [''])
>  
> +# Group AMD_shader_trinary_minmax
> +spec['AMD_shader_trinary_minmax'] = Group()
> +import_glsl_parser_tests(spec['AMD_shader_trinary_minmax'],
> +                      os.path.join(testsDir, 'spec', 
> 'amd_shader_trinary_minmax'),
> +                      [''])
> +
>  # Group ARB_point_sprite
>  arb_point_sprite = Group()
>  spec['ARB_point_sprite'] = arb_point_sprite
> diff --git a/tests/spec/amd_shader_trinary_minmax/compiler/define.frag 
> b/tests/spec/amd_shader_trinary_minmax/compiler/define.frag
> new file mode 100644
> index 0000000..b1931cf
> --- /dev/null
> +++ b/tests/spec/amd_shader_trinary_minmax/compiler/define.frag
> @@ -0,0 +1,19 @@
> +// [config]
> +// expect_result: pass
> +// glsl_version: 1.10
> +// require_extensions: GL_AMD_shader_trinary_minmax
> +// [end config]
> +
> +#version 110
> +#extension GL_AMD_shader_trinary_minmax: require
> +
> +#if !defined GL_AMD_shader_trinary_minmax

I think #ifndef would be nicer, but not a big deal either way.

> +#  error GL_AMD_shader_trinary_minmax is not defined
> +#elif GL_AMD_shader_trinary_minmax != 1
> +#  error GL_AMD_shader_trinary_minmax is not equal to 1
> +#endif
> +
> +/* Some compilers generate spurious errors if a shader does not contain
> + * any code or declarations.
> + */
> +int foo(void) { return 1; }
> diff --git a/tests/spec/amd_shader_trinary_minmax/compiler/define.vert 
> b/tests/spec/amd_shader_trinary_minmax/compiler/define.vert
> new file mode 100644
> index 0000000..b1931cf
> --- /dev/null
> +++ b/tests/spec/amd_shader_trinary_minmax/compiler/define.vert
> @@ -0,0 +1,19 @@
> +// [config]
> +// expect_result: pass
> +// glsl_version: 1.10
> +// require_extensions: GL_AMD_shader_trinary_minmax
> +// [end config]
> +
> +#version 110
> +#extension GL_AMD_shader_trinary_minmax: require
> +
> +#if !defined GL_AMD_shader_trinary_minmax
> +#  error GL_AMD_shader_trinary_minmax is not defined

Ditto.

Either way,
Reviewed-by: Kenneth Graunke <[email protected]>

> +#elif GL_AMD_shader_trinary_minmax != 1
> +#  error GL_AMD_shader_trinary_minmax is not equal to 1
> +#endif
> +
> +/* Some compilers generate spurious errors if a shader does not contain
> + * any code or declarations.
> + */
> +int foo(void) { return 1; }
> 


Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Piglit mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to