Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=100316

Signed-off-by: Danylo Piliaiev <danylo.pilia...@globallogic.com>
---
 .../linker/invariant-propagation.shader_test  | 25 +++++++++++++++++++
 1 file changed, 25 insertions(+)
 create mode 100644 
tests/spec/glsl-1.20/linker/invariant-propagation.shader_test

diff --git a/tests/spec/glsl-1.20/linker/invariant-propagation.shader_test 
b/tests/spec/glsl-1.20/linker/invariant-propagation.shader_test
new file mode 100644
index 000000000..fc4096833
--- /dev/null
+++ b/tests/spec/glsl-1.20/linker/invariant-propagation.shader_test
@@ -0,0 +1,25 @@
+[require]
+GLSL >= 1.20
+
+# This test exercises a Mesa GLSL bug where 'invariant' qualifier
+# propagated on uniforms causing a linker failure due to mismatch
+# of uniforms declaration between stages.
+
+[vertex shader]
+#version 120
+uniform float t;
+invariant gl_Position;
+void main()
+{
+  gl_Position = vec4(t);
+}
+
+[fragment shader]
+#version 120
+uniform float t;
+void main()
+{
+}
+
+[test]
+link success
-- 
2.18.0

_______________________________________________
Piglit mailing list
Piglit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to