On Sun, Apr 20, 2014 at 9:05 PM, Chris Forbes <[email protected]> wrote: > These highlight a few cases where we were doing the wrong thing. > > Signed-off-by: Chris Forbes <[email protected]> > --- > .../glsl-1.50/compiler/invariant-qualifier-01.geom | 10 ++++++++++ > .../glsl-1.50/compiler/invariant-qualifier-02.geom | 10 ++++++++++ > .../glsl-1.50/compiler/invariant-qualifier-03.geom | 11 +++++++++++ > .../glsl-1.50/compiler/invariant-qualifier-04.geom | 11 +++++++++++ > .../compiler/invariant-qualifier-in-out-block-01.vert | 16 ++++++++++++++++ > .../compiler/invariant-qualifier-in-out-block-02.vert | 18 > ++++++++++++++++++ > 6 files changed, 76 insertions(+) > create mode 100644 tests/spec/glsl-1.50/compiler/invariant-qualifier-01.geom > create mode 100644 tests/spec/glsl-1.50/compiler/invariant-qualifier-02.geom > create mode 100644 tests/spec/glsl-1.50/compiler/invariant-qualifier-03.geom > create mode 100644 tests/spec/glsl-1.50/compiler/invariant-qualifier-04.geom > create mode 100644 > tests/spec/glsl-1.50/compiler/invariant-qualifier-in-out-block-01.vert > create mode 100644 > tests/spec/glsl-1.50/compiler/invariant-qualifier-in-out-block-02.vert > > diff --git a/tests/spec/glsl-1.50/compiler/invariant-qualifier-01.geom > b/tests/spec/glsl-1.50/compiler/invariant-qualifier-01.geom > new file mode 100644 > index 0000000..aa631dc > --- /dev/null > +++ b/tests/spec/glsl-1.50/compiler/invariant-qualifier-01.geom > @@ -0,0 +1,10 @@ > +// [config] > +// expect_result: fail > +// glsl_version: 1.50 > +// [end config] > +// > +// Verify that the invariant-qualifier cannot be used on uniforms in the GS. > + > +#version 150 > + > +invariant uniform vec4 junk; /* not allowed */ > diff --git a/tests/spec/glsl-1.50/compiler/invariant-qualifier-02.geom > b/tests/spec/glsl-1.50/compiler/invariant-qualifier-02.geom > new file mode 100644 > index 0000000..f9fdcbb > --- /dev/null > +++ b/tests/spec/glsl-1.50/compiler/invariant-qualifier-02.geom > @@ -0,0 +1,10 @@ > +// [config] > +// expect_result: fail > +// glsl_version: 1.50 > +// [end config] > +// > +// Verify that the invariant-qualifier cannot be used on temps in the GS. > + > +#version 150 > + > +invariant vec4 junk; /* not allowed */ > diff --git a/tests/spec/glsl-1.50/compiler/invariant-qualifier-03.geom > b/tests/spec/glsl-1.50/compiler/invariant-qualifier-03.geom > new file mode 100644 > index 0000000..029b7fd > --- /dev/null > +++ b/tests/spec/glsl-1.50/compiler/invariant-qualifier-03.geom > @@ -0,0 +1,11 @@ > +// [config] > +// expect_result: fail > +// glsl_version: 1.50 > +// [end config] > +// > +// Verify that the invariant redeclarations cannot be used on uniforms in > the GS. > + > +#version 150 > + > +uniform vec4 junk; > +invariant junk; /* not allowed */ > diff --git a/tests/spec/glsl-1.50/compiler/invariant-qualifier-04.geom > b/tests/spec/glsl-1.50/compiler/invariant-qualifier-04.geom > new file mode 100644 > index 0000000..3601360 > --- /dev/null > +++ b/tests/spec/glsl-1.50/compiler/invariant-qualifier-04.geom > @@ -0,0 +1,11 @@ > +// [config] > +// expect_result: fail > +// glsl_version: 1.50 > +// [end config] > +// > +// Verify that the invariant redeclarations cannot be used on temps in the > GS. > + > +#version 150 > + > +vec4 junk; > +invariant junk; /* not allowed */ > diff --git > a/tests/spec/glsl-1.50/compiler/invariant-qualifier-in-out-block-01.vert > b/tests/spec/glsl-1.50/compiler/invariant-qualifier-in-out-block-01.vert > new file mode 100644 > index 0000000..5eb50d0 > --- /dev/null > +++ b/tests/spec/glsl-1.50/compiler/invariant-qualifier-in-out-block-01.vert > @@ -0,0 +1,16 @@ > +// [config] > +// expect_result: pass > +// glsl_version: 1.50 > +// [end config] > +// > +// Tests that the invariant qualifier can be applied to a member of an out > block. > + > +#version 150 > + > +out block { > + invariant vec4 x; > +}; > + > +void main() > +{ > +} > diff --git > a/tests/spec/glsl-1.50/compiler/invariant-qualifier-in-out-block-02.vert > b/tests/spec/glsl-1.50/compiler/invariant-qualifier-in-out-block-02.vert > new file mode 100644 > index 0000000..b6c7b91 > --- /dev/null > +++ b/tests/spec/glsl-1.50/compiler/invariant-qualifier-in-out-block-02.vert > @@ -0,0 +1,18 @@ > +// [config] > +// expect_result: pass > +// glsl_version: 1.50 > +// [end config] > +// > +// Tests that the invariant qualifier can be applied to a member of an out > block. > + > +#version 150 > + > +out block { > + vec4 x; > +}; > + > +invariant x; > + > +void main() > +{ > +} > --
Looks good to me. Reviewed-by: Anuj Phogat <[email protected]> > 1.9.2 > > _______________________________________________ > Piglit mailing list > [email protected] > http://lists.freedesktop.org/mailman/listinfo/piglit _______________________________________________ Piglit mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/piglit
