[Mesa-dev] [PATCH] arb_shader_image_load_store: add memory-qualifier-with-non-image-type.frag

Samuel Pitoiset samuel.pitoiset at gmail.com
Wed Apr 26 16:40:52 UTC 2017


Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
---
 .../memory-qualifier-with-non-image-type.frag      | 25 ++++++++++++++++++++++
 1 file changed, 25 insertions(+)
 create mode 100644 tests/spec/arb_shader_image_load_store/compiler/memory-qualifier-with-non-image-type.frag

diff --git a/tests/spec/arb_shader_image_load_store/compiler/memory-qualifier-with-non-image-type.frag b/tests/spec/arb_shader_image_load_store/compiler/memory-qualifier-with-non-image-type.frag
new file mode 100644
index 000000000..71087ec21
--- /dev/null
+++ b/tests/spec/arb_shader_image_load_store/compiler/memory-qualifier-with-non-image-type.frag
@@ -0,0 +1,25 @@
+// [config]
+// expect_result: fail
+// glsl_version: 3.30
+// require_extensions: GL_ARB_shader_image_load_store
+// [end config]
+
+#version 330
+#extension GL_ARB_shader_image_load_store: enable
+
+// From Section 4.10 (Memory Qualifiers) of the GLSL 4.50 spec:
+//
+// "Variables declared as image types (the basic opaque types with “image”
+//  in their keyword) can be further qualified with one or more of the
+//  following memory qualifiers: ..."
+//
+// Easy enough to infer that memory qualifiers should not be used with
+// non-image types.
+
+uniform Block {
+	volatile int x;
+};
+
+void main()
+{
+}
-- 
2.12.2



More information about the mesa-dev mailing list