---
 .../fs-multiple-large-local-arrays.shader_test     | 35 ++++++++++++++++++++++
 1 file changed, 35 insertions(+)
 create mode 100644 
tests/spec/glsl-1.30/execution/fs-multiple-large-local-arrays.shader_test

diff --git 
a/tests/spec/glsl-1.30/execution/fs-multiple-large-local-arrays.shader_test 
b/tests/spec/glsl-1.30/execution/fs-multiple-large-local-arrays.shader_test
new file mode 100644
index 0000000..1ad6a46
--- /dev/null
+++ b/tests/spec/glsl-1.30/execution/fs-multiple-large-local-arrays.shader_test
@@ -0,0 +1,35 @@
+# Both arrays will typically not fit into the GPU's
+# fastest storage type, requiring at least one to
+# be spilled/reloaded from a slower memory.
+# Test that this still produces correct values for array
+# elements.
+[require]
+GLSL >= 1.30
+
+[vertex shader passthrough]
+
+[fragment shader]
+uniform uint i;
+void main()
+{
+       uint A[60];
+       uint B[70];
+       A[20] = 0u;
+       A[i] = 37u;
+       B[20] = 0u;
+       B[i] = 39u;
+       gl_FragColor.rba = vec3(0.0, 0.0, 1.0);
+       gl_FragColor.g = float(A[20] == 37u && B[20] == 39u);
+}
+
+[test]
+clear color 1.0 0.0 0.0 1.0
+clear
+uniform uint i 19
+draw rect -1 -1 2 2
+probe all rgba 0.0 0.0 0.0 1.0
+
+clear
+uniform uint i 20
+draw rect -1 -1 2 2
+probe all rgba 0.0 1.0 0.0 1.0
-- 
2.7.4

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

Reply via email to