aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndres Gomez <agomez@igalia.com>2016-10-11 17:11:24 +0300
committerAndres Gomez <agomez@igalia.com>2016-11-26 02:39:55 +0200
commitdd29f890cac9c047be24b6e649853fbd34ffc365 (patch)
treee738b9c707af678a85de72d928c75a4fe3dc0ae3
parent9269d4757a33a9e2f0b7bea8c69c23496efbcba0 (diff)
downloadpiglit-dd29f890cac9c047be24b6e649853fbd34ffc365.tar.gz
arb_enhanced_layouts: More duplicated layout-qualifier-names tests
Added tests for the layout-qualifier-names "max_vertices", "invocations", "vertices", "local_size_[x|y|z]" and "xfb_stride" which may have redeclarations but all of them enforce that a global or variable redeclaration holds the same value than in the previous declaration(s). These tests check that multiple appearances of the same layout-qualifier-name in a single layout qualifier with different values won't trigger a compile/link error. From the ARB_enhanced_layouts spec: "More than one layout qualifier may appear in a single declaration. Additionally, the same layout-qualifier-name can occur multiple times within a layout qualifier or across multiple layout qualifiers in the same declaration. When the same layout-qualifier-name occurs multiple times, in a single declaration, the last occurrence overrides the former occurrence(s). Further, if such a layout-qualifier-name will effect subsequent declarations or other observable behavior, it is only the last occurrence that will have any effect, behaving as if the earlier occurrence(s) within the declaration are not present. This is also true for overriding layout-qualifier-names, where one overrides the other (e.g., row_major vs. column_major); only the last occurrence has any effect." V2: - Removed link check, as suggested by Timothy. - Risen GLSL version from 1.40 to 1.50, needed for default input/output layout declarations. Reviewed-by: Timothy Arceri <timothy.arceri@collabora.com> Signed-off-by: Andres Gomez <agomez@igalia.com>
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-invocation-identifiers-in-single-layout-mismatch.geom38
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-invocation-identifiers-in-single-layout.geom38
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-local_size-identifiers-in-single-layout-mismatch.comp37
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-local_size-identifiers-in-single-layout.comp37
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-max_vertices-identifiers-in-single-layout-mismatch.geom40
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-max_vertices-identifiers-in-single-layout.geom40
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-vertices-identifiers-in-single-layout-mismatch.tesc39
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-vertices-identifiers-in-single-layout.tesc39
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-global-identifiers-in-single-layout-mismatch.vert41
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-global-identifiers-in-single-layout.vert41
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-identifiers-in-single-layout-mismatch.vert44
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-identifiers-in-single-layout.vert44
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-global-identifiers-in-single-layout-mismatch.vert37
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-global-identifiers-in-single-layout.vert37
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-global-identifiers-in-single-layout-mismatch.vert41
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-global-identifiers-in-single-layout.vert41
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-identifiers-in-single-layout-mismatch.vert44
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-identifiers-in-single-layout.vert44
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-global-identifiers-in-single-layout-mismatch.vert39
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-global-identifiers-in-single-layout.vert39
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-identifiers-in-single-layout-mismatch.vert39
-rw-r--r--tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-identifiers-in-single-layout.vert39
22 files changed, 878 insertions, 0 deletions
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-invocation-identifiers-in-single-layout-mismatch.geom b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-invocation-identifiers-in-single-layout-mismatch.geom
new file mode 100644
index 000000000..31d0aed99
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-invocation-identifiers-in-single-layout-mismatch.geom
@@ -0,0 +1,38 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts GL_ARB_gpu_shader5
+// check_link: false
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_gpu_shader5 spec:
+//
+// "If an invocation count is declared, all such declarations must
+// specify the same count."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: enable
+#extension GL_ARB_gpu_shader5 : enable
+
+layout(points, invocations=4, invocations=3) in;
+layout(invocations=4) in;
+layout(triangle_strip, max_vertices=3) out;
+
+void main()
+{
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-invocation-identifiers-in-single-layout.geom b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-invocation-identifiers-in-single-layout.geom
new file mode 100644
index 000000000..a9837fb39
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-invocation-identifiers-in-single-layout.geom
@@ -0,0 +1,38 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts GL_ARB_gpu_shader5
+// check_link: false
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_gpu_shader5 spec:
+//
+// "If an invocation count is declared, all such declarations must
+// specify the same count."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: enable
+#extension GL_ARB_gpu_shader5 : enable
+
+layout(points, invocations=3, invocations=4) in;
+layout(invocations=4) in;
+layout(triangle_strip, max_vertices=3) out;
+
+void main()
+{
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-local_size-identifiers-in-single-layout-mismatch.comp b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-local_size-identifiers-in-single-layout-mismatch.comp
new file mode 100644
index 000000000..9d0b6caed
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-local_size-identifiers-in-single-layout-mismatch.comp
@@ -0,0 +1,37 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts GL_ARB_compute_shader
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_compute_shader spec:
+//
+// "[If an input layout qualifier] is declared more than once in
+// the same shader, all those declarations must indicate the same
+// local work-group size; otherwise a compile-time error results."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: enable
+#extension GL_ARB_compute_shader: enable
+
+layout(local_size_z = 2, local_size_z = 1) in;
+layout(local_size_z = 2) in;
+
+void main()
+{
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-local_size-identifiers-in-single-layout.comp b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-local_size-identifiers-in-single-layout.comp
new file mode 100644
index 000000000..c5b0dd74e
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-local_size-identifiers-in-single-layout.comp
@@ -0,0 +1,37 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts GL_ARB_compute_shader
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_compute_shader spec:
+//
+// "[If an input layout qualifier] is declared more than once in
+// the same shader, all those declarations must indicate the same
+// local work-group size; otherwise a compile-time error results."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: enable
+#extension GL_ARB_compute_shader: enable
+
+layout(local_size_z = 1, local_size_z = 2) in;
+layout(local_size_z = 2) in;
+
+void main()
+{
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-max_vertices-identifiers-in-single-layout-mismatch.geom b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-max_vertices-identifiers-in-single-layout-mismatch.geom
new file mode 100644
index 000000000..9f3519cf5
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-max_vertices-identifiers-in-single-layout-mismatch.geom
@@ -0,0 +1,40 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From section 4.3.8.2(Output Layout Qualifiers) of the GLSL 1.50 spec says:
+//
+// "All geometry shader output layout declarations in a program must declare the
+// same layout and same value for max_vertices."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: enable
+
+layout(lines) in;
+layout(line_strip, max_vertices=3, max_vertices=2) out;
+
+in vec4 pos[];
+
+layout(max_vertices=3) out;
+
+void main()
+{
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-max_vertices-identifiers-in-single-layout.geom b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-max_vertices-identifiers-in-single-layout.geom
new file mode 100644
index 000000000..54411cfdc
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-max_vertices-identifiers-in-single-layout.geom
@@ -0,0 +1,40 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From section 4.3.8.2(Output Layout Qualifiers) of the GLSL 1.50 spec says:
+//
+// "All geometry shader output layout declarations in a program must declare the
+// same layout and same value for max_vertices."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: enable
+
+layout(lines) in;
+layout(line_strip, max_vertices=2, max_vertices=3) out;
+
+in vec4 pos[];
+
+layout(max_vertices=3) out;
+
+void main()
+{
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-vertices-identifiers-in-single-layout-mismatch.tesc b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-vertices-identifiers-in-single-layout-mismatch.tesc
new file mode 100644
index 000000000..883567edd
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-vertices-identifiers-in-single-layout-mismatch.tesc
@@ -0,0 +1,39 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts GL_ARB_tessellation_shader
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_tessellation_shader spec:
+//
+// "All tessellation control shader layout declarations in a program must
+// specify the same output patch vertex count."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: enable
+#extension GL_ARB_tessellation_shader: require
+
+layout(vertices = 3, vertices = 4) out;
+layout(vertices = 3) out;
+
+void main() {
+ gl_out[gl_InvocationID].gl_Position = vec4(0.0);
+ gl_TessLevelOuter = float[4](1.0, 1.0, 1.0, 1.0);
+ gl_TessLevelInner = float[2](1.0, 1.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-vertices-identifiers-in-single-layout.tesc b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-vertices-identifiers-in-single-layout.tesc
new file mode 100644
index 000000000..66f42233c
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-vertices-identifiers-in-single-layout.tesc
@@ -0,0 +1,39 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts GL_ARB_tessellation_shader
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_tessellation_shader spec:
+//
+// "All tessellation control shader layout declarations in a program must
+// specify the same output patch vertex count."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: enable
+#extension GL_ARB_tessellation_shader: require
+
+layout(vertices = 4, vertices = 3) out;
+layout(vertices = 3) out;
+
+void main() {
+ gl_out[gl_InvocationID].gl_Position = vec4(0.0);
+ gl_TessLevelOuter = float[4](1.0, 1.0, 1.0, 1.0);
+ gl_TessLevelInner = float[2](1.0, 1.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-global-identifiers-in-single-layout-mismatch.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-global-identifiers-in-single-layout-mismatch.vert
new file mode 100644
index 000000000..5863ffc4c
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-global-identifiers-in-single-layout-mismatch.vert
@@ -0,0 +1,41 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 20, xfb_buffer = 0) out;
+
+layout(xfb_stride = 20, xfb_stride = 32) out block {
+ vec4 var;
+};
+
+void main()
+{
+ var = vec4(1.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-global-identifiers-in-single-layout.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-global-identifiers-in-single-layout.vert
new file mode 100644
index 000000000..a43961be9
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-global-identifiers-in-single-layout.vert
@@ -0,0 +1,41 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 20, xfb_buffer = 0) out;
+
+layout(xfb_stride = 32, xfb_stride = 20) out block {
+ vec4 var;
+};
+
+void main()
+{
+ var = vec4(1.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-identifiers-in-single-layout-mismatch.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-identifiers-in-single-layout-mismatch.vert
new file mode 100644
index 000000000..3bf393407
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-identifiers-in-single-layout-mismatch.vert
@@ -0,0 +1,44 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 20, xfb_stride = 32) out block1 {
+ vec4 var;
+};
+
+layout(xfb_buffer = 0, xfb_stride = 20) out block2 {
+ vec4 var2;
+};
+
+void main()
+{
+ var = vec4(1.0);
+ var2 = vec4(0.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-identifiers-in-single-layout.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-identifiers-in-single-layout.vert
new file mode 100644
index 000000000..e3b03559c
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-block-identifiers-in-single-layout.vert
@@ -0,0 +1,44 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 32, xfb_stride = 20) out block1 {
+ vec4 var;
+};
+
+layout(xfb_buffer = 0, xfb_stride = 20) out block2 {
+ vec4 var2;
+};
+
+void main()
+{
+ var = vec4(1.0);
+ var2 = vec4(0.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-global-identifiers-in-single-layout-mismatch.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-global-identifiers-in-single-layout-mismatch.vert
new file mode 100644
index 000000000..b896dbc44
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-global-identifiers-in-single-layout-mismatch.vert
@@ -0,0 +1,37 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 32, xfb_stride = 20) out;
+layout(xfb_buffer = 0, xfb_stride = 32) out;
+
+void main()
+{
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-global-identifiers-in-single-layout.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-global-identifiers-in-single-layout.vert
new file mode 100644
index 000000000..70a35e2b2
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-global-identifiers-in-single-layout.vert
@@ -0,0 +1,37 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 32, xfb_stride = 20) out;
+layout(xfb_buffer = 0, xfb_stride = 20) out;
+
+void main()
+{
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-global-identifiers-in-single-layout-mismatch.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-global-identifiers-in-single-layout-mismatch.vert
new file mode 100644
index 000000000..e3d627761
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-global-identifiers-in-single-layout-mismatch.vert
@@ -0,0 +1,41 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 20, xfb_buffer = 0) out;
+
+layout(xfb_stride = 20, xfb_stride = 32) out block {
+ vec4 var;
+} b1;
+
+void main()
+{
+ b1.var = vec4(1.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-global-identifiers-in-single-layout.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-global-identifiers-in-single-layout.vert
new file mode 100644
index 000000000..e9c528fbb
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-global-identifiers-in-single-layout.vert
@@ -0,0 +1,41 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 20, xfb_buffer = 0) out;
+
+layout(xfb_stride = 32, xfb_stride = 20) out block {
+ vec4 var;
+} b1;
+
+void main()
+{
+ b1.var = vec4(1.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-identifiers-in-single-layout-mismatch.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-identifiers-in-single-layout-mismatch.vert
new file mode 100644
index 000000000..b42c28318
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-identifiers-in-single-layout-mismatch.vert
@@ -0,0 +1,44 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 20, xfb_stride = 32) out block1 {
+ vec4 var;
+} b1;
+
+layout(xfb_buffer = 0, xfb_stride = 20) out block2 {
+ vec4 var2;
+} b2;
+
+void main()
+{
+ b1.var = vec4(1.0);
+ b2.var2 = vec4(0.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-identifiers-in-single-layout.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-identifiers-in-single-layout.vert
new file mode 100644
index 000000000..c32b58cab
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-namedblock-identifiers-in-single-layout.vert
@@ -0,0 +1,44 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 32, xfb_stride = 20) out block1 {
+ vec4 var;
+} b1;
+
+layout(xfb_buffer = 0, xfb_stride = 20) out block2 {
+ vec4 var2;
+} b2;
+
+void main()
+{
+ b1.var = vec4(1.0);
+ b2.var2 = vec4(0.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-global-identifiers-in-single-layout-mismatch.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-global-identifiers-in-single-layout-mismatch.vert
new file mode 100644
index 000000000..937280c24
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-global-identifiers-in-single-layout-mismatch.vert
@@ -0,0 +1,39 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 20, xfb_buffer = 0) out;
+
+layout(xfb_buffer = 0, xfb_stride = 20, xfb_stride = 32) out vec4 var;
+
+void main()
+{
+ var = vec4(1.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-global-identifiers-in-single-layout.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-global-identifiers-in-single-layout.vert
new file mode 100644
index 000000000..4cfea4deb
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-global-identifiers-in-single-layout.vert
@@ -0,0 +1,39 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 20, xfb_buffer = 0) out;
+
+layout(xfb_buffer = 0, xfb_stride = 32, xfb_stride = 20) out vec4 var;
+
+void main()
+{
+ var = vec4(1.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-identifiers-in-single-layout-mismatch.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-identifiers-in-single-layout-mismatch.vert
new file mode 100644
index 000000000..8874b4285
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-identifiers-in-single-layout-mismatch.vert
@@ -0,0 +1,39 @@
+// [config]
+// expect_result: fail
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 32, xfb_stride = 20) out vec4 var;
+layout(xfb_buffer = 0, xfb_stride = 32) out vec4 var2;
+
+void main()
+{
+ var = vec4(1.0);
+ var2 = vec4(0.0);
+}
diff --git a/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-identifiers-in-single-layout.vert b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-identifiers-in-single-layout.vert
new file mode 100644
index 000000000..0f7df1994
--- /dev/null
+++ b/tests/spec/arb_enhanced_layouts/compiler/duplicate-layout-qualifier-identifiers/multiple-xfb_stride-variable-identifiers-in-single-layout.vert
@@ -0,0 +1,39 @@
+// [config]
+// expect_result: pass
+// glsl_version: 1.50
+// require_extensions: GL_ARB_enhanced_layouts
+// check_link: true
+// [end config]
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "More than one layout qualifier may appear in a single declaration.
+// Additionally, the same layout-qualifier-name can occur multiple times
+// within a layout qualifier or across multiple layout qualifiers in the
+// same declaration. When the same layout-qualifier-name occurs
+// multiple times, in a single declaration, the last occurrence overrides
+// the former occurrence(s). Further, if such a layout-qualifier-name
+// will effect subsequent declarations or other observable behavior, it
+// is only the last occurrence that will have any effect, behaving as if
+// the earlier occurrence(s) within the declaration are not present.
+// This is also true for overriding layout-qualifier-names, where one
+// overrides the other (e.g., row_major vs. column_major); only the last
+// occurrence has any effect."
+//
+// From the ARB_enhanced_layouts spec:
+//
+// "While *xfb_stride* can be declared multiple times for the same buffer,
+// it is a compile-time or link-time error to have different values
+// specified for the stride for the same buffer."
+
+#version 150
+#extension GL_ARB_enhanced_layouts: require
+
+layout(xfb_stride = 32, xfb_stride = 20) out vec4 var;
+layout(xfb_buffer = 0, xfb_stride = 20) out vec4 var2;
+
+void main()
+{
+ var = vec4(1.0);
+ var2 = vec4(0.0);
+}