[Piglit] [PATCH 4/4 v2] generators: Add a simple generator for enabled and disabled defines

Dylan Baker baker.dylan.c at gmail.com
Tue Apr 12 20:25:58 UTC 2016


This replaces a large number of handrolled tests (and adds many new
ones) for testing that preprocessor defines are exposed correctly
(either exposed if the extension is enabled, or not if it's disabled)
across all shader stages. It tests for support in legacy (non
core/compat) mode and in profile mode, unless the extension itself
requires GLSL >= 140. It also covers all stages (fs, vs, gs, tcs, tes,
and cs), and both GLES and GL.

It drives all of this from a simple, easily extended list in the
generator, and replaces over 1000 lines of code with about 300,
including the template files, and generates nearly 2000 tests currently.
These are GLSL parser tests and don't take more than a few seconds to
run.

The only known issue is that an extension can not currently be tested in
both GLES and OpenGL.

Signed-off-by: Dylan Baker <dylanx.c.baker at intel.com>
---

v2: - add a template for testing that when an extension isn't available
      it cannot be included. (Ilia)

 generated_tests/CMakeLists.txt                     |   8 +
 generated_tests/gen_extensions_defined.py          | 188 +++++++++++++++++++++
 .../gen_extensions_defined/disabled.glsl.mako      |  40 +++++
 .../gen_extensions_defined/enabled.glsl.mako       |  43 +++++
 .../undefined-require.glsl.mako                    |  17 ++
 tests/all.py                                       |   1 -
 tests/shaders/CMakeLists.gl.txt                    |   1 -
 .../glsl-arb-fragment-coord-conventions-define.c   |  83 ---------
 ...glsl-arb-fragment-coord-conventions-define.frag |  10 --
 .../amd_shader_trinary_minmax/compiler/define.frag |  19 ---
 .../amd_shader_trinary_minmax/compiler/define.vert |  19 ---
 .../arb_derivative_control/compiler/define.frag    |  29 ----
 .../compiler/instanceidarb-disabled.frag           |  25 ---
 .../compiler/instanceidarb-disabled.vert           |  25 ---
 .../compiler/instanceidarb-enabled.frag            |  24 ---
 .../compiler/instanceidarb-enabled.vert            |  24 ---
 .../preprocessor/feature-macro-disabled.frag       |  12 --
 .../preprocessor/feature-macro-disabled.vert       |  12 --
 .../preprocessor/feature-macro-enabled.frag        |  15 --
 .../preprocessor/feature-macro-enabled.vert        |  15 --
 .../spec/arb_enhanced_layouts/compiler/define.frag |  19 ---
 .../spec/arb_enhanced_layouts/compiler/define.vert |  19 ---
 .../1.10/preprocessor/define.frag                  |  19 ---
 .../1.10/preprocessor/define.vert                  |  19 ---
 .../1.20/preprocessor/define.frag                  |  19 ---
 .../1.20/preprocessor/define.vert                  |  19 ---
 .../1.30/preprocessor/define-130.frag              |  19 ---
 .../1.30/preprocessor/define-130.vert              |  19 ---
 .../preprocessor/define.frag                       |  20 ---
 .../preprocessor/define.vert                       |  20 ---
 .../arb_gpu_shader_fp64/preprocessor/define.frag   |  19 ---
 .../arb_gpu_shader_fp64/preprocessor/define.vert   |  19 ---
 .../compiler/1.10/define.frag                      |  18 --
 .../compiler/1.10/define.vert                      |  18 --
 .../compiler/1.20/define.frag                      |  18 --
 .../compiler/1.20/define.vert                      |  18 --
 .../compiler/1.30/define.frag                      |  18 --
 .../compiler/1.30/define.vert                      |  18 --
 .../compiler/1.40/define.frag                      |  18 --
 .../compiler/1.40/define.vert                      |  18 --
 .../compiler/1.50/define.frag                      |  18 --
 .../compiler/1.50/define.geom                      |  18 --
 .../compiler/1.50/define.vert                      |  18 --
 .../preprocessor/define.frag                       |  19 ---
 .../preprocessor/define.vert                       |  19 ---
 .../preprocessor/define.frag                       |  19 ---
 .../preprocessor/define.vert                       |  19 ---
 .../compiler/define.vert                           |  19 ---
 .../preprocessor/define.frag                       |  19 ---
 .../preprocessor/define.vert                       |  19 ---
 .../arb_shader_subroutine/preprocessor/define.vert |  19 ---
 .../arb_tessellation_shader/compiler/define.tesc   |  19 ---
 .../arb_tessellation_shader/compiler/define.tese   |  19 ---
 .../preprocessor/define.frag                       |  19 ---
 .../preprocessor/define.vert                       |  19 ---
 .../preprocessor/define.frag                       |  19 ---
 .../preprocessor/define.vert                       |  19 ---
 .../glsl-1.10/preprocessor/define.frag             |  19 ---
 .../glsl-1.10/preprocessor/define.vert             |  19 ---
 .../glsl-1.50/preprocessor/define.geom             |  18 --
 .../glsl-es-3.10/preprocessor/define.frag          |  19 ---
 .../glsl-es-3.10/preprocessor/define.vert          |  19 ---
 62 files changed, 296 insertions(+), 1102 deletions(-)
 create mode 100644 generated_tests/gen_extensions_defined.py
 create mode 100644 generated_tests/templates/gen_extensions_defined/disabled.glsl.mako
 create mode 100644 generated_tests/templates/gen_extensions_defined/enabled.glsl.mako
 create mode 100644 generated_tests/templates/gen_extensions_defined/undefined-require.glsl.mako
 delete mode 100644 tests/shaders/glsl-arb-fragment-coord-conventions-define.c
 delete mode 100644 tests/shaders/glsl-arb-fragment-coord-conventions-define.frag
 delete mode 100644 tests/spec/amd_shader_trinary_minmax/compiler/define.frag
 delete mode 100644 tests/spec/amd_shader_trinary_minmax/compiler/define.vert
 delete mode 100644 tests/spec/arb_derivative_control/compiler/define.frag
 delete mode 100644 tests/spec/arb_draw_instanced/compiler/instanceidarb-disabled.frag
 delete mode 100644 tests/spec/arb_draw_instanced/compiler/instanceidarb-disabled.vert
 delete mode 100644 tests/spec/arb_draw_instanced/compiler/instanceidarb-enabled.frag
 delete mode 100644 tests/spec/arb_draw_instanced/compiler/instanceidarb-enabled.vert
 delete mode 100644 tests/spec/arb_draw_instanced/preprocessor/feature-macro-disabled.frag
 delete mode 100644 tests/spec/arb_draw_instanced/preprocessor/feature-macro-disabled.vert
 delete mode 100644 tests/spec/arb_draw_instanced/preprocessor/feature-macro-enabled.frag
 delete mode 100644 tests/spec/arb_draw_instanced/preprocessor/feature-macro-enabled.vert
 delete mode 100644 tests/spec/arb_enhanced_layouts/compiler/define.frag
 delete mode 100644 tests/spec/arb_enhanced_layouts/compiler/define.vert
 delete mode 100644 tests/spec/arb_explicit_attrib_location/1.10/preprocessor/define.frag
 delete mode 100644 tests/spec/arb_explicit_attrib_location/1.10/preprocessor/define.vert
 delete mode 100644 tests/spec/arb_explicit_attrib_location/1.20/preprocessor/define.frag
 delete mode 100644 tests/spec/arb_explicit_attrib_location/1.20/preprocessor/define.vert
 delete mode 100644 tests/spec/arb_explicit_attrib_location/1.30/preprocessor/define-130.frag
 delete mode 100644 tests/spec/arb_explicit_attrib_location/1.30/preprocessor/define-130.vert
 delete mode 100644 tests/spec/arb_explicit_uniform_location/preprocessor/define.frag
 delete mode 100644 tests/spec/arb_explicit_uniform_location/preprocessor/define.vert
 delete mode 100644 tests/spec/arb_gpu_shader_fp64/preprocessor/define.frag
 delete mode 100644 tests/spec/arb_gpu_shader_fp64/preprocessor/define.vert
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.10/define.frag
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.10/define.vert
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.20/define.frag
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.20/define.vert
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.30/define.frag
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.30/define.vert
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.40/define.frag
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.40/define.vert
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.50/define.frag
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.50/define.geom
 delete mode 100644 tests/spec/arb_separate_shader_objects/compiler/1.50/define.vert
 delete mode 100644 tests/spec/arb_shader_atomic_counter_ops/preprocessor/define.frag
 delete mode 100644 tests/spec/arb_shader_atomic_counter_ops/preprocessor/define.vert
 delete mode 100644 tests/spec/arb_shader_atomic_counters/preprocessor/define.frag
 delete mode 100644 tests/spec/arb_shader_atomic_counters/preprocessor/define.vert
 delete mode 100644 tests/spec/arb_shader_draw_parameters/compiler/define.vert
 delete mode 100644 tests/spec/arb_shader_storage_buffer_object/preprocessor/define.frag
 delete mode 100644 tests/spec/arb_shader_storage_buffer_object/preprocessor/define.vert
 delete mode 100644 tests/spec/arb_shader_subroutine/preprocessor/define.vert
 delete mode 100644 tests/spec/arb_tessellation_shader/compiler/define.tesc
 delete mode 100644 tests/spec/arb_tessellation_shader/compiler/define.tese
 delete mode 100644 tests/spec/arb_uniform_buffer_object/preprocessor/define.frag
 delete mode 100644 tests/spec/arb_uniform_buffer_object/preprocessor/define.vert
 delete mode 100644 tests/spec/arb_vertex_attrib_64bit/preprocessor/define.frag
 delete mode 100644 tests/spec/arb_vertex_attrib_64bit/preprocessor/define.vert
 delete mode 100644 tests/spec/ext_shader_samples_identical/glsl-1.10/preprocessor/define.frag
 delete mode 100644 tests/spec/ext_shader_samples_identical/glsl-1.10/preprocessor/define.vert
 delete mode 100644 tests/spec/ext_shader_samples_identical/glsl-1.50/preprocessor/define.geom
 delete mode 100644 tests/spec/ext_shader_samples_identical/glsl-es-3.10/preprocessor/define.frag
 delete mode 100644 tests/spec/ext_shader_samples_identical/glsl-es-3.10/preprocessor/define.vert

diff --git a/generated_tests/CMakeLists.txt b/generated_tests/CMakeLists.txt
index 0dc617b..296a652 100644
--- a/generated_tests/CMakeLists.txt
+++ b/generated_tests/CMakeLists.txt
@@ -132,6 +132,13 @@ piglit_make_generated_tests(
 	templates/gen_variable_index_read_tests/vs.shader_test.mako
 	templates/gen_variable_index_read_tests/fs.shader_test.mako
 	templates/gen_variable_index_read_tests/helpers.mako)
+piglit_make_generated_tests(
+	gen_extensions_defined.list
+	gen_extensions_defined.py
+	templates/gen_extensions_defined/enabled.glsl.mako
+	templates/gen_extensions_defined/disabled.glsl.mako
+	templates/gen_extensions_defined/undefined-require.glsl.mako
+	modules/glsl.py)
 
 # OpenCL Test generators
 piglit_make_generated_tests(
@@ -176,6 +183,7 @@ add_custom_target(gen-gl-tests
 			shader_precision_tests.list
 			shader_image_load_store_tests.list
 			variable_index_read_tests.list
+			gen_extensions_defined.list
 )
 
 # Create a custom target for generating OpenCL tests
diff --git a/generated_tests/gen_extensions_defined.py b/generated_tests/gen_extensions_defined.py
new file mode 100644
index 0000000..e054e6d
--- /dev/null
+++ b/generated_tests/gen_extensions_defined.py
@@ -0,0 +1,188 @@
+# encoding=utf-8
+# Copyright © 2016 Intel Corporation
+
+# Permission is hereby granted, free of charge, to any person obtaining a copy
+# of this software and associated documentation files (the "Software"), to deal
+# in the Software without restriction, including without limitation the rights
+# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+# copies of the Software, and to permit persons to whom the Software is
+# furnished to do so, subject to the following conditions:
+
+# The above copyright notice and this permission notice shall be included in
+# all copies or substantial portions of the Software.
+
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+# SOFTWARE.
+
+"""Generate tests for extensions that affect the shading language.
+
+This generates three tests per extensions.
+- The first test asserts that if the extension is required it's defined
+- The second test asserts that if the extension isn't available it's not
+  defined
+- The third test asserts that if the extension isn't available trying to
+  require it is an error.
+
+These are glslparsertests.
+
+For extensions that require an OpenGL version < 140 (without profiles) a test
+will be generated for that version with '-legacy' appended to the name, and a
+version for 140 that adds '-profile'. If the extension requires >= 140 then
+only a single test with no appended value will be generated.
+
+For OpenGL ES only one test will be generated, it will have no extra name
+added.
+
+"""
+
+from __future__ import (
+    absolute_import, division, print_function, unicode_literals
+)
+import os
+
+from templates import template_dir
+from modules import utils, glsl
+
+_TEMPLATES = template_dir(os.path.basename(os.path.splitext(__file__)[0]))
+ENABLED_TEMPLATE = _TEMPLATES.get_template('enabled.glsl.mako')
+DISABLED_TEMPLATE = _TEMPLATES.get_template('disabled.glsl.mako')
+UNDEFINED_TEMPLATE = _TEMPLATES.get_template('undefined-require.glsl.mako')
+
+# A list of tuples with the full preprocess defined name, and the minimum
+# supported version of that extension.
+EXTENSIONS = [
+    ("GL_ARB_draw_instanced", "110"),
+    ("GL_ARB_draw_buffers", "110"),
+    ("GL_ARB_enhanced_layouts", "140"),
+    ("GL_ARB_separate_shader_objects", "110"),
+    ("GL_ARB_texture_rectangle", "110"),
+    ("GL_AMD_shader_trinary_minmax", "110"),
+    ("GL_EXT_texture_array", "110"),
+    ("GL_ARB_ES3_1_compatibility", "110"),
+    ("GL_ARB_arrays_of_arrays", "110"),
+    ("GL_ARB_fragment_coord_conventions", "110"),
+    ("GL_ARB_fragment_layer_viewport", "110"),
+    ("GL_ARB_explicit_attrib_location", "110"),
+    ("GL_ARB_explicit_uniform_location", "110"),
+    ("GL_ARB_shader_texture_lod", "110"),
+    ("GL_AMD_conservative_depth", "110"),
+    ("GL_ARB_conservative_depth", "110"),
+    ("GL_ARB_shader_bit_encodign", "110"),
+    ("GL_ARB_shader_clock", "110"),
+    ("GL_ARB_uniform_buffer_object", "110"),
+    ("GL_ARB_texture_cube_map_array", "110"),
+    ("GL_ARB_shading_language_packing", "110"),
+    ("GL_ARB_texture_multisample", "110"),
+    ("GL_ARB_texture_query_levels", "110"),
+    ("GL_ARB_texture_query_lod", "110"),
+    ("GL_ARB_gpu_shader5", "110"),
+    ("GL_ARB_gpu_shader_fp64", "150"),
+    ("GL_ARB_vertex_attrib_64bit", "150"),
+    ("GL_AMD_vertex_shader_layer", "110"),
+    ("GL_AMD_vertex_shader_viewport_index", "110"),
+    ("GL_ARB_shading_language_420pack", "110"),
+    ("GL_ARB_sample_shading", "110"),
+    ("GL_ARB_texture_gather", "110"),
+    ("GL_ARB_shader_atomic_counters", "110"),
+    ("GL_ARB_shader_atomic_counter_ops", "140"),
+    ("GL_ARB_viewport_array", "110"),
+    ("GL_ARB_compute_shader", "110"),
+    ("GL_ARB_shader_image_load_store", "110"),
+    ("GL_ARB_shader_image_size", "110"),
+    ("GL_ARB_shader_texture_image_samples", "110"),
+    # That is what the original hand written test required.
+    ("GL_ARB_derivative_control", "150"),
+    ("GL_ARB_shader_precision", "110"),
+    ("GL_ARB_shader_storage_buffer_object", "110"),
+    ("GL_ARB_tessellation_shader", "150"),
+    ("GL_ARB_shader_subroutine", "150"),
+    ("GL_ARB_shader_draw_parameters", "140"),
+    ("GL_EXT_separate_shader_objects", "100"),
+    ("GL_EXT_draw_buffers", "100"),
+    ("GL_AMD_shader_stencil_export", "120"),
+    ("GL_ARB_shader_stencil_export", "120"),
+    ("GL_ARB_geometry_shader4", "110"),
+    ("GL_OES_EGL_image_external", "100"),
+    ("GL_EXT_shader_samples_identical", "110"),
+    ("GL_EXT_shader_samples_identical", "310 es"),
+    ("GL_OES_sample_variables", "300 es"),
+    ("GL_OES_multisample_interpolation", "300 es"),
+    ("GL_OES_standard_derivatives", "100"),
+    ("GL_OES_texture_storage_multisample_2d_array", "300 es"),
+    ("GL_OES_blend_func_extended", "100"),
+    ("GL_OES_shader_image_atomic", "310 es"),
+    ("GL_OES_geometry_shader", "310 es"),
+    ("GL_OES_geometry_point_size", "310 es"),
+    ("GL_EXT_gpu_shader5", "310 es"),
+    ("GL_OES_gpu_shader5", "310 es"),
+    ("GL_EXT_texture_buffer", "310 es"),
+    ("GL_OES_texture_buffer", "310 es"),
+]
+EXTENSIONS = [(n, glsl.Version(v)) for n, v in EXTENSIONS]
+
+_EXTRA_REQUIRES = {
+    'tesc': ['GL_ARB_tessellation_shader'],
+    'tese': ['GL_ARB_tessellation_shader'],
+    'comp': ['GL_ARB_compute_shader'],
+}
+
+
+def _gen_tests(ext, ver, stage, path, extra_name=''):
+    """Generate the actual test files.
+
+    This generates both a disabled test for both disabled and enabled
+    configurations.
+
+    Argments:
+    ext -- the extension to be tested
+    ver -- the minimum required version
+    stage -- the shader stage to test
+    path -- the path to put the test in, without the test name
+
+    Keyword Arguments:
+    extra_name -- An extra string to put in the test name. Default: ''
+
+    """
+    extra_extensions = _EXTRA_REQUIRES.get(stage, [])
+    version = glsl.MinVersion.for_stage(stage, ver)
+
+    for test, template in [('enabled', ENABLED_TEMPLATE),
+                           ('disabled-defined', DISABLED_TEMPLATE),
+                           ('disabled-undefined', UNDEFINED_TEMPLATE)]:
+        name = os.path.join(path, '{}{}.{}'.format(test, extra_name, stage))
+
+        # Open in bytes mode to avoid weirdness in python 2/3 compatibility
+        with open(name, 'wb') as f:
+            f.write(template.render(
+                version=version,
+                extension=ext,
+                extra_extensions=extra_extensions))
+        print(name)
+
+
+def main():
+    """Main function."""
+    for ext, ver in EXTENSIONS:
+        # Lower ext in the path name, but keep it capitalized for the generated
+        # tests
+        path = os.path.join('spec', ext[3:].lower(), 'preprocessor')
+        utils.safe_makedirs(path)
+
+        for stage in ['vert', 'frag', 'geom', 'tesc', 'tese', 'comp']:
+            # If the version is less than 140, generate two tests. One for
+            # legacy (without profiles) and one for profiles.
+            if not ver.is_es and ver < 140:
+                _gen_tests(ext, ver, stage, path, extra_name='-legacy')
+                _gen_tests(ext, glsl.Version('140'), stage, path,
+                           extra_name='-profile')
+            else:
+                _gen_tests(ext, ver, stage, path)
+
+
+if __name__ == '__main__':
+    main()
diff --git a/generated_tests/templates/gen_extensions_defined/disabled.glsl.mako b/generated_tests/templates/gen_extensions_defined/disabled.glsl.mako
new file mode 100644
index 0000000..f4fc92f
--- /dev/null
+++ b/generated_tests/templates/gen_extensions_defined/disabled.glsl.mako
@@ -0,0 +1,40 @@
+## encoding=utf-8
+## Copyright © 2016 Intel Corporation
+##
+## Permission is hereby granted, free of charge, to any person obtaining a copy
+## of this software and associated documentation files (the "Software"), to deal
+## in the Software without restriction, including without limitation the rights
+## to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+## copies of the Software, and to permit persons to whom the Software is
+## furnished to do so, subject to the following conditions:
+##
+## The above copyright notice and this permission notice shall be included in
+## all copies or substantial portions of the Software.
+##
+## THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+## IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+## FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+## AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+## LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+## OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+## SOFTWARE.
+/* This is a generated test, do not edit
+ * Generated by gen_extensions_defined.py
+ *
+ * [config]
+ * expect_result: pass
+ * glsl_version: ${version.print_float()}
+ * require_extensions: !${extension} ${' '.join(extra_extensions)}
+ * [end config]
+ */
+
+#version ${str(version)}
+% for ext in extra_extensions:
+  #extension ${ext} : require
+% endfor
+
+#if defined ${extension}
+#    error ${extension} is defined, but should not be
+#endif
+
+float foo() { return 0.0; }
diff --git a/generated_tests/templates/gen_extensions_defined/enabled.glsl.mako b/generated_tests/templates/gen_extensions_defined/enabled.glsl.mako
new file mode 100644
index 0000000..09a82fa
--- /dev/null
+++ b/generated_tests/templates/gen_extensions_defined/enabled.glsl.mako
@@ -0,0 +1,43 @@
+## encoding=utf-8
+## Copyright © 2016 Intel Corporation
+##
+## Permission is hereby granted, free of charge, to any person obtaining a copy
+## of this software and associated documentation files (the "Software"), to deal
+## in the Software without restriction, including without limitation the rights
+## to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+## copies of the Software, and to permit persons to whom the Software is
+## furnished to do so, subject to the following conditions:
+##
+## The above copyright notice and this permission notice shall be included in
+## all copies or substantial portions of the Software.
+##
+## THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+## IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+## FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+## AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+## LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+## OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+## SOFTWARE.
+/* This is a generated test, do not edit
+ * Generated by gen_extensions_defined.py
+ *
+ * [config]
+ * expect_result: pass
+ * glsl_version: ${version.print_float()}
+ * require_extensions: ${extension} ${' '.join(extra_extensions)}
+ * [end config]
+ */
+
+#version ${str(version)}
+#extension ${extension} : require
+% for ext in extra_extensions:
+  #extension ${ext} : require
+% endfor
+
+#if !defined ${extension}
+#    error ${extension} is not defined
+#elif ${extension} != 1
+#    error ${extension} != 1
+#endif
+
+float foo() { return 0.0; }
diff --git a/generated_tests/templates/gen_extensions_defined/undefined-require.glsl.mako b/generated_tests/templates/gen_extensions_defined/undefined-require.glsl.mako
new file mode 100644
index 0000000..e129e85
--- /dev/null
+++ b/generated_tests/templates/gen_extensions_defined/undefined-require.glsl.mako
@@ -0,0 +1,17 @@
+/* This is a generated test, do not edit
+ * Generated by gen_extensinos_defined.py
+ *
+ * [config]
+ * expect_result: fail
+ * glsl_version: ${version.print_float()}
+ * require_extensions: !${extension} ${' '.join(extra_extensions)}
+ * [end config]
+ */
+
+#version ${str(version)}
+% for ext in extra_extensions:
+  #extension ${ext}: require
+% endfor
+#extension ${extension} : require
+
+float foo() { return 0.0; }
diff --git a/tests/all.py b/tests/all.py
index c7088ca..898d061 100644
--- a/tests/all.py
+++ b/tests/all.py
@@ -490,7 +490,6 @@ with profile.group_manager(PiglitGLTest, 'shaders') as g:
     g(['createshaderprogram-bad-type'])
     g(['createshaderprogram-attached-shaders'])
     g(['glsl-arb-fragment-coord-conventions'])
-    g(['glsl-arb-fragment-coord-conventions-define'])
     g(['glsl-bug-22603'])
     g(['glsl-bindattriblocation'])
     g(['glsl-dlist-getattriblocation'])
diff --git a/tests/shaders/CMakeLists.gl.txt b/tests/shaders/CMakeLists.gl.txt
index 42c6fae..afbcc4b 100644
--- a/tests/shaders/CMakeLists.gl.txt
+++ b/tests/shaders/CMakeLists.gl.txt
@@ -43,7 +43,6 @@ IF (UNIX)
 	target_link_libraries(fp-unpack-01 m)
 ENDIF (UNIX)
 piglit_add_executable (glsl-arb-fragment-coord-conventions glsl-arb-fragment-coord-conventions.c)
-piglit_add_executable (glsl-arb-fragment-coord-conventions-define glsl-arb-fragment-coord-conventions-define.c)
 piglit_add_executable (glsl-bindattriblocation glsl-bindattriblocation.c)
 piglit_add_executable (glsl-bug-22603 glsl-bug-22603.c)
 piglit_add_executable (glsl-dlist-getattriblocation glsl-dlist-getattriblocation.c)
diff --git a/tests/shaders/glsl-arb-fragment-coord-conventions-define.c b/tests/shaders/glsl-arb-fragment-coord-conventions-define.c
deleted file mode 100644
index bc30a96..0000000
--- a/tests/shaders/glsl-arb-fragment-coord-conventions-define.c
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * Copyright © 2009 Intel Corporation
- *
- * Permission is hereby granted, free of charge, to any person obtaining a
- * copy of this software and associated documentation files (the "Software"),
- * to deal in the Software without restriction, including without limitation
- * the rights to use, copy, modify, merge, publish, distribute, sublicense,
- * and/or sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice (including the next
- * paragraph) shall be included in all copies or substantial portions of the
- * Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
- * IN THE SOFTWARE.
- *
- * Authors:
- *    Eric Anholt <eric at anholt.net>
- *
- */
-
-/** @file glsl-arb-fragment-coord-conventions-define.c
- *
- * Tests that the ARB_fragment_coord_conventions extension define is present
- * when the extension is exposed.
- */
-
-#include "piglit-util-gl.h"
-
-PIGLIT_GL_TEST_CONFIG_BEGIN
-
-	config.supports_gl_compat_version = 10;
-
-	config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE;
-
-PIGLIT_GL_TEST_CONFIG_END
-
-static GLint prog;
-
-enum piglit_result
-piglit_display(void)
-{
-	GLboolean pass = GL_TRUE;
-	static const float green[] = {0.0, 1.0, 0.0, 0.0};
-
-	glClearColor(1.0, 0.0, 0.0, 0.0);
-	glClear(GL_COLOR_BUFFER_BIT);
-
-	piglit_draw_rect(0, 0, piglit_width, piglit_height);
-
-	pass &= piglit_probe_pixel_rgb(15, 15, green);
-
-	piglit_present_results();
-
-	return pass ? PIGLIT_PASS : PIGLIT_FAIL;
-}
-
-void
-piglit_init(int argc, char **argv)
-{
-	GLint vs, fs;
-
-	piglit_require_gl_version(20);
-
-	piglit_require_extension("GL_ARB_fragment_coord_conventions");
-
-	piglit_ortho_projection(piglit_width, piglit_height, GL_FALSE);
-
-	vs = piglit_compile_shader(GL_VERTEX_SHADER,
-				   "shaders/glsl-mvp.vert");
-	fs = piglit_compile_shader(GL_FRAGMENT_SHADER,
-				   "shaders/glsl-arb-fragment-coord-conventions-define.frag");
-
-	prog = piglit_link_simple_program(vs, fs);
-
-	glUseProgram(prog);
-}
diff --git a/tests/shaders/glsl-arb-fragment-coord-conventions-define.frag b/tests/shaders/glsl-arb-fragment-coord-conventions-define.frag
deleted file mode 100644
index 645f77f..0000000
--- a/tests/shaders/glsl-arb-fragment-coord-conventions-define.frag
+++ /dev/null
@@ -1,10 +0,0 @@
-#extension GL_ARB_fragment_coord_conventions : warn
-
-void main()
-{
-#ifdef GL_ARB_fragment_coord_conventions
-		gl_FragColor = vec4(0.0, 1.0, 0.0, 0.0);
-#else
-		gl_FragColor = vec4(1.0, 0.0, 0.0, 0.0);
-#endif
-}
diff --git a/tests/spec/amd_shader_trinary_minmax/compiler/define.frag b/tests/spec/amd_shader_trinary_minmax/compiler/define.frag
deleted file mode 100644
index b1931cf..0000000
--- a/tests/spec/amd_shader_trinary_minmax/compiler/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_AMD_shader_trinary_minmax
-// [end config]
-
-#version 110
-#extension GL_AMD_shader_trinary_minmax: require
-
-#if !defined GL_AMD_shader_trinary_minmax
-#  error GL_AMD_shader_trinary_minmax is not defined
-#elif GL_AMD_shader_trinary_minmax != 1
-#  error GL_AMD_shader_trinary_minmax is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/amd_shader_trinary_minmax/compiler/define.vert b/tests/spec/amd_shader_trinary_minmax/compiler/define.vert
deleted file mode 100644
index b1931cf..0000000
--- a/tests/spec/amd_shader_trinary_minmax/compiler/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_AMD_shader_trinary_minmax
-// [end config]
-
-#version 110
-#extension GL_AMD_shader_trinary_minmax: require
-
-#if !defined GL_AMD_shader_trinary_minmax
-#  error GL_AMD_shader_trinary_minmax is not defined
-#elif GL_AMD_shader_trinary_minmax != 1
-#  error GL_AMD_shader_trinary_minmax is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_derivative_control/compiler/define.frag b/tests/spec/arb_derivative_control/compiler/define.frag
deleted file mode 100644
index 4e31dd7..0000000
--- a/tests/spec/arb_derivative_control/compiler/define.frag
+++ /dev/null
@@ -1,29 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_derivative_control
-// [end config]
-
-#version 150
-#extension GL_ARB_derivative_control: require
-
-#if !defined GL_ARB_derivative_control
-#  error GL_ARB_derivative_control is not defined
-#elif GL_ARB_derivative_control != 1
-#  error GL_ARB_derivative_control is not equal to 1
-#endif
-
-/* Make sure that the functions are defined */
-in vec4 val;
-out vec4 color;
-void main() {
-  color = dFdx(val);
-  color += dFdy(val);
-  color += fwidth(val);
-  color += dFdxCoarse(val);
-  color += dFdyCoarse(val);
-  color += fwidthCoarse(val);
-  color += dFdxFine(val);
-  color += dFdyFine(val);
-  color += fwidthFine(val);
-}
diff --git a/tests/spec/arb_draw_instanced/compiler/instanceidarb-disabled.frag b/tests/spec/arb_draw_instanced/compiler/instanceidarb-disabled.frag
deleted file mode 100644
index 54d5200..0000000
--- a/tests/spec/arb_draw_instanced/compiler/instanceidarb-disabled.frag
+++ /dev/null
@@ -1,25 +0,0 @@
-/* [config]
- * expect_result: fail
- * glsl_version: 1.10
- * require_extensions: GL_ARB_draw_instanced
- * [end config]
- *
- * From the GL_ARB_draw_instanced spec:
- *
- *     "Change Section 7.1 "Vertex Shader Special Variables"
- *
- *     Add the following definition to the list of built-in variable
- *     definitions:
- *
- *          int gl_InstanceIDARB // read-only"
- *
- * There is no mention of gl_InstanceIDARB in fragment shaders or
- * geometry shaders.
- *
- * This test does not enable the extension before using gl_InstanceIDARB.
- */
-
-int function()
-{
-  return gl_InstanceIDARB;
-}
diff --git a/tests/spec/arb_draw_instanced/compiler/instanceidarb-disabled.vert b/tests/spec/arb_draw_instanced/compiler/instanceidarb-disabled.vert
deleted file mode 100644
index 54d5200..0000000
--- a/tests/spec/arb_draw_instanced/compiler/instanceidarb-disabled.vert
+++ /dev/null
@@ -1,25 +0,0 @@
-/* [config]
- * expect_result: fail
- * glsl_version: 1.10
- * require_extensions: GL_ARB_draw_instanced
- * [end config]
- *
- * From the GL_ARB_draw_instanced spec:
- *
- *     "Change Section 7.1 "Vertex Shader Special Variables"
- *
- *     Add the following definition to the list of built-in variable
- *     definitions:
- *
- *          int gl_InstanceIDARB // read-only"
- *
- * There is no mention of gl_InstanceIDARB in fragment shaders or
- * geometry shaders.
- *
- * This test does not enable the extension before using gl_InstanceIDARB.
- */
-
-int function()
-{
-  return gl_InstanceIDARB;
-}
diff --git a/tests/spec/arb_draw_instanced/compiler/instanceidarb-enabled.frag b/tests/spec/arb_draw_instanced/compiler/instanceidarb-enabled.frag
deleted file mode 100644
index a59afca..0000000
--- a/tests/spec/arb_draw_instanced/compiler/instanceidarb-enabled.frag
+++ /dev/null
@@ -1,24 +0,0 @@
-/* [config]
- * expect_result: fail
- * glsl_version: 1.10
- * require_extensions: GL_ARB_draw_instanced
- * [end config]
- *
- * From the GL_ARB_draw_instanced spec:
- *
- *     "Change Section 7.1 "Vertex Shader Special Variables"
- *
- *     Add the following definition to the list of built-in variable
- *     definitions:
- *
- *          int gl_InstanceIDARB // read-only"
- *
- * There is no mention of gl_InstanceIDARB in fragment shaders or
- * geometry shaders.
- */
-#extension GL_ARB_draw_instanced: require
-
-int function()
-{
-  return gl_InstanceIDARB;
-}
diff --git a/tests/spec/arb_draw_instanced/compiler/instanceidarb-enabled.vert b/tests/spec/arb_draw_instanced/compiler/instanceidarb-enabled.vert
deleted file mode 100644
index beb4a9c..0000000
--- a/tests/spec/arb_draw_instanced/compiler/instanceidarb-enabled.vert
+++ /dev/null
@@ -1,24 +0,0 @@
-/* [config]
- * expect_result: pass
- * glsl_version: 1.10
- * require_extensions: GL_ARB_draw_instanced
- * [end config]
- *
- * From the GL_ARB_draw_instanced spec:
- *
- *     "Change Section 7.1 "Vertex Shader Special Variables"
- *
- *     Add the following definition to the list of built-in variable
- *     definitions:
- *
- *          int gl_InstanceIDARB // read-only"
- *
- * There is no mention of gl_InstanceIDARB in fragment shaders or
- * geometry shaders.
- */
-#extension GL_ARB_draw_instanced: require
-
-int function()
-{
-  return gl_InstanceIDARB;
-}
diff --git a/tests/spec/arb_draw_instanced/preprocessor/feature-macro-disabled.frag b/tests/spec/arb_draw_instanced/preprocessor/feature-macro-disabled.frag
deleted file mode 100644
index 0f95e1b..0000000
--- a/tests/spec/arb_draw_instanced/preprocessor/feature-macro-disabled.frag
+++ /dev/null
@@ -1,12 +0,0 @@
-/* [config]
- * expect_result: pass
- * glsl_version: 1.10
- * require_extensions: !GL_ARB_draw_instanced
- * [end config]
- */
-
-#if defined GL_ARB_draw_instanced
-#    error GL_ARB_draw_instanced is defined, but should not be
-#endif
-
-float foo() { return 0.0; }
diff --git a/tests/spec/arb_draw_instanced/preprocessor/feature-macro-disabled.vert b/tests/spec/arb_draw_instanced/preprocessor/feature-macro-disabled.vert
deleted file mode 100644
index 0f95e1b..0000000
--- a/tests/spec/arb_draw_instanced/preprocessor/feature-macro-disabled.vert
+++ /dev/null
@@ -1,12 +0,0 @@
-/* [config]
- * expect_result: pass
- * glsl_version: 1.10
- * require_extensions: !GL_ARB_draw_instanced
- * [end config]
- */
-
-#if defined GL_ARB_draw_instanced
-#    error GL_ARB_draw_instanced is defined, but should not be
-#endif
-
-float foo() { return 0.0; }
diff --git a/tests/spec/arb_draw_instanced/preprocessor/feature-macro-enabled.frag b/tests/spec/arb_draw_instanced/preprocessor/feature-macro-enabled.frag
deleted file mode 100644
index 766424c..0000000
--- a/tests/spec/arb_draw_instanced/preprocessor/feature-macro-enabled.frag
+++ /dev/null
@@ -1,15 +0,0 @@
-/* [config]
- * expect_result: pass
- * glsl_version: 1.10
- * require_extensions: GL_ARB_draw_instanced
- * [end config]
- */
-#extension GL_ARB_draw_instanced: require
-
-#if !defined GL_ARB_draw_instanced
-#    error GL_ARB_draw_instanced is not defined
-#elif GL_ARB_draw_instanced != 1
-#    error GL_ARB_draw_instanced != 1
-#endif
-
-float foo() { return 0.0; }
diff --git a/tests/spec/arb_draw_instanced/preprocessor/feature-macro-enabled.vert b/tests/spec/arb_draw_instanced/preprocessor/feature-macro-enabled.vert
deleted file mode 100644
index 766424c..0000000
--- a/tests/spec/arb_draw_instanced/preprocessor/feature-macro-enabled.vert
+++ /dev/null
@@ -1,15 +0,0 @@
-/* [config]
- * expect_result: pass
- * glsl_version: 1.10
- * require_extensions: GL_ARB_draw_instanced
- * [end config]
- */
-#extension GL_ARB_draw_instanced: require
-
-#if !defined GL_ARB_draw_instanced
-#    error GL_ARB_draw_instanced is not defined
-#elif GL_ARB_draw_instanced != 1
-#    error GL_ARB_draw_instanced != 1
-#endif
-
-float foo() { return 0.0; }
diff --git a/tests/spec/arb_enhanced_layouts/compiler/define.frag b/tests/spec/arb_enhanced_layouts/compiler/define.frag
deleted file mode 100644
index 4d52cf4..0000000
--- a/tests/spec/arb_enhanced_layouts/compiler/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.40
-// require_extensions: GL_ARB_enhanced_layouts
-// [end config]
-
-#version 140
-#extension GL_ARB_enhanced_layouts: require
-
-#if !defined GL_ARB_enhanced_layouts
-#  error GL_ARB_enhanced_layouts is not defined
-#elif GL_ARB_enhanced_layouts != 1
-#  error GL_ARB_enhanced_layouts is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_enhanced_layouts/compiler/define.vert b/tests/spec/arb_enhanced_layouts/compiler/define.vert
deleted file mode 100644
index 4d52cf4..0000000
--- a/tests/spec/arb_enhanced_layouts/compiler/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.40
-// require_extensions: GL_ARB_enhanced_layouts
-// [end config]
-
-#version 140
-#extension GL_ARB_enhanced_layouts: require
-
-#if !defined GL_ARB_enhanced_layouts
-#  error GL_ARB_enhanced_layouts is not defined
-#elif GL_ARB_enhanced_layouts != 1
-#  error GL_ARB_enhanced_layouts is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_explicit_attrib_location/1.10/preprocessor/define.frag b/tests/spec/arb_explicit_attrib_location/1.10/preprocessor/define.frag
deleted file mode 100644
index 7e03a53..0000000
--- a/tests/spec/arb_explicit_attrib_location/1.10/preprocessor/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_ARB_explicit_attrib_location
-// [end config]
-
-#version 110
-#extension GL_ARB_explicit_attrib_location: require
-
-#if !defined GL_ARB_explicit_attrib_location
-#  error GL_ARB_explicit_attrib_location is not defined
-#elif GL_ARB_explicit_attrib_location != 1
-#  error GL_ARB_explicit_attrib_location is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_explicit_attrib_location/1.10/preprocessor/define.vert b/tests/spec/arb_explicit_attrib_location/1.10/preprocessor/define.vert
deleted file mode 100644
index 7e03a53..0000000
--- a/tests/spec/arb_explicit_attrib_location/1.10/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_ARB_explicit_attrib_location
-// [end config]
-
-#version 110
-#extension GL_ARB_explicit_attrib_location: require
-
-#if !defined GL_ARB_explicit_attrib_location
-#  error GL_ARB_explicit_attrib_location is not defined
-#elif GL_ARB_explicit_attrib_location != 1
-#  error GL_ARB_explicit_attrib_location is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_explicit_attrib_location/1.20/preprocessor/define.frag b/tests/spec/arb_explicit_attrib_location/1.20/preprocessor/define.frag
deleted file mode 100644
index f89761c..0000000
--- a/tests/spec/arb_explicit_attrib_location/1.20/preprocessor/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.20
-// require_extensions: GL_ARB_explicit_attrib_location
-// [end config]
-
-#version 120
-#extension GL_ARB_explicit_attrib_location: require
-
-#if !defined GL_ARB_explicit_attrib_location
-#  error GL_ARB_explicit_attrib_location is not defined
-#elif GL_ARB_explicit_attrib_location != 1
-#  error GL_ARB_explicit_attrib_location is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_explicit_attrib_location/1.20/preprocessor/define.vert b/tests/spec/arb_explicit_attrib_location/1.20/preprocessor/define.vert
deleted file mode 100644
index f89761c..0000000
--- a/tests/spec/arb_explicit_attrib_location/1.20/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.20
-// require_extensions: GL_ARB_explicit_attrib_location
-// [end config]
-
-#version 120
-#extension GL_ARB_explicit_attrib_location: require
-
-#if !defined GL_ARB_explicit_attrib_location
-#  error GL_ARB_explicit_attrib_location is not defined
-#elif GL_ARB_explicit_attrib_location != 1
-#  error GL_ARB_explicit_attrib_location is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_explicit_attrib_location/1.30/preprocessor/define-130.frag b/tests/spec/arb_explicit_attrib_location/1.30/preprocessor/define-130.frag
deleted file mode 100644
index e9a3917..0000000
--- a/tests/spec/arb_explicit_attrib_location/1.30/preprocessor/define-130.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.30
-// require_extensions: GL_ARB_explicit_attrib_location
-// [end config]
-
-#version 130
-#extension GL_ARB_explicit_attrib_location: require
-
-#if !defined GL_ARB_explicit_attrib_location
-#  error GL_ARB_explicit_attrib_location is not defined
-#elif GL_ARB_explicit_attrib_location != 1
-#  error GL_ARB_explicit_attrib_location is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_explicit_attrib_location/1.30/preprocessor/define-130.vert b/tests/spec/arb_explicit_attrib_location/1.30/preprocessor/define-130.vert
deleted file mode 100644
index e9a3917..0000000
--- a/tests/spec/arb_explicit_attrib_location/1.30/preprocessor/define-130.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.30
-// require_extensions: GL_ARB_explicit_attrib_location
-// [end config]
-
-#version 130
-#extension GL_ARB_explicit_attrib_location: require
-
-#if !defined GL_ARB_explicit_attrib_location
-#  error GL_ARB_explicit_attrib_location is not defined
-#elif GL_ARB_explicit_attrib_location != 1
-#  error GL_ARB_explicit_attrib_location is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_explicit_uniform_location/preprocessor/define.frag b/tests/spec/arb_explicit_uniform_location/preprocessor/define.frag
deleted file mode 100644
index c88dd73..0000000
--- a/tests/spec/arb_explicit_uniform_location/preprocessor/define.frag
+++ /dev/null
@@ -1,20 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.30
-// require_extensions: GL_ARB_explicit_attrib_location GL_ARB_explicit_uniform_location
-// [end config]
-
-#version 130
-#extension GL_ARB_explicit_attrib_location: require
-#extension GL_ARB_explicit_uniform_location: require
-
-#if !defined GL_ARB_explicit_uniform_location
-#  error GL_ARB_explicit_uniform_location is not defined
-#elif GL_ARB_explicit_uniform_location != 1
-#  error GL_ARB_explicit_uniform_location is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_explicit_uniform_location/preprocessor/define.vert b/tests/spec/arb_explicit_uniform_location/preprocessor/define.vert
deleted file mode 100644
index c88dd73..0000000
--- a/tests/spec/arb_explicit_uniform_location/preprocessor/define.vert
+++ /dev/null
@@ -1,20 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.30
-// require_extensions: GL_ARB_explicit_attrib_location GL_ARB_explicit_uniform_location
-// [end config]
-
-#version 130
-#extension GL_ARB_explicit_attrib_location: require
-#extension GL_ARB_explicit_uniform_location: require
-
-#if !defined GL_ARB_explicit_uniform_location
-#  error GL_ARB_explicit_uniform_location is not defined
-#elif GL_ARB_explicit_uniform_location != 1
-#  error GL_ARB_explicit_uniform_location is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_gpu_shader_fp64/preprocessor/define.frag b/tests/spec/arb_gpu_shader_fp64/preprocessor/define.frag
deleted file mode 100644
index 85dd9bf..0000000
--- a/tests/spec/arb_gpu_shader_fp64/preprocessor/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_gpu_shader_fp64
-// [end config]
-
-#version 150
-#extension GL_ARB_gpu_shader_fp64: require
-
-#if !defined GL_ARB_gpu_shader_fp64
-#  error GL_ARB_gpu_shader_fp64 is not defined
-#elif GL_ARB_gpu_shader_fp64 != 1
-#  error GL_ARB_gpu_shader_fp64 is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_gpu_shader_fp64/preprocessor/define.vert b/tests/spec/arb_gpu_shader_fp64/preprocessor/define.vert
deleted file mode 100644
index 85dd9bf..0000000
--- a/tests/spec/arb_gpu_shader_fp64/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_gpu_shader_fp64
-// [end config]
-
-#version 150
-#extension GL_ARB_gpu_shader_fp64: require
-
-#if !defined GL_ARB_gpu_shader_fp64
-#  error GL_ARB_gpu_shader_fp64 is not defined
-#elif GL_ARB_gpu_shader_fp64 != 1
-#  error GL_ARB_gpu_shader_fp64 is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.10/define.frag b/tests/spec/arb_separate_shader_objects/compiler/1.10/define.frag
deleted file mode 100644
index 8ea068b..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.10/define.frag
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 110
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.10/define.vert b/tests/spec/arb_separate_shader_objects/compiler/1.10/define.vert
deleted file mode 100644
index 8ea068b..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.10/define.vert
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 110
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.20/define.frag b/tests/spec/arb_separate_shader_objects/compiler/1.20/define.frag
deleted file mode 100644
index fac81b9..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.20/define.frag
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.20
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 120
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.20/define.vert b/tests/spec/arb_separate_shader_objects/compiler/1.20/define.vert
deleted file mode 100644
index fac81b9..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.20/define.vert
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.20
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 120
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.30/define.frag b/tests/spec/arb_separate_shader_objects/compiler/1.30/define.frag
deleted file mode 100644
index ddccb6e..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.30/define.frag
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.30
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 130
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.30/define.vert b/tests/spec/arb_separate_shader_objects/compiler/1.30/define.vert
deleted file mode 100644
index ddccb6e..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.30/define.vert
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.30
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 130
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.40/define.frag b/tests/spec/arb_separate_shader_objects/compiler/1.40/define.frag
deleted file mode 100644
index 9ae5932..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.40/define.frag
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.40
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 140
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.40/define.vert b/tests/spec/arb_separate_shader_objects/compiler/1.40/define.vert
deleted file mode 100644
index 9ae5932..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.40/define.vert
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.40
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 140
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.50/define.frag b/tests/spec/arb_separate_shader_objects/compiler/1.50/define.frag
deleted file mode 100644
index ae1f2e9..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.50/define.frag
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 150
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.50/define.geom b/tests/spec/arb_separate_shader_objects/compiler/1.50/define.geom
deleted file mode 100644
index ae1f2e9..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.50/define.geom
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 150
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_separate_shader_objects/compiler/1.50/define.vert b/tests/spec/arb_separate_shader_objects/compiler/1.50/define.vert
deleted file mode 100644
index ae1f2e9..0000000
--- a/tests/spec/arb_separate_shader_objects/compiler/1.50/define.vert
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_separate_shader_objects
-// [end config]
-#version 150
-#extension GL_ARB_separate_shader_objects: require
-
-#if !defined GL_ARB_separate_shader_objects
-#  error GL_ARB_separate_shader_objects is not defined
-#elif GL_ARB_separate_shader_objects != 1
-#  error GL_ARB_separate_shader_objects is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_shader_atomic_counter_ops/preprocessor/define.frag b/tests/spec/arb_shader_atomic_counter_ops/preprocessor/define.frag
deleted file mode 100644
index 69633af..0000000
--- a/tests/spec/arb_shader_atomic_counter_ops/preprocessor/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.40
-// require_extensions: GL_ARB_shader_atomic_counter_ops
-// [end config]
-
-#version 140
-#extension GL_ARB_shader_atomic_counter_ops: require
-
-#if !defined GL_ARB_shader_atomic_counter_ops
-#  error GL_ARB_shader_atomic_counter_ops is not defined
-#elif GL_ARB_shader_atomic_counter_ops != 1
-#  error GL_ARB_shader_atomic_counter_ops is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_shader_atomic_counter_ops/preprocessor/define.vert b/tests/spec/arb_shader_atomic_counter_ops/preprocessor/define.vert
deleted file mode 100644
index 69633af..0000000
--- a/tests/spec/arb_shader_atomic_counter_ops/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.40
-// require_extensions: GL_ARB_shader_atomic_counter_ops
-// [end config]
-
-#version 140
-#extension GL_ARB_shader_atomic_counter_ops: require
-
-#if !defined GL_ARB_shader_atomic_counter_ops
-#  error GL_ARB_shader_atomic_counter_ops is not defined
-#elif GL_ARB_shader_atomic_counter_ops != 1
-#  error GL_ARB_shader_atomic_counter_ops is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_shader_atomic_counters/preprocessor/define.frag b/tests/spec/arb_shader_atomic_counters/preprocessor/define.frag
deleted file mode 100644
index f48fe8e..0000000
--- a/tests/spec/arb_shader_atomic_counters/preprocessor/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.40
-// require_extensions: GL_ARB_shader_atomic_counters
-// [end config]
-
-#version 140
-#extension GL_ARB_shader_atomic_counters: require
-
-#if !defined GL_ARB_shader_atomic_counters
-#  error GL_ARB_shader_atomic_counters is not defined
-#elif GL_ARB_shader_atomic_counters != 1
-#  error GL_ARB_shader_atomic_counters is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_shader_atomic_counters/preprocessor/define.vert b/tests/spec/arb_shader_atomic_counters/preprocessor/define.vert
deleted file mode 100644
index f48fe8e..0000000
--- a/tests/spec/arb_shader_atomic_counters/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.40
-// require_extensions: GL_ARB_shader_atomic_counters
-// [end config]
-
-#version 140
-#extension GL_ARB_shader_atomic_counters: require
-
-#if !defined GL_ARB_shader_atomic_counters
-#  error GL_ARB_shader_atomic_counters is not defined
-#elif GL_ARB_shader_atomic_counters != 1
-#  error GL_ARB_shader_atomic_counters is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_shader_draw_parameters/compiler/define.vert b/tests/spec/arb_shader_draw_parameters/compiler/define.vert
deleted file mode 100644
index 073ec64..0000000
--- a/tests/spec/arb_shader_draw_parameters/compiler/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.40
-// require_extensions: GL_ARB_shader_draw_parameters
-// [end config]
-
-#version 140
-#extension GL_ARB_shader_draw_parameters: require
-
-#if !defined GL_ARB_shader_draw_parameters
-#  error GL_ARB_shader_draw_parameters is not defined
-#elif GL_ARB_shader_draw_parameters != 1
-#  error GL_ARB_shader_draw_parameters is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_shader_storage_buffer_object/preprocessor/define.frag b/tests/spec/arb_shader_storage_buffer_object/preprocessor/define.frag
deleted file mode 100644
index ca9fc6d..0000000
--- a/tests/spec/arb_shader_storage_buffer_object/preprocessor/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_ARB_shader_storage_buffer_object
-// [end config]
-
-#version 110
-#extension GL_ARB_shader_storage_buffer_object: require
-
-#if !defined GL_ARB_shader_storage_buffer_object
-#  error GL_ARB_shader_storage_buffer_object is not defined
-#elif GL_ARB_shader_storage_buffer_object != 1
-#  error GL_ARB_shader_storage_buffer_object is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_shader_storage_buffer_object/preprocessor/define.vert b/tests/spec/arb_shader_storage_buffer_object/preprocessor/define.vert
deleted file mode 100644
index ca9fc6d..0000000
--- a/tests/spec/arb_shader_storage_buffer_object/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_ARB_shader_storage_buffer_object
-// [end config]
-
-#version 110
-#extension GL_ARB_shader_storage_buffer_object: require
-
-#if !defined GL_ARB_shader_storage_buffer_object
-#  error GL_ARB_shader_storage_buffer_object is not defined
-#elif GL_ARB_shader_storage_buffer_object != 1
-#  error GL_ARB_shader_storage_buffer_object is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_shader_subroutine/preprocessor/define.vert b/tests/spec/arb_shader_subroutine/preprocessor/define.vert
deleted file mode 100644
index 37d99b6..0000000
--- a/tests/spec/arb_shader_subroutine/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_shader_subroutine
-// [end config]
-
-#version 150
-#extension GL_ARB_shader_subroutine: require
-
-#if !defined GL_ARB_shader_subroutine
-#  error GL_ARB_shader_subroutine is not defined
-#elif GL_ARB_shader_subroutine != 1
-#  error GL_ARB_shader_subroutine is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_tessellation_shader/compiler/define.tesc b/tests/spec/arb_tessellation_shader/compiler/define.tesc
deleted file mode 100644
index ed9c782..0000000
--- a/tests/spec/arb_tessellation_shader/compiler/define.tesc
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_tessellation_shader
-// [end config]
-
-#version 150
-#extension GL_ARB_tessellation_shader: require
-
-#if !defined GL_ARB_tessellation_shader
-#  error GL_ARB_tessellation_shader is not defined
-#elif GL_ARB_tessellation_shader != 1
-#  error GL_ARB_tessellation_shader is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_tessellation_shader/compiler/define.tese b/tests/spec/arb_tessellation_shader/compiler/define.tese
deleted file mode 100644
index ed9c782..0000000
--- a/tests/spec/arb_tessellation_shader/compiler/define.tese
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_tessellation_shader
-// [end config]
-
-#version 150
-#extension GL_ARB_tessellation_shader: require
-
-#if !defined GL_ARB_tessellation_shader
-#  error GL_ARB_tessellation_shader is not defined
-#elif GL_ARB_tessellation_shader != 1
-#  error GL_ARB_tessellation_shader is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_uniform_buffer_object/preprocessor/define.frag b/tests/spec/arb_uniform_buffer_object/preprocessor/define.frag
deleted file mode 100644
index e1c13e8..0000000
--- a/tests/spec/arb_uniform_buffer_object/preprocessor/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_ARB_uniform_buffer_object
-// [end config]
-
-#version 110
-#extension GL_ARB_uniform_buffer_object: require
-
-#if !defined GL_ARB_uniform_buffer_object
-#  error GL_ARB_uniform_buffer_object is not defined
-#elif GL_ARB_uniform_buffer_object != 1
-#  error GL_ARB_uniform_buffer_object is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_uniform_buffer_object/preprocessor/define.vert b/tests/spec/arb_uniform_buffer_object/preprocessor/define.vert
deleted file mode 100644
index e1c13e8..0000000
--- a/tests/spec/arb_uniform_buffer_object/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_ARB_uniform_buffer_object
-// [end config]
-
-#version 110
-#extension GL_ARB_uniform_buffer_object: require
-
-#if !defined GL_ARB_uniform_buffer_object
-#  error GL_ARB_uniform_buffer_object is not defined
-#elif GL_ARB_uniform_buffer_object != 1
-#  error GL_ARB_uniform_buffer_object is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_vertex_attrib_64bit/preprocessor/define.frag b/tests/spec/arb_vertex_attrib_64bit/preprocessor/define.frag
deleted file mode 100644
index 9bd723b..0000000
--- a/tests/spec/arb_vertex_attrib_64bit/preprocessor/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_vertex_attrib_64bit
-// [end config]
-
-#version 150
-#extension GL_ARB_vertex_attrib_64bit: require
-
-#if !defined GL_ARB_vertex_attrib_64bit
-#  error GL_ARB_vertex_attrib_64bit is not defined
-#elif GL_ARB_vertex_attrib_64bit != 1
-#  error GL_ARB_vertex_attrib_64bit is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/arb_vertex_attrib_64bit/preprocessor/define.vert b/tests/spec/arb_vertex_attrib_64bit/preprocessor/define.vert
deleted file mode 100644
index 9bd723b..0000000
--- a/tests/spec/arb_vertex_attrib_64bit/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_ARB_vertex_attrib_64bit
-// [end config]
-
-#version 150
-#extension GL_ARB_vertex_attrib_64bit: require
-
-#if !defined GL_ARB_vertex_attrib_64bit
-#  error GL_ARB_vertex_attrib_64bit is not defined
-#elif GL_ARB_vertex_attrib_64bit != 1
-#  error GL_ARB_vertex_attrib_64bit is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/ext_shader_samples_identical/glsl-1.10/preprocessor/define.frag b/tests/spec/ext_shader_samples_identical/glsl-1.10/preprocessor/define.frag
deleted file mode 100644
index c48232a..0000000
--- a/tests/spec/ext_shader_samples_identical/glsl-1.10/preprocessor/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_ARB_texture_multisample GL_EXT_shader_samples_identical
-// [end config]
-
-#extension GL_ARB_texture_multisample: require
-#extension GL_EXT_shader_samples_identical: require
-
-#if !defined GL_EXT_shader_samples_identical
-#  error GL_EXT_shader_samples_identical is not defined
-#elif GL_EXT_shader_samples_identical != 1
-#  error GL_EXT_shader_samples_identical is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/ext_shader_samples_identical/glsl-1.10/preprocessor/define.vert b/tests/spec/ext_shader_samples_identical/glsl-1.10/preprocessor/define.vert
deleted file mode 100644
index c48232a..0000000
--- a/tests/spec/ext_shader_samples_identical/glsl-1.10/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.10
-// require_extensions: GL_ARB_texture_multisample GL_EXT_shader_samples_identical
-// [end config]
-
-#extension GL_ARB_texture_multisample: require
-#extension GL_EXT_shader_samples_identical: require
-
-#if !defined GL_EXT_shader_samples_identical
-#  error GL_EXT_shader_samples_identical is not defined
-#elif GL_EXT_shader_samples_identical != 1
-#  error GL_EXT_shader_samples_identical is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/ext_shader_samples_identical/glsl-1.50/preprocessor/define.geom b/tests/spec/ext_shader_samples_identical/glsl-1.50/preprocessor/define.geom
deleted file mode 100644
index c7d677a..0000000
--- a/tests/spec/ext_shader_samples_identical/glsl-1.50/preprocessor/define.geom
+++ /dev/null
@@ -1,18 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 1.50
-// require_extensions: GL_EXT_shader_samples_identical
-// [end config]
-
-#extension GL_EXT_shader_samples_identical: require
-
-#if !defined GL_EXT_shader_samples_identical
-#  error GL_EXT_shader_samples_identical is not defined
-#elif GL_EXT_shader_samples_identical != 1
-#  error GL_EXT_shader_samples_identical is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/ext_shader_samples_identical/glsl-es-3.10/preprocessor/define.frag b/tests/spec/ext_shader_samples_identical/glsl-es-3.10/preprocessor/define.frag
deleted file mode 100644
index 00a1d1c..0000000
--- a/tests/spec/ext_shader_samples_identical/glsl-es-3.10/preprocessor/define.frag
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 3.10
-// require_extensions: GL_EXT_shader_samples_identical
-// [end config]
-
-#version 310 es
-#extension GL_EXT_shader_samples_identical: require
-
-#if !defined GL_EXT_shader_samples_identical
-#  error GL_EXT_shader_samples_identical is not defined
-#elif GL_EXT_shader_samples_identical != 1
-#  error GL_EXT_shader_samples_identical is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
diff --git a/tests/spec/ext_shader_samples_identical/glsl-es-3.10/preprocessor/define.vert b/tests/spec/ext_shader_samples_identical/glsl-es-3.10/preprocessor/define.vert
deleted file mode 100644
index 00a1d1c..0000000
--- a/tests/spec/ext_shader_samples_identical/glsl-es-3.10/preprocessor/define.vert
+++ /dev/null
@@ -1,19 +0,0 @@
-// [config]
-// expect_result: pass
-// glsl_version: 3.10
-// require_extensions: GL_EXT_shader_samples_identical
-// [end config]
-
-#version 310 es
-#extension GL_EXT_shader_samples_identical: require
-
-#if !defined GL_EXT_shader_samples_identical
-#  error GL_EXT_shader_samples_identical is not defined
-#elif GL_EXT_shader_samples_identical != 1
-#  error GL_EXT_shader_samples_identical is not equal to 1
-#endif
-
-/* Some compilers generate spurious errors if a shader does not contain
- * any code or declarations.
- */
-int foo(void) { return 1; }
-- 
2.8.0



More information about the Piglit mailing list