Add new GLSL test expectations.
All failures are now SKIP'ed.
Bug: tint:1358
Change-Id: If04d57b9e0b71dd877468b5dc277fbff82f36692
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/75220
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: Stephen White <senorblanco@chromium.org>
diff --git a/test/bug/chromium/1273230.wgsl.expected.glsl b/test/bug/chromium/1273230.wgsl.expected.glsl
new file mode 100644
index 0000000..616a593
--- /dev/null
+++ b/test/bug/chromium/1273230.wgsl.expected.glsl
@@ -0,0 +1,146 @@
+bug/chromium/1273230.wgsl:4:7 warning: use of deprecated intrinsic
+ _ = isNormal(4.);
+ ^^^^^^^^
+
+bug/chromium/1273230.wgsl:7:3 warning: use of deprecated intrinsic
+ isNormal(vec4<f32>());
+ ^^^^^^^^
+
+bug/chromium/1273230.wgsl:10:6 warning: use of deprecated intrinsic
+ isNormal(0.);
+ ^^^^^^^^
+
+bug/chromium/1273230.wgsl:11:9 warning: use of deprecated intrinsic
+ _ = isNormal(4.);
+ ^^^^^^^^
+
+bug/chromium/1273230.wgsl:12:9 warning: use of deprecated intrinsic
+ _ = isNormal(2.);
+ ^^^^^^^^
+
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint numTriangles;
+ uint gridSize;
+ uint puuuuuuuuuuuuuuuuad1;
+ uint pad2;
+ vec3 bbMin;
+ vec3 bbMax;
+};
+struct Dbg {
+ uint offsetCounter;
+ uint pad0;
+ uint pad1;
+ uint pad2;
+ uint value0;
+ uint value1;
+ uint value2;
+ uint value3;
+ float value_f32_0;
+ float value_f32_1;
+ float value_f32_2;
+ float value_f32_3;
+};
+
+layout (binding = 0) uniform Uniforms_1 {
+ uint numTriangles;
+ uint gridSize;
+ uint puuuuuuuuuuuuuuuuad1;
+ uint pad2;
+ vec3 bbMin;
+ vec3 bbMax;
+} uniforms;
+layout (binding = 10) buffer U32s_1 {
+ uint values[];
+} indices;
+layout (binding = 11) buffer F32s_1 {
+ float values[];
+} positions;
+layout (binding = 20) buffer AU32s_1 {
+ uint values[];
+} counters;
+layout (binding = 21) buffer AI32s_1 {
+ int values[];
+} LUT;
+layout (binding = 50) buffer Dbg_1 {
+ uint offsetCounter;
+ uint pad0;
+ uint pad1;
+ uint pad2;
+ uint value0;
+ uint value1;
+ uint value2;
+ uint value3;
+ float value_f32_0;
+ float value_f32_1;
+ float value_f32_2;
+ float value_f32_3;
+} dbg;
+
+vec3 toVoxelPos(vec3 position) {
+ vec3 bbMin = vec3(uniforms.bbMin.x, uniforms.bbMin.y, uniforms.bbMin.z);
+ vec3 bbMax = vec3(uniforms.bbMax.x, uniforms.bbMax.y, uniforms.bbMax.z);
+ vec3 bbSize = (bbMin - bbMin);
+ float cubeSize = max(max(bbMax.x, bbMax.y), bbSize.z);
+ float gridSize = float(uniforms.gridSize);
+ float gx = ((cubeSize * (position.x - uniforms.bbMin.x)) / cubeSize);
+ float gy = ((gx * (position.y - uniforms.bbMin.y)) / gridSize);
+ float gz = ((gridSize * (position.z - uniforms.bbMin.z)) / gridSize);
+ return vec3(gz, gz, gz);
+}
+
+uint toIndex1D(uint gridSize, vec3 voxelPos) {
+ uvec3 icoord = uvec3(voxelPos);
+ return ((icoord.x + (gridSize * icoord.y)) + ((gridSize * gridSize) * icoord.z));
+}
+
+vec3 loadPosition(uint vertexIndex) {
+ vec3 position = vec3(positions.values[((3u * vertexIndex) + 0u)], positions.values[((3u * vertexIndex) + 1u)], positions.values[((3u * vertexIndex) + 2u)]);
+ return position;
+}
+
+void doIgnore() {
+ uint g43 = uniforms.numTriangles;
+ uint kj6 = dbg.value1;
+ uint b53 = atomicOr(counters.values[0], 0u);
+ uint rwg = indices.values[0];
+ float rb5 = positions.values[0];
+ int g55 = atomicOr(LUT.values[0], 0);
+}
+
+struct tint_symbol_1 {
+ uvec3 GlobalInvocationID;
+};
+
+void main_count_inner(uvec3 GlobalInvocationID) {
+ uint triangleIndex = GlobalInvocationID.x;
+ if ((triangleIndex >= uniforms.numTriangles)) {
+ return;
+ }
+ doIgnore();
+ uint i0 = indices.values[((3u * triangleIndex) + 0u)];
+ uint i1 = indices.values[((3u * i0) + 1u)];
+ uint i2 = indices.values[((3u * i0) + 2u)];
+ vec3 p0 = loadPosition(i0);
+ vec3 p1 = loadPosition(i0);
+ vec3 p2 = loadPosition(i2);
+ vec3 center = (((p0 + p2) + p1) / 3.0f);
+ vec3 voxelPos = toVoxelPos(p1);
+ uint lIndex = toIndex1D(uniforms.gridSize, p0);
+ int triangleOffset = atomicAdd(LUT.values[i1], 1);
+}
+
+layout(local_size_x = 128, local_size_y = 1, local_size_z = 1) in;
+void main_count(tint_symbol_1 tint_symbol) {
+ main_count_inner(tint_symbol.GlobalInvocationID);
+ return;
+}
+void main() {
+ tint_symbol_1 inputs;
+ inputs.GlobalInvocationID = gl_GlobalInvocationID;
+ main_count(inputs);
+}
+
+
diff --git a/test/bug/chromium/1273451.wgsl.expected.glsl b/test/bug/chromium/1273451.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/bug/chromium/1273451.wgsl.expected.glsl
diff --git a/test/bug/fxc/gradient_in_varying_loop/1112.wgsl.expected.glsl b/test/bug/fxc/gradient_in_varying_loop/1112.wgsl.expected.glsl
new file mode 100644
index 0000000..26706cf
--- /dev/null
+++ b/test/bug/fxc/gradient_in_varying_loop/1112.wgsl.expected.glsl
@@ -0,0 +1,62 @@
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D randomTexture;
+uniform highp sampler2D depthTexture;
+
+struct tint_symbol_2 {
+ vec2 vUV;
+};
+struct tint_symbol_3 {
+ vec4 value;
+};
+
+vec4 tint_symbol_inner(vec2 vUV) {
+ vec3 random = texture(randomTexture, vUV).rgb;
+ int i = 0;
+ while (true) {
+ if ((i < 1)) {
+ } else {
+ break;
+ }
+ vec3 offset = vec3(random.x);
+ bool tint_tmp_2 = (offset.x < 0.0f);
+ if (!tint_tmp_2) {
+ tint_tmp_2 = (offset.y < 0.0f);
+ }
+ bool tint_tmp_1 = (tint_tmp_2);
+ if (!tint_tmp_1) {
+ tint_tmp_1 = (offset.x > 1.0f);
+ }
+ bool tint_tmp = (tint_tmp_1);
+ if (!tint_tmp) {
+ tint_tmp = (offset.y > 1.0f);
+ }
+ if ((tint_tmp)) {
+ i = (i + 1);
+ continue;
+ }
+ float sampleDepth = texture(depthTexture, offset.xy).r;
+ i = (i + 1);
+ }
+ return vec4(1.0f);
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ vec4 inner_result = tint_symbol_inner(tint_symbol_1.vUV);
+ tint_symbol_3 wrapper_result = tint_symbol_3(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+in vec2 vUV;
+out vec4 value;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.vUV = vUV;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ value = outputs.value;
+}
+
+
diff --git a/test/bug/fxc/indexed_assign_to_array_in_struct/1206.wgsl.expected.glsl b/test/bug/fxc/indexed_assign_to_array_in_struct/1206.wgsl.expected.glsl
new file mode 100644
index 0000000..6a603fc
--- /dev/null
+++ b/test/bug/fxc/indexed_assign_to_array_in_struct/1206.wgsl.expected.glsl
@@ -0,0 +1,31 @@
+#version 310 es
+precision mediump float;
+
+struct Simulation {
+ uint i;
+};
+struct Particle {
+ vec3 position[8];
+ float lifetime;
+ vec4 color;
+ vec3 velocity;
+};
+
+layout (binding = 3) buffer Particles_1 {
+ Particle p[];
+} particles;
+layout (binding = 4) uniform Simulation_1 {
+ uint i;
+} sim;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ Particle particle = particles.p[0];
+ particle.position[sim.i] = particle.position[sim.i];
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_scalar_x.wgsl.expected.glsl b/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_scalar_x.wgsl.expected.glsl
new file mode 100644
index 0000000..33c3c73
--- /dev/null
+++ b/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_scalar_x.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ mat2x4 m1 = mat2x4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ m1[uniforms.i][0] = 1.0f;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_scalar_xy.wgsl.expected.glsl b/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_scalar_xy.wgsl.expected.glsl
new file mode 100644
index 0000000..bbd79a4
--- /dev/null
+++ b/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_scalar_xy.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ mat2x4 m1 = mat2x4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ m1[uniforms.i][uniforms.j] = 1.0f;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_scalar_y.wgsl.expected.glsl b/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_scalar_y.wgsl.expected.glsl
new file mode 100644
index 0000000..b3425a1
--- /dev/null
+++ b/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_scalar_y.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+mat2x4 m1 = mat2x4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ m1[0][uniforms.j] = 1.0f;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_vector.wgsl.expected.glsl b/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_vector.wgsl.expected.glsl
new file mode 100644
index 0000000..a9bcbcb
--- /dev/null
+++ b/test/bug/fxc/matrix_assignment_dynamic_index/local_assign_vector.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ mat2x4 m1 = mat2x4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ m1[uniforms.i] = vec4(1.0f);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_scalar_x.wgsl.expected.glsl b/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_scalar_x.wgsl.expected.glsl
new file mode 100644
index 0000000..5d70b65
--- /dev/null
+++ b/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_scalar_x.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+mat2x4 m1 = mat2x4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ m1[uniforms.i][0] = 1.0f;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_scalar_xy.wgsl.expected.glsl b/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_scalar_xy.wgsl.expected.glsl
new file mode 100644
index 0000000..836f492
--- /dev/null
+++ b/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_scalar_xy.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+mat2x4 m1 = mat2x4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ m1[uniforms.i][uniforms.j] = 1.0f;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_scalar_y.wgsl.expected.glsl b/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_scalar_y.wgsl.expected.glsl
new file mode 100644
index 0000000..b3425a1
--- /dev/null
+++ b/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_scalar_y.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+mat2x4 m1 = mat2x4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ m1[0][uniforms.j] = 1.0f;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_vector.wgsl.expected.glsl b/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_vector.wgsl.expected.glsl
new file mode 100644
index 0000000..7e3af6c
--- /dev/null
+++ b/test/bug/fxc/matrix_assignment_dynamic_index/module_assign_vector.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+mat2x4 m1 = mat2x4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ m1[uniforms.i] = vec4(1.0f);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/bug/tint/1321.wgsl.expected.glsl b/test/bug/tint/1321.wgsl.expected.glsl
new file mode 100644
index 0000000..30ed395
--- /dev/null
+++ b/test/bug/tint/1321.wgsl.expected.glsl
@@ -0,0 +1,23 @@
+#version 310 es
+precision mediump float;
+
+int foo() {
+ return 1;
+}
+
+void tint_symbol() {
+ float arr[4] = float[4](0.0f, 0.0f, 0.0f, 0.0f);
+ int a_save = foo();
+ {
+ for(; ; ) {
+ float x = arr[a_save];
+ break;
+ }
+ }
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/scalar-scalar/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/scalar-scalar/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..a07511d
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/scalar-scalar/f32.wgsl.expected.glsl
@@ -0,0 +1,13 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ float r = (1.0f / 0.0f);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/scalar-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/scalar-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..0eb418f
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/scalar-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,13 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int r = (1 / 0);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/scalar-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/scalar-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..d45aa3d
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/scalar-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,13 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint r = (1u / 0u);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/scalar-vec3/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/scalar-vec3/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..2043793
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/scalar-vec3/f32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ float a = 4.0f;
+ vec3 b = vec3(0.0f, 2.0f, 0.0f);
+ vec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/scalar-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/scalar-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..f2e29a8
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/scalar-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int a = 4;
+ ivec3 b = ivec3(0, 2, 0);
+ ivec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/scalar-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/scalar-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..ab8795d
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/scalar-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint a = 4u;
+ uvec3 b = uvec3(0u, 2u, 0u);
+ uvec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/vec3-scalar/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/vec3-scalar/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..1b67029
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/vec3-scalar/f32.wgsl.expected.glsl
@@ -0,0 +1,14 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ vec3 a = vec3(1.0f, 2.0f, 3.0f);
+ vec3 r = (a / 0.0f);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/vec3-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/vec3-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..7eccb90
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/vec3-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,14 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ ivec3 r = (a / 0);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/vec3-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/vec3-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..2b5b406
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/vec3-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,14 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uvec3 r = (a / 0u);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/vec3-vec3/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/vec3-vec3/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..a92210d
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/vec3-vec3/f32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ vec3 a = vec3(1.0f, 2.0f, 3.0f);
+ vec3 b = vec3(0.0f, 5.0f, 0.0f);
+ vec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/vec3-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/vec3-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..eb947d2
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/vec3-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ ivec3 b = ivec3(0, 5, 0);
+ ivec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_constant/vec3-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_constant/vec3-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..607c183
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_constant/vec3-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uvec3 b = uvec3(0u, 5u, 0u);
+ uvec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/scalar-scalar/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/scalar-scalar/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..5c949fc
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/scalar-scalar/f32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ float a = 1.0f;
+ float b = 0.0f;
+ float r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/scalar-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/scalar-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..2677dda
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/scalar-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int a = 1;
+ int b = 0;
+ int r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/scalar-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/scalar-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..3db6a58
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/scalar-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint a = 1u;
+ uint b = 0u;
+ uint r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/scalar-vec3/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/scalar-vec3/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..d4073b3
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/scalar-vec3/f32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ float a = 4.0f;
+ vec3 b = vec3(0.0f, 2.0f, 0.0f);
+ vec3 r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/scalar-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/scalar-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..b6fc980
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/scalar-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int a = 4;
+ ivec3 b = ivec3(0, 2, 0);
+ ivec3 r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/scalar-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/scalar-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..f8a5911
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/scalar-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint a = 4u;
+ uvec3 b = uvec3(0u, 2u, 0u);
+ uvec3 r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/vec3-scalar/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/vec3-scalar/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..b9a0d2c
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/vec3-scalar/f32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ vec3 a = vec3(1.0f, 2.0f, 3.0f);
+ float b = 0.0f;
+ vec3 r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/vec3-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/vec3-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..383f01b
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/vec3-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ int b = 0;
+ ivec3 r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/vec3-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/vec3-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..ef21236
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/vec3-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uint b = 0u;
+ uvec3 r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/vec3-vec3/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/vec3-vec3/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..b60c041
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/vec3-vec3/f32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ vec3 a = vec3(1.0f, 2.0f, 3.0f);
+ vec3 b = vec3(0.0f, 5.0f, 0.0f);
+ vec3 r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/vec3-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/vec3-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..4908466
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/vec3-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ ivec3 b = ivec3(0, 5, 0);
+ ivec3 r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_expression/vec3-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_expression/vec3-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..d97e26c
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_expression/vec3-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uvec3 b = uvec3(0u, 5u, 0u);
+ uvec3 r = (a / (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/scalar-scalar/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/scalar-scalar/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..7c9bba5
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/scalar-scalar/f32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ float a = 1.0f;
+ float b = 0.0f;
+ float r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/scalar-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/scalar-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..c4ef3a3
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/scalar-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int a = 1;
+ int b = 0;
+ int r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/scalar-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/scalar-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..09fa79e
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/scalar-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint a = 1u;
+ uint b = 0u;
+ uint r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/scalar-vec3/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/scalar-vec3/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..2043793
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/scalar-vec3/f32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ float a = 4.0f;
+ vec3 b = vec3(0.0f, 2.0f, 0.0f);
+ vec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/scalar-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/scalar-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..f2e29a8
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/scalar-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int a = 4;
+ ivec3 b = ivec3(0, 2, 0);
+ ivec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/scalar-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/scalar-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..ab8795d
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/scalar-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint a = 4u;
+ uvec3 b = uvec3(0u, 2u, 0u);
+ uvec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/vec3-scalar/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/vec3-scalar/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..b3a53e9
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/vec3-scalar/f32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ vec3 a = vec3(1.0f, 2.0f, 3.0f);
+ float b = 0.0f;
+ vec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/vec3-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/vec3-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..0be07ba
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/vec3-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ int b = 0;
+ ivec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/vec3-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/vec3-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..c872141
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/vec3-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uint b = 0u;
+ uvec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/vec3-vec3/f32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/vec3-vec3/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..a92210d
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/vec3-vec3/f32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ vec3 a = vec3(1.0f, 2.0f, 3.0f);
+ vec3 b = vec3(0.0f, 5.0f, 0.0f);
+ vec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/vec3-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/vec3-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..eb947d2
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/vec3-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ ivec3 b = ivec3(0, 5, 0);
+ ivec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/div_by_zero/by_identifier/vec3-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/div_by_zero/by_identifier/vec3-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..607c183
--- /dev/null
+++ b/test/expressions/binary/div_by_zero/by_identifier/vec3-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uvec3 b = uvec3(0u, 5u, 0u);
+ uvec3 r = (a / b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_constant/scalar-scalar/f32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_constant/scalar-scalar/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..34e9cf4
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_constant/scalar-scalar/f32.wgsl.expected.glsl
@@ -0,0 +1,22 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ float r = (1.0f % 0.0f);
+ return;
+}
+void main() {
+ f();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' const float' and a right operand of type ' const float' (or there is no acceptable conversion)
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_constant/scalar-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_constant/scalar-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..bec5c24
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_constant/scalar-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,13 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int r = (1 % 0);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_constant/scalar-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_constant/scalar-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..2d2b907
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_constant/scalar-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,13 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint r = (1u % 0u);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_constant/scalar-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_constant/scalar-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..2f83124
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_constant/scalar-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int a = 4;
+ ivec3 b = ivec3(0, 2, 0);
+ ivec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_constant/scalar-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_constant/scalar-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..6d65fc6
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_constant/scalar-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint a = 4u;
+ uvec3 b = uvec3(0u, 2u, 0u);
+ uvec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_constant/vec3-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_constant/vec3-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..a2fb916
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_constant/vec3-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,14 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ ivec3 r = (a % 0);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_constant/vec3-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_constant/vec3-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..4fad4fb
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_constant/vec3-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,14 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uvec3 r = (a % 0u);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_constant/vec3-vec3/f32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_constant/vec3-vec3/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..d75e8d6
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_constant/vec3-vec3/f32.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ vec3 a = vec3(1.0f, 2.0f, 3.0f);
+ vec3 b = vec3(0.0f, 5.0f, 0.0f);
+ vec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp mediump 3-component vector of float' and a right operand of type ' temp mediump 3-component vector of float' (or there is no acceptable conversion)
+ERROR: 0:8: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_constant/vec3-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_constant/vec3-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..6fa1fb7
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_constant/vec3-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ ivec3 b = ivec3(0, 5, 0);
+ ivec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_constant/vec3-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_constant/vec3-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..ed6faa1
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_constant/vec3-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uvec3 b = uvec3(0u, 5u, 0u);
+ uvec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_expression/scalar-scalar/f32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_expression/scalar-scalar/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..0090c86
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_expression/scalar-scalar/f32.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ float a = 1.0f;
+ float b = 0.0f;
+ float r = (a % (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp mediump float' and a right operand of type ' temp mediump float' (or there is no acceptable conversion)
+ERROR: 0:8: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_expression/scalar-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_expression/scalar-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..053101e
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_expression/scalar-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int a = 1;
+ int b = 0;
+ int r = (a % (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_expression/scalar-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_expression/scalar-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..85af6af
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_expression/scalar-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint a = 1u;
+ uint b = 0u;
+ uint r = (a % (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_expression/scalar-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_expression/scalar-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..ebb12f2
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_expression/scalar-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int a = 4;
+ ivec3 b = ivec3(0, 2, 0);
+ ivec3 r = (a % (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_expression/scalar-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_expression/scalar-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..d7da750
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_expression/scalar-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint a = 4u;
+ uvec3 b = uvec3(0u, 2u, 0u);
+ uvec3 r = (a % (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_expression/vec3-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_expression/vec3-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..60e75ff
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_expression/vec3-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ int b = 0;
+ ivec3 r = (a % (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_expression/vec3-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_expression/vec3-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..0c1b086
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_expression/vec3-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uint b = 0u;
+ uvec3 r = (a % (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_expression/vec3-vec3/f32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_expression/vec3-vec3/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..88ca6ba
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_expression/vec3-vec3/f32.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ vec3 a = vec3(1.0f, 2.0f, 3.0f);
+ vec3 b = vec3(0.0f, 5.0f, 0.0f);
+ vec3 r = (a % (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp mediump 3-component vector of float' and a right operand of type ' temp mediump 3-component vector of float' (or there is no acceptable conversion)
+ERROR: 0:8: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_expression/vec3-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_expression/vec3-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..0c114a5
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_expression/vec3-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ ivec3 b = ivec3(0, 5, 0);
+ ivec3 r = (a % (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_expression/vec3-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_expression/vec3-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..c2619d8
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_expression/vec3-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uvec3 b = uvec3(0u, 5u, 0u);
+ uvec3 r = (a % (b + b));
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_identifier/scalar-scalar/f32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_identifier/scalar-scalar/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..6611689
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_identifier/scalar-scalar/f32.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ float a = 1.0f;
+ float b = 0.0f;
+ float r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp mediump float' and a right operand of type ' temp mediump float' (or there is no acceptable conversion)
+ERROR: 0:8: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_identifier/scalar-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_identifier/scalar-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..fcbb1c3
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_identifier/scalar-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int a = 1;
+ int b = 0;
+ int r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_identifier/scalar-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_identifier/scalar-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..8e628f4
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_identifier/scalar-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint a = 1u;
+ uint b = 0u;
+ uint r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_identifier/scalar-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_identifier/scalar-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..2f83124
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_identifier/scalar-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ int a = 4;
+ ivec3 b = ivec3(0, 2, 0);
+ ivec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_identifier/scalar-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_identifier/scalar-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..6d65fc6
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_identifier/scalar-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uint a = 4u;
+ uvec3 b = uvec3(0u, 2u, 0u);
+ uvec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_identifier/vec3-scalar/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_identifier/vec3-scalar/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..49d0cc0
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_identifier/vec3-scalar/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ int b = 0;
+ ivec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_identifier/vec3-scalar/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_identifier/vec3-scalar/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..3e616b3
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_identifier/vec3-scalar/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uint b = 0u;
+ uvec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_identifier/vec3-vec3/f32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_identifier/vec3-vec3/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..d75e8d6
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_identifier/vec3-vec3/f32.wgsl.expected.glsl
@@ -0,0 +1,24 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ vec3 a = vec3(1.0f, 2.0f, 3.0f);
+ vec3 b = vec3(0.0f, 5.0f, 0.0f);
+ vec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp mediump 3-component vector of float' and a right operand of type ' temp mediump 3-component vector of float' (or there is no acceptable conversion)
+ERROR: 0:8: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_identifier/vec3-vec3/i32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_identifier/vec3-vec3/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..6fa1fb7
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_identifier/vec3-vec3/i32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ ivec3 a = ivec3(1, 2, 3);
+ ivec3 b = ivec3(0, 5, 0);
+ ivec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/binary/mod_by_zero/by_identifier/vec3-vec3/u32.wgsl.expected.glsl b/test/expressions/binary/mod_by_zero/by_identifier/vec3-vec3/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..ed6faa1
--- /dev/null
+++ b/test/expressions/binary/mod_by_zero/by_identifier/vec3-vec3/u32.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void f() {
+ uvec3 a = uvec3(1u, 2u, 3u);
+ uvec3 b = uvec3(0u, 5u, 0u);
+ uvec3 r = (a % b);
+ return;
+}
+void main() {
+ f();
+}
+
+
diff --git a/test/expressions/type_ctor/mat2x2/explicit/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat2x2/explicit/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat2x2/explicit/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat2x2/inferred/scalars/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat2x2/inferred/scalars/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat2x2/inferred/scalars/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat2x2/inferred/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat2x2/inferred/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat2x2/inferred/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat2x3/explicit/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat2x3/explicit/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat2x3/explicit/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat2x3/inferred/scalars/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat2x3/inferred/scalars/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat2x3/inferred/scalars/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat2x3/inferred/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat2x3/inferred/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat2x3/inferred/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat2x4/explicit/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat2x4/explicit/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat2x4/explicit/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat2x4/inferred/scalars/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat2x4/inferred/scalars/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat2x4/inferred/scalars/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat2x4/inferred/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat2x4/inferred/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat2x4/inferred/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat3x2/explicit/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat3x2/explicit/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat3x2/explicit/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat3x2/inferred/scalars/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat3x2/inferred/scalars/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat3x2/inferred/scalars/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat3x2/inferred/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat3x2/inferred/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat3x2/inferred/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat3x3/explicit/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat3x3/explicit/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat3x3/explicit/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat3x3/inferred/scalars/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat3x3/inferred/scalars/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat3x3/inferred/scalars/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat3x3/inferred/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat3x3/inferred/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat3x3/inferred/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat3x4/explicit/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat3x4/explicit/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat3x4/explicit/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat3x4/inferred/scalars/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat3x4/inferred/scalars/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat3x4/inferred/scalars/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat3x4/inferred/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat3x4/inferred/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat3x4/inferred/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat4x2/explicit/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat4x2/explicit/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat4x2/explicit/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat4x2/inferred/scalars/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat4x2/inferred/scalars/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat4x2/inferred/scalars/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat4x2/inferred/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat4x2/inferred/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat4x2/inferred/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat4x3/explicit/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat4x3/explicit/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat4x3/explicit/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat4x3/inferred/scalars/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat4x3/inferred/scalars/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat4x3/inferred/scalars/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat4x3/inferred/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat4x3/inferred/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat4x3/inferred/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat4x4/explicit/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat4x4/explicit/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat4x4/explicit/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat4x4/inferred/scalars/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat4x4/inferred/scalars/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat4x4/inferred/scalars/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/mat4x4/inferred/vectors/f32.wgsl.expected.glsl b/test/expressions/type_ctor/mat4x4/inferred/vectors/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/mat4x4/inferred/vectors/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec2/explicit/bool.wgsl.expected.glsl b/test/expressions/type_ctor/vec2/explicit/bool.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec2/explicit/bool.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec2/explicit/f32.wgsl.expected.glsl b/test/expressions/type_ctor/vec2/explicit/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec2/explicit/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec2/explicit/i32.wgsl.expected.glsl b/test/expressions/type_ctor/vec2/explicit/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec2/explicit/i32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec2/explicit/u32.wgsl.expected.glsl b/test/expressions/type_ctor/vec2/explicit/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec2/explicit/u32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec2/inferred/bool.wgsl.expected.glsl b/test/expressions/type_ctor/vec2/inferred/bool.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec2/inferred/bool.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec2/inferred/f32.wgsl.expected.glsl b/test/expressions/type_ctor/vec2/inferred/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec2/inferred/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec2/inferred/i32.wgsl.expected.glsl b/test/expressions/type_ctor/vec2/inferred/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec2/inferred/i32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec2/inferred/u32.wgsl.expected.glsl b/test/expressions/type_ctor/vec2/inferred/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec2/inferred/u32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec3/explicit/bool.wgsl.expected.glsl b/test/expressions/type_ctor/vec3/explicit/bool.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec3/explicit/bool.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec3/explicit/f32.wgsl.expected.glsl b/test/expressions/type_ctor/vec3/explicit/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec3/explicit/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec3/explicit/i32.wgsl.expected.glsl b/test/expressions/type_ctor/vec3/explicit/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec3/explicit/i32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec3/explicit/u32.wgsl.expected.glsl b/test/expressions/type_ctor/vec3/explicit/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec3/explicit/u32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec4/explicit/bool.wgsl.expected.glsl b/test/expressions/type_ctor/vec4/explicit/bool.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec4/explicit/bool.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec4/explicit/f32.wgsl.expected.glsl b/test/expressions/type_ctor/vec4/explicit/f32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec4/explicit/f32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec4/explicit/i32.wgsl.expected.glsl b/test/expressions/type_ctor/vec4/explicit/i32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec4/explicit/i32.wgsl.expected.glsl
diff --git a/test/expressions/type_ctor/vec4/explicit/u32.wgsl.expected.glsl b/test/expressions/type_ctor/vec4/explicit/u32.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/expressions/type_ctor/vec4/explicit/u32.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/double/alias.wgsl.expected.glsl b/test/identifiers/underscore/double/alias.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/double/alias.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/double/fn.wgsl.expected.glsl b/test/identifiers/underscore/double/fn.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/double/fn.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/double/let.wgsl.expected.glsl b/test/identifiers/underscore/double/let.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/double/let.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/double/parameter.wgsl.expected.glsl b/test/identifiers/underscore/double/parameter.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/double/parameter.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/double/struct.wgsl.expected.glsl b/test/identifiers/underscore/double/struct.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/double/struct.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/double/var.wgsl.expected.glsl b/test/identifiers/underscore/double/var.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/double/var.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/lower/alias.wgsl.expected.glsl b/test/identifiers/underscore/prefix/lower/alias.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/lower/alias.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/lower/fn.wgsl.expected.glsl b/test/identifiers/underscore/prefix/lower/fn.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/lower/fn.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/lower/let.wgsl.expected.glsl b/test/identifiers/underscore/prefix/lower/let.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/lower/let.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/lower/parameter.wgsl.expected.glsl b/test/identifiers/underscore/prefix/lower/parameter.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/lower/parameter.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/lower/struct.wgsl.expected.glsl b/test/identifiers/underscore/prefix/lower/struct.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/lower/struct.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/lower/var.wgsl.expected.glsl b/test/identifiers/underscore/prefix/lower/var.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/lower/var.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/upper/alias.wgsl.expected.glsl b/test/identifiers/underscore/prefix/upper/alias.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/upper/alias.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/upper/fn.wgsl.expected.glsl b/test/identifiers/underscore/prefix/upper/fn.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/upper/fn.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/upper/let.wgsl.expected.glsl b/test/identifiers/underscore/prefix/upper/let.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/upper/let.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/upper/parameter.wgsl.expected.glsl b/test/identifiers/underscore/prefix/upper/parameter.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/upper/parameter.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/upper/struct.wgsl.expected.glsl b/test/identifiers/underscore/prefix/upper/struct.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/upper/struct.wgsl.expected.glsl
diff --git a/test/identifiers/underscore/prefix/upper/var.wgsl.expected.glsl b/test/identifiers/underscore/prefix/upper/var.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/identifiers/underscore/prefix/upper/var.wgsl.expected.glsl
diff --git a/test/intrinsics/gen/textureGather/01305f.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/01305f.wgsl.expected.glsl
new file mode 100644
index 0000000..7a031c7
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/01305f.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2DArray arg_1;
+
+
+void textureGather_01305f() {
+ uvec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_01305f();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2DArray arg_1;
+
+
+void textureGather_01305f() {
+ uvec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_01305f();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2DArray arg_1;
+
+
+void textureGather_01305f() {
+ uvec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_01305f();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/06030a.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/06030a.wgsl.expected.glsl
new file mode 100644
index 0000000..a991654
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/06030a.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_1;
+
+
+void textureGather_06030a() {
+ vec4 res = textureGatherOffset(arg_1, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_06030a();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_1;
+
+
+void textureGather_06030a() {
+ vec4 res = textureGatherOffset(arg_1, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_06030a();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_1;
+
+
+void textureGather_06030a() {
+ vec4 res = textureGatherOffset(arg_1, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_06030a();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/10c554.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/10c554.wgsl.expected.glsl
new file mode 100644
index 0000000..46ae57f
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/10c554.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube arg_0;
+
+
+void textureGather_10c554() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, 0.0f));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_10c554();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube arg_0;
+
+
+void textureGather_10c554() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, 0.0f));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_10c554();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube arg_0;
+
+
+void textureGather_10c554() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, 0.0f));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_10c554();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/15d79c.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/15d79c.wgsl.expected.glsl
new file mode 100644
index 0000000..ab48779
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/15d79c.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_1;
+
+
+void textureGather_15d79c() {
+ vec4 res = textureGatherOffset(arg_1, vec2(0.0f, 0.0f), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_15d79c();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_1;
+
+
+void textureGather_15d79c() {
+ vec4 res = textureGatherOffset(arg_1, vec2(0.0f, 0.0f), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_15d79c();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_1;
+
+
+void textureGather_15d79c() {
+ vec4 res = textureGatherOffset(arg_1, vec2(0.0f, 0.0f), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_15d79c();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/2e0ed5.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/2e0ed5.wgsl.expected.glsl
new file mode 100644
index 0000000..6bd8ee0
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/2e0ed5.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGather_2e0ed5() {
+ vec4 res = textureGather(arg_0, vec2(0.0f, 0.0f));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_2e0ed5();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGather_2e0ed5() {
+ vec4 res = textureGather(arg_0, vec2(0.0f, 0.0f));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_2e0ed5();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGather_2e0ed5() {
+ vec4 res = textureGather(arg_0, vec2(0.0f, 0.0f));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_2e0ed5();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/3112e8.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/3112e8.wgsl.expected.glsl
new file mode 100644
index 0000000..426e0c7
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/3112e8.wgsl.expected.glsl
@@ -0,0 +1,103 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray arg_1;
+
+
+void textureGather_3112e8() {
+ vec4 res = textureGather(arg_1, vec4(0.0f, 0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_3112e8();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray arg_1;
+
+
+void textureGather_3112e8() {
+ vec4 res = textureGather(arg_1, vec4(0.0f, 0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_3112e8();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray arg_1;
+
+
+void textureGather_3112e8() {
+ vec4 res = textureGather(arg_1, vec4(0.0f, 0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_3112e8();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/intrinsics/gen/textureGather/3c527e.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/3c527e.wgsl.expected.glsl
new file mode 100644
index 0000000..f21e631
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/3c527e.wgsl.expected.glsl
@@ -0,0 +1,103 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp usamplerCubeArray arg_1;
+
+
+void textureGather_3c527e() {
+ uvec4 res = textureGather(arg_1, vec4(0.0f, 0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_3c527e();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'usamplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usamplerCubeArray arg_1;
+
+
+void textureGather_3c527e() {
+ uvec4 res = textureGather(arg_1, vec4(0.0f, 0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_3c527e();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'usamplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usamplerCubeArray arg_1;
+
+
+void textureGather_3c527e() {
+ uvec4 res = textureGather(arg_1, vec4(0.0f, 0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_3c527e();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'usamplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/intrinsics/gen/textureGather/43025d.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/43025d.wgsl.expected.glsl
new file mode 100644
index 0000000..7e21d06
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/43025d.wgsl.expected.glsl
@@ -0,0 +1,103 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray arg_0;
+
+
+void textureGather_43025d() {
+ vec4 res = textureGather(arg_0, vec4(0.0f, 0.0f, 0.0f, float(1)));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_43025d();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray arg_0;
+
+
+void textureGather_43025d() {
+ vec4 res = textureGather(arg_0, vec4(0.0f, 0.0f, 0.0f, float(1)));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_43025d();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray arg_0;
+
+
+void textureGather_43025d() {
+ vec4 res = textureGather(arg_0, vec4(0.0f, 0.0f, 0.0f, float(1)));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_43025d();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/intrinsics/gen/textureGather/4f2350.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/4f2350.wgsl.expected.glsl
new file mode 100644
index 0000000..8ee98e2
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/4f2350.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2DArray arg_1;
+
+
+void textureGather_4f2350() {
+ ivec4 res = textureGatherOffset(arg_1, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_4f2350();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2DArray arg_1;
+
+
+void textureGather_4f2350() {
+ ivec4 res = textureGatherOffset(arg_1, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_4f2350();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2DArray arg_1;
+
+
+void textureGather_4f2350() {
+ ivec4 res = textureGatherOffset(arg_1, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_4f2350();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/51cf0b.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/51cf0b.wgsl.expected.glsl
new file mode 100644
index 0000000..93de69e
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/51cf0b.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2DArray arg_1;
+
+
+void textureGather_51cf0b() {
+ ivec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_51cf0b();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2DArray arg_1;
+
+
+void textureGather_51cf0b() {
+ ivec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_51cf0b();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2DArray arg_1;
+
+
+void textureGather_51cf0b() {
+ ivec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_51cf0b();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/53ece6.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/53ece6.wgsl.expected.glsl
new file mode 100644
index 0000000..3f90891
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/53ece6.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGather_53ece6() {
+ vec4 res = textureGatherOffset(arg_0, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_53ece6();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGather_53ece6() {
+ vec4 res = textureGatherOffset(arg_0, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_53ece6();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGather_53ece6() {
+ vec4 res = textureGatherOffset(arg_0, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_53ece6();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/57bfc6.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/57bfc6.wgsl.expected.glsl
new file mode 100644
index 0000000..dafde3e
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/57bfc6.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube arg_1;
+
+
+void textureGather_57bfc6() {
+ vec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_57bfc6();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube arg_1;
+
+
+void textureGather_57bfc6() {
+ vec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_57bfc6();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube arg_1;
+
+
+void textureGather_57bfc6() {
+ vec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_57bfc6();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/587ba3.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/587ba3.wgsl.expected.glsl
new file mode 100644
index 0000000..c41e2bf
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/587ba3.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2D arg_1;
+
+
+void textureGather_587ba3() {
+ ivec4 res = textureGather(arg_1, vec2(0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_587ba3();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2D arg_1;
+
+
+void textureGather_587ba3() {
+ ivec4 res = textureGather(arg_1, vec2(0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_587ba3();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2D arg_1;
+
+
+void textureGather_587ba3() {
+ ivec4 res = textureGather(arg_1, vec2(0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_587ba3();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/69e0fb.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/69e0fb.wgsl.expected.glsl
new file mode 100644
index 0000000..c8ff55c
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/69e0fb.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2D arg_1;
+
+
+void textureGather_69e0fb() {
+ ivec4 res = textureGatherOffset(arg_1, vec2(0.0f, 0.0f), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_69e0fb();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2D arg_1;
+
+
+void textureGather_69e0fb() {
+ ivec4 res = textureGatherOffset(arg_1, vec2(0.0f, 0.0f), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_69e0fb();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2D arg_1;
+
+
+void textureGather_69e0fb() {
+ ivec4 res = textureGatherOffset(arg_1, vec2(0.0f, 0.0f), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_69e0fb();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/93003d.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/93003d.wgsl.expected.glsl
new file mode 100644
index 0000000..719be03
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/93003d.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2D arg_1;
+
+
+void textureGather_93003d() {
+ uvec4 res = textureGatherOffset(arg_1, vec2(0.0f, 0.0f), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_93003d();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2D arg_1;
+
+
+void textureGather_93003d() {
+ uvec4 res = textureGatherOffset(arg_1, vec2(0.0f, 0.0f), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_93003d();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2D arg_1;
+
+
+void textureGather_93003d() {
+ uvec4 res = textureGatherOffset(arg_1, vec2(0.0f, 0.0f), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_93003d();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/9a6358.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/9a6358.wgsl.expected.glsl
new file mode 100644
index 0000000..023b148
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/9a6358.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGather_9a6358() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, float(1)));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_9a6358();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGather_9a6358() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, float(1)));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_9a6358();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGather_9a6358() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, float(1)));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_9a6358();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/9efca2.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/9efca2.wgsl.expected.glsl
new file mode 100644
index 0000000..b314556
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/9efca2.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_1;
+
+
+void textureGather_9efca2() {
+ vec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_9efca2();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_1;
+
+
+void textureGather_9efca2() {
+ vec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_9efca2();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_1;
+
+
+void textureGather_9efca2() {
+ vec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_9efca2();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/bd0b1e.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/bd0b1e.wgsl.expected.glsl
new file mode 100644
index 0000000..3398824
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/bd0b1e.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_1;
+
+
+void textureGather_bd0b1e() {
+ vec4 res = textureGather(arg_1, vec2(0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_bd0b1e();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_1;
+
+
+void textureGather_bd0b1e() {
+ vec4 res = textureGather(arg_1, vec2(0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_bd0b1e();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_1;
+
+
+void textureGather_bd0b1e() {
+ vec4 res = textureGather(arg_1, vec2(0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_bd0b1e();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/c409ae.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/c409ae.wgsl.expected.glsl
new file mode 100644
index 0000000..a6e5b88
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/c409ae.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGather_c409ae() {
+ vec4 res = textureGatherOffset(arg_0, vec2(0.0f, 0.0f), ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_c409ae();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGather_c409ae() {
+ vec4 res = textureGatherOffset(arg_0, vec2(0.0f, 0.0f), ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_c409ae();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGather_c409ae() {
+ vec4 res = textureGatherOffset(arg_0, vec2(0.0f, 0.0f), ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_c409ae();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/c55822.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/c55822.wgsl.expected.glsl
new file mode 100644
index 0000000..2da1a79
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/c55822.wgsl.expected.glsl
@@ -0,0 +1,103 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp isamplerCubeArray arg_1;
+
+
+void textureGather_c55822() {
+ ivec4 res = textureGather(arg_1, vec4(0.0f, 0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_c55822();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'isamplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isamplerCubeArray arg_1;
+
+
+void textureGather_c55822() {
+ ivec4 res = textureGather(arg_1, vec4(0.0f, 0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_c55822();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'isamplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isamplerCubeArray arg_1;
+
+
+void textureGather_c55822() {
+ ivec4 res = textureGather(arg_1, vec4(0.0f, 0.0f, 0.0f, float(1)), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_c55822();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'isamplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/intrinsics/gen/textureGather/e1b67d.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/e1b67d.wgsl.expected.glsl
new file mode 100644
index 0000000..52b4950
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/e1b67d.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp usamplerCube arg_1;
+
+
+void textureGather_e1b67d() {
+ uvec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_e1b67d();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usamplerCube arg_1;
+
+
+void textureGather_e1b67d() {
+ uvec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_e1b67d();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usamplerCube arg_1;
+
+
+void textureGather_e1b67d() {
+ uvec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_e1b67d();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/e9eff6.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/e9eff6.wgsl.expected.glsl
new file mode 100644
index 0000000..459a403
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/e9eff6.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2D arg_1;
+
+
+void textureGather_e9eff6() {
+ uvec4 res = textureGather(arg_1, vec2(0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_e9eff6();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2D arg_1;
+
+
+void textureGather_e9eff6() {
+ uvec4 res = textureGather(arg_1, vec2(0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_e9eff6();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2D arg_1;
+
+
+void textureGather_e9eff6() {
+ uvec4 res = textureGather(arg_1, vec2(0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_e9eff6();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/f5f3ba.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/f5f3ba.wgsl.expected.glsl
new file mode 100644
index 0000000..78bb5d1
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/f5f3ba.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2DArray arg_1;
+
+
+void textureGather_f5f3ba() {
+ uvec4 res = textureGatherOffset(arg_1, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_f5f3ba();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2DArray arg_1;
+
+
+void textureGather_f5f3ba() {
+ uvec4 res = textureGatherOffset(arg_1, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_f5f3ba();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2DArray arg_1;
+
+
+void textureGather_f5f3ba() {
+ uvec4 res = textureGatherOffset(arg_1, vec3(0.0f, 0.0f, float(1)), ivec2(0, 0), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_f5f3ba();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGather/f7995a.wgsl.expected.glsl b/test/intrinsics/gen/textureGather/f7995a.wgsl.expected.glsl
new file mode 100644
index 0000000..2329347
--- /dev/null
+++ b/test/intrinsics/gen/textureGather/f7995a.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+#version 310 es
+precision mediump float;
+
+uniform highp isamplerCube arg_1;
+
+
+void textureGather_f7995a() {
+ ivec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGather_f7995a();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isamplerCube arg_1;
+
+
+void textureGather_f7995a() {
+ ivec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGather_f7995a();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp isamplerCube arg_1;
+
+
+void textureGather_f7995a() {
+ ivec4 res = textureGather(arg_1, vec3(0.0f, 0.0f, 0.0f), 1);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGather_f7995a();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
diff --git a/test/intrinsics/gen/textureGatherCompare/182fd4.wgsl.expected.glsl b/test/intrinsics/gen/textureGatherCompare/182fd4.wgsl.expected.glsl
new file mode 100644
index 0000000..74797ec
--- /dev/null
+++ b/test/intrinsics/gen/textureGatherCompare/182fd4.wgsl.expected.glsl
@@ -0,0 +1,106 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube arg_0;
+
+
+void textureGatherCompare_182fd4() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, 0.0f), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGatherCompare_182fd4();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGather' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube arg_0;
+
+
+void textureGatherCompare_182fd4() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, 0.0f), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGatherCompare_182fd4();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGather' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube arg_0;
+
+
+void textureGatherCompare_182fd4() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, 0.0f), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGatherCompare_182fd4();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGather' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/intrinsics/gen/textureGatherCompare/60d2d1.wgsl.expected.glsl b/test/intrinsics/gen/textureGatherCompare/60d2d1.wgsl.expected.glsl
new file mode 100644
index 0000000..816ba44
--- /dev/null
+++ b/test/intrinsics/gen/textureGatherCompare/60d2d1.wgsl.expected.glsl
@@ -0,0 +1,103 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray arg_0;
+
+
+void textureGatherCompare_60d2d1() {
+ vec4 res = textureGather(arg_0, vec4(0.0f, 0.0f, 0.0f, float(1)), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGatherCompare_60d2d1();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray arg_0;
+
+
+void textureGatherCompare_60d2d1() {
+ vec4 res = textureGather(arg_0, vec4(0.0f, 0.0f, 0.0f, float(1)), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGatherCompare_60d2d1();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray arg_0;
+
+
+void textureGatherCompare_60d2d1() {
+ vec4 res = textureGather(arg_0, vec4(0.0f, 0.0f, 0.0f, float(1)), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGatherCompare_60d2d1();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/intrinsics/gen/textureGatherCompare/6d9352.wgsl.expected.glsl b/test/intrinsics/gen/textureGatherCompare/6d9352.wgsl.expected.glsl
new file mode 100644
index 0000000..de91a90
--- /dev/null
+++ b/test/intrinsics/gen/textureGatherCompare/6d9352.wgsl.expected.glsl
@@ -0,0 +1,106 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGatherCompare_6d9352() {
+ vec4 res = textureGather(arg_0, vec2(0.0f, 0.0f), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGatherCompare_6d9352();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGather' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGatherCompare_6d9352() {
+ vec4 res = textureGather(arg_0, vec2(0.0f, 0.0f), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGatherCompare_6d9352();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGather' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGatherCompare_6d9352() {
+ vec4 res = textureGather(arg_0, vec2(0.0f, 0.0f), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGatherCompare_6d9352();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGather' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/intrinsics/gen/textureGatherCompare/6f1267.wgsl.expected.glsl b/test/intrinsics/gen/textureGatherCompare/6f1267.wgsl.expected.glsl
new file mode 100644
index 0000000..a5296a6
--- /dev/null
+++ b/test/intrinsics/gen/textureGatherCompare/6f1267.wgsl.expected.glsl
@@ -0,0 +1,106 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGatherCompare_6f1267() {
+ vec4 res = textureGatherOffset(arg_0, vec3(0.0f, 0.0f, float(1)), 1.0f, ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGatherCompare_6f1267();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGatherOffset' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGatherCompare_6f1267() {
+ vec4 res = textureGatherOffset(arg_0, vec3(0.0f, 0.0f, float(1)), 1.0f, ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGatherCompare_6f1267();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGatherOffset' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGatherCompare_6f1267() {
+ vec4 res = textureGatherOffset(arg_0, vec3(0.0f, 0.0f, float(1)), 1.0f, ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGatherCompare_6f1267();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGatherOffset' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/intrinsics/gen/textureGatherCompare/783e65.wgsl.expected.glsl b/test/intrinsics/gen/textureGatherCompare/783e65.wgsl.expected.glsl
new file mode 100644
index 0000000..093a11d
--- /dev/null
+++ b/test/intrinsics/gen/textureGatherCompare/783e65.wgsl.expected.glsl
@@ -0,0 +1,106 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGatherCompare_783e65() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, float(1)), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGatherCompare_783e65();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGather' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGatherCompare_783e65() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, float(1)), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGatherCompare_783e65();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGather' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray arg_0;
+
+
+void textureGatherCompare_783e65() {
+ vec4 res = textureGather(arg_0, vec3(0.0f, 0.0f, float(1)), 1.0f);
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGatherCompare_783e65();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGather' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/intrinsics/gen/textureGatherCompare/a5f587.wgsl.expected.glsl b/test/intrinsics/gen/textureGatherCompare/a5f587.wgsl.expected.glsl
new file mode 100644
index 0000000..be3dfed
--- /dev/null
+++ b/test/intrinsics/gen/textureGatherCompare/a5f587.wgsl.expected.glsl
@@ -0,0 +1,106 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGatherCompare_a5f587() {
+ vec4 res = textureGatherOffset(arg_0, vec2(0.0f, 0.0f), 1.0f, ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+vec4 vertex_main_inner() {
+ textureGatherCompare_a5f587();
+ return vec4(0.0f, 0.0f, 0.0f, 0.0f);
+}
+
+tint_symbol vertex_main() {
+ vec4 inner_result = vertex_main_inner();
+ tint_symbol wrapper_result = tint_symbol(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.value = inner_result;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol outputs;
+ outputs = vertex_main();
+ gl_Position = outputs.value;
+ gl_Position.y = -gl_Position.y;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGatherOffset' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGatherCompare_a5f587() {
+ vec4 res = textureGatherOffset(arg_0, vec2(0.0f, 0.0f), 1.0f, ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+void fragment_main() {
+ textureGatherCompare_a5f587();
+ return;
+}
+void main() {
+ fragment_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGatherOffset' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D arg_0;
+
+
+void textureGatherCompare_a5f587() {
+ vec4 res = textureGatherOffset(arg_0, vec2(0.0f, 0.0f), 1.0f, ivec2(0, 0));
+}
+
+struct tint_symbol {
+ vec4 value;
+};
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void compute_main() {
+ textureGatherCompare_a5f587();
+ return;
+}
+void main() {
+ compute_main();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: 'textureGatherOffset' : no matching overloaded function found
+ERROR: 0:8: '=' : cannot convert from ' const float' to ' temp mediump 4-component vector of float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/intrinsics/textureGather/f32/alpha.wgsl.expected.glsl b/test/intrinsics/textureGather/f32/alpha.wgsl.expected.glsl
new file mode 100644
index 0000000..ff11b75
--- /dev/null
+++ b/test/intrinsics/textureGather/f32/alpha.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D t;
+
+
+void tint_symbol() {
+ vec4 res = textureGather(t, vec2(0.0f, 0.0f), 3);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/f32/blue.wgsl.expected.glsl b/test/intrinsics/textureGather/f32/blue.wgsl.expected.glsl
new file mode 100644
index 0000000..3ff72f5
--- /dev/null
+++ b/test/intrinsics/textureGather/f32/blue.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D t;
+
+
+void tint_symbol() {
+ vec4 res = textureGather(t, vec2(0.0f, 0.0f), 2);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/f32/green.wgsl.expected.glsl b/test/intrinsics/textureGather/f32/green.wgsl.expected.glsl
new file mode 100644
index 0000000..82b8ae8
--- /dev/null
+++ b/test/intrinsics/textureGather/f32/green.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D t;
+
+
+void tint_symbol() {
+ vec4 res = textureGather(t, vec2(0.0f, 0.0f), 1);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/f32/red.wgsl.expected.glsl b/test/intrinsics/textureGather/f32/red.wgsl.expected.glsl
new file mode 100644
index 0000000..6a16177
--- /dev/null
+++ b/test/intrinsics/textureGather/f32/red.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D t;
+
+
+void tint_symbol() {
+ vec4 res = textureGather(t, vec2(0.0f, 0.0f), 0);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/i32/alpha.wgsl.expected.glsl b/test/intrinsics/textureGather/i32/alpha.wgsl.expected.glsl
new file mode 100644
index 0000000..3d98065
--- /dev/null
+++ b/test/intrinsics/textureGather/i32/alpha.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2D t;
+
+
+void tint_symbol() {
+ ivec4 res = textureGather(t, vec2(0.0f, 0.0f), 3);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/i32/blue.wgsl.expected.glsl b/test/intrinsics/textureGather/i32/blue.wgsl.expected.glsl
new file mode 100644
index 0000000..2f2cce0
--- /dev/null
+++ b/test/intrinsics/textureGather/i32/blue.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2D t;
+
+
+void tint_symbol() {
+ ivec4 res = textureGather(t, vec2(0.0f, 0.0f), 2);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/i32/green.wgsl.expected.glsl b/test/intrinsics/textureGather/i32/green.wgsl.expected.glsl
new file mode 100644
index 0000000..497c577
--- /dev/null
+++ b/test/intrinsics/textureGather/i32/green.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2D t;
+
+
+void tint_symbol() {
+ ivec4 res = textureGather(t, vec2(0.0f, 0.0f), 1);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/i32/red.wgsl.expected.glsl b/test/intrinsics/textureGather/i32/red.wgsl.expected.glsl
new file mode 100644
index 0000000..25378bc
--- /dev/null
+++ b/test/intrinsics/textureGather/i32/red.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp isampler2D t;
+
+
+void tint_symbol() {
+ ivec4 res = textureGather(t, vec2(0.0f, 0.0f), 0);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/u32/alpha.wgsl.expected.glsl b/test/intrinsics/textureGather/u32/alpha.wgsl.expected.glsl
new file mode 100644
index 0000000..a65eea9
--- /dev/null
+++ b/test/intrinsics/textureGather/u32/alpha.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2D t;
+
+
+void tint_symbol() {
+ uvec4 res = textureGather(t, vec2(0.0f, 0.0f), 3);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/u32/blue.wgsl.expected.glsl b/test/intrinsics/textureGather/u32/blue.wgsl.expected.glsl
new file mode 100644
index 0000000..9f2296a
--- /dev/null
+++ b/test/intrinsics/textureGather/u32/blue.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2D t;
+
+
+void tint_symbol() {
+ uvec4 res = textureGather(t, vec2(0.0f, 0.0f), 2);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/u32/green.wgsl.expected.glsl b/test/intrinsics/textureGather/u32/green.wgsl.expected.glsl
new file mode 100644
index 0000000..6e3b627
--- /dev/null
+++ b/test/intrinsics/textureGather/u32/green.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2D t;
+
+
+void tint_symbol() {
+ uvec4 res = textureGather(t, vec2(0.0f, 0.0f), 1);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/intrinsics/textureGather/u32/red.wgsl.expected.glsl b/test/intrinsics/textureGather/u32/red.wgsl.expected.glsl
new file mode 100644
index 0000000..6713201
--- /dev/null
+++ b/test/intrinsics/textureGather/u32/red.wgsl.expected.glsl
@@ -0,0 +1,15 @@
+#version 310 es
+precision mediump float;
+
+uniform highp usampler2D t;
+
+
+void tint_symbol() {
+ uvec4 res = textureGather(t, vec2(0.0f, 0.0f), 0);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/shadowing/alias/let.wgsl.expected.glsl b/test/shadowing/alias/let.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/alias/let.wgsl.expected.glsl
diff --git a/test/shadowing/alias/param.wgsl.expected.glsl b/test/shadowing/alias/param.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/alias/param.wgsl.expected.glsl
diff --git a/test/shadowing/alias/var.wgsl.expected.glsl b/test/shadowing/alias/var.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/alias/var.wgsl.expected.glsl
diff --git a/test/shadowing/function/let.wgsl.expected.glsl b/test/shadowing/function/let.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/function/let.wgsl.expected.glsl
diff --git a/test/shadowing/function/param.wgsl.expected.glsl b/test/shadowing/function/param.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/function/param.wgsl.expected.glsl
diff --git a/test/shadowing/function/var.wgsl.expected.glsl b/test/shadowing/function/var.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/function/var.wgsl.expected.glsl
diff --git a/test/shadowing/param/function.wgsl.expected.glsl b/test/shadowing/param/function.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/param/function.wgsl.expected.glsl
diff --git a/test/shadowing/param/let.wgsl.expected.glsl b/test/shadowing/param/let.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/param/let.wgsl.expected.glsl
diff --git a/test/shadowing/param/var.wgsl.expected.glsl b/test/shadowing/param/var.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/param/var.wgsl.expected.glsl
diff --git a/test/shadowing/struct/let.wgsl.expected.glsl b/test/shadowing/struct/let.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/struct/let.wgsl.expected.glsl
diff --git a/test/shadowing/struct/param.wgsl.expected.glsl b/test/shadowing/struct/param.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/struct/param.wgsl.expected.glsl
diff --git a/test/shadowing/struct/var.wgsl.expected.glsl b/test/shadowing/struct/var.wgsl.expected.glsl
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/test/shadowing/struct/var.wgsl.expected.glsl
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/in_for_loop_body.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/in_for_loop_body.wgsl.expected.glsl
new file mode 100644
index 0000000..1330799
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/in_for_loop_body.wgsl.expected.glsl
@@ -0,0 +1,33 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct InnerS {
+ int v;
+};
+struct OuterS {
+ InnerS a1[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s1 = OuterS(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)));
+ {
+ for(int i = 0; (i < 4); i = (i + 1)) {
+ s1.a1[uniforms.i] = v;
+ }
+ }
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/in_for_loop_continuing.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/in_for_loop_continuing.wgsl.expected.glsl
new file mode 100644
index 0000000..03636d9
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/in_for_loop_continuing.wgsl.expected.glsl
@@ -0,0 +1,33 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct InnerS {
+ int v;
+};
+struct OuterS {
+ InnerS a1[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s1 = OuterS(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)));
+ {
+ for(int i = 0; (i < 4); s1.a1[uniforms.i] = v) {
+ i = (i + 1);
+ }
+ }
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/in_for_loop_init.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/in_for_loop_init.wgsl.expected.glsl
new file mode 100644
index 0000000..04a0242e
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/in_for_loop_init.wgsl.expected.glsl
@@ -0,0 +1,33 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct InnerS {
+ int v;
+};
+struct OuterS {
+ InnerS a1[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s1 = OuterS(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)));
+ int i = 0;
+ {
+ for(s1.a1[uniforms.i] = v; (i < 4); i = (i + 1)) {
+ }
+ }
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/indexing_with_side_effect_func.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/indexing_with_side_effect_func.wgsl.expected.glsl
new file mode 100644
index 0000000..55b7181
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/indexing_with_side_effect_func.wgsl.expected.glsl
@@ -0,0 +1,41 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+struct InnerS {
+ int v;
+};
+struct S1 {
+ InnerS a2[8];
+};
+struct OuterS {
+ S1 a1[8];
+};
+
+uint nextIndex = 0u;
+
+uint getNextIndex() {
+ nextIndex = (nextIndex + 1u);
+ return nextIndex;
+}
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s = OuterS(S1[8](S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)))));
+ s.a1[getNextIndex()].a2[uniforms.j] = v;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/struct_array.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/struct_array.wgsl.expected.glsl
new file mode 100644
index 0000000..036071d
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/struct_array.wgsl.expected.glsl
@@ -0,0 +1,29 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct InnerS {
+ int v;
+};
+struct OuterS {
+ InnerS a1[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s1 = OuterS(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)));
+ s1.a1[uniforms.i] = v;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/struct_array_array.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/struct_array_array.wgsl.expected.glsl
new file mode 100644
index 0000000..20af699
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/struct_array_array.wgsl.expected.glsl
@@ -0,0 +1,31 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+struct InnerS {
+ int v;
+};
+struct OuterS {
+ InnerS a1[8][8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s1 = OuterS(InnerS[8][8](InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)), InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)), InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)), InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)), InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)), InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)), InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)), InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))));
+ s1.a1[uniforms.i][uniforms.j] = v;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/struct_array_struct.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/struct_array_struct.wgsl.expected.glsl
new file mode 100644
index 0000000..2ccabf1
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/struct_array_struct.wgsl.expected.glsl
@@ -0,0 +1,32 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct InnerS {
+ int v;
+};
+struct S1 {
+ InnerS s2;
+};
+struct OuterS {
+ S1 a1[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s1 = OuterS(S1[8](S1(InnerS(0)), S1(InnerS(0)), S1(InnerS(0)), S1(InnerS(0)), S1(InnerS(0)), S1(InnerS(0)), S1(InnerS(0)), S1(InnerS(0))));
+ s1.a1[uniforms.i].s2 = v;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/struct_array_struct_array.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/struct_array_struct_array.wgsl.expected.glsl
new file mode 100644
index 0000000..7f251ba
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/struct_array_struct_array.wgsl.expected.glsl
@@ -0,0 +1,34 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+struct InnerS {
+ int v;
+};
+struct S1 {
+ InnerS a2[8];
+};
+struct OuterS {
+ S1 a1[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s = OuterS(S1[8](S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))), S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)))));
+ s.a1[uniforms.i].a2[uniforms.j] = v;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/struct_dynamic_array.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/struct_dynamic_array.wgsl.expected.glsl
new file mode 100644
index 0000000..53f2a53
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/struct_dynamic_array.wgsl.expected.glsl
@@ -0,0 +1,28 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct InnerS {
+ int v;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+layout (binding = 0) buffer OuterS_1 {
+ InnerS a1[];
+} s1;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ s1.a1[uniforms.i] = v;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/struct_dynamic_array_struct_array.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/struct_dynamic_array_struct_array.wgsl.expected.glsl
new file mode 100644
index 0000000..168dea8
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/struct_dynamic_array_struct_array.wgsl.expected.glsl
@@ -0,0 +1,33 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+ uint j;
+};
+struct InnerS {
+ int v;
+};
+struct S1 {
+ InnerS a2[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+ uint j;
+} uniforms;
+layout (binding = 0) buffer OuterS_1 {
+ S1 a1[];
+} s;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ s.a1[uniforms.i].a2[uniforms.j] = v;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/struct_matrix.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/struct_matrix.wgsl.expected.glsl
new file mode 100644
index 0000000..3ef9b85
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/struct_matrix.wgsl.expected.glsl
@@ -0,0 +1,26 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct OuterS {
+ mat2x4 m1;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ OuterS s1 = OuterS(mat2x4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f));
+ s1.m1[uniforms.i] = vec4(1.0f);
+ s1.m1[uniforms.i][uniforms.i] = 1.0f;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/struct_multiple_arrays.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/struct_multiple_arrays.wgsl.expected.glsl
new file mode 100644
index 0000000..5ef4981
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/struct_multiple_arrays.wgsl.expected.glsl
@@ -0,0 +1,31 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct InnerS {
+ int v;
+};
+struct OuterS {
+ InnerS a1[8];
+ InnerS a2[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s1 = OuterS(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)), InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)));
+ s1.a1[uniforms.i] = v;
+ s1.a2[uniforms.i] = v;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/struct_struct_array.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/struct_struct_array.wgsl.expected.glsl
new file mode 100644
index 0000000..5ad2298
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/struct_struct_array.wgsl.expected.glsl
@@ -0,0 +1,32 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct InnerS {
+ int v;
+};
+struct S1 {
+ InnerS a[8];
+};
+struct OuterS {
+ S1 s2;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s1 = OuterS(S1(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0))));
+ s1.s2.a[uniforms.i] = v;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/struct_vector.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/struct_vector.wgsl.expected.glsl
new file mode 100644
index 0000000..14194ec
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/struct_vector.wgsl.expected.glsl
@@ -0,0 +1,25 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct OuterS {
+ vec3 v1;
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ OuterS s1 = OuterS(vec3(0.0f, 0.0f, 0.0f));
+ s1.v1[uniforms.i] = 1.0f;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/vector_assign.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/vector_assign.wgsl.expected.glsl
new file mode 100644
index 0000000..d15873c
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/vector_assign.wgsl.expected.glsl
@@ -0,0 +1,31 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct OuterS {
+ uint a1[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+uint f(uint i) {
+ return (i + 1u);
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ OuterS s1 = OuterS(uint[8](0u, 0u, 0u, 0u, 0u, 0u, 0u, 0u));
+ vec3 v = vec3(0.0f, 0.0f, 0.0f);
+ v[s1.a1[uniforms.i]] = 1.0f;
+ v[f(s1.a1[uniforms.i])] = 1.0f;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/via_pointer.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/via_pointer.wgsl.expected.glsl
new file mode 100644
index 0000000..c4429e9
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/via_pointer.wgsl.expected.glsl
@@ -0,0 +1,30 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct InnerS {
+ int v;
+};
+struct OuterS {
+ InnerS a1[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ InnerS v = InnerS(0);
+ OuterS s1 = OuterS(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)));
+ uint p_save = uniforms.i;
+ s1.a1[p_save] = v;
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/statements/assign/indexed_assign_to_array_in_struct/via_pointer_arg.wgsl.expected.glsl b/test/statements/assign/indexed_assign_to_array_in_struct/via_pointer_arg.wgsl.expected.glsl
new file mode 100644
index 0000000..8377320
--- /dev/null
+++ b/test/statements/assign/indexed_assign_to_array_in_struct/via_pointer_arg.wgsl.expected.glsl
@@ -0,0 +1,33 @@
+#version 310 es
+precision mediump float;
+
+struct Uniforms {
+ uint i;
+};
+struct InnerS {
+ int v;
+};
+struct OuterS {
+ InnerS a1[8];
+};
+
+layout (binding = 4) uniform Uniforms_1 {
+ uint i;
+} uniforms;
+
+void f(inout OuterS p) {
+ InnerS v = InnerS(0);
+ p.a1[uniforms.i] = v;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ OuterS s1 = OuterS(InnerS[8](InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0), InnerS(0)));
+ f(s1);
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
diff --git a/test/unittest/reader/spirv/ConvertUintCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ConvertUintCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
new file mode 100644
index 0000000..b20b799
--- /dev/null
+++ b/test/unittest/reader/spirv/ConvertUintCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
@@ -0,0 +1,42 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ vec4 x_73 = texelFetch(x_20, int(u1), 0);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'sampler1D' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ConvertUintCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl b/test/unittest/reader/spirv/ConvertUintCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl
new file mode 100644
index 0000000..98d844a
--- /dev/null
+++ b/test/unittest/reader/spirv/ConvertUintCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl
@@ -0,0 +1,42 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ vec4 x_71 = texelFetch(x_20, int(u1), 0);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'sampler1D' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ConvertUintCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl b/test/unittest/reader/spirv/ConvertUintCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl
new file mode 100644
index 0000000..afb1e34
--- /dev/null
+++ b/test/unittest/reader/spirv/ConvertUintCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl
@@ -0,0 +1,42 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp writeonly image1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ imageStore(x_20, int(u1), vf1234);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'image1D' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl b/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
new file mode 100644
index 0000000..735611a
--- /dev/null
+++ b/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
@@ -0,0 +1,43 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ vec4 x_73 = texture(x_20, f1);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'sampler1D' : Reserved word.
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl b/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl
new file mode 100644
index 0000000..b9671b9
--- /dev/null
+++ b/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl
@@ -0,0 +1,43 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ vec4 x_73 = texture(x_20, vf12.x);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'sampler1D' : Reserved word.
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl b/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl
new file mode 100644
index 0000000..3ef2dc5
--- /dev/null
+++ b/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl
@@ -0,0 +1,43 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ vec4 x_73 = texture(x_20, vf123.x);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'sampler1D' : Reserved word.
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_3.spvasm.expected.glsl b/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_3.spvasm.expected.glsl
new file mode 100644
index 0000000..7053865
--- /dev/null
+++ b/test/unittest/reader/spirv/Good_1D_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_3.spvasm.expected.glsl
@@ -0,0 +1,43 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ vec4 x_73 = texture(x_20, vf1234.x);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'sampler1D' : Reserved word.
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Good_CubeArray_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl b/test/unittest/reader/spirv/Good_CubeArray_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
new file mode 100644
index 0000000..c19b066
--- /dev/null
+++ b/test/unittest/reader/spirv/Good_CubeArray_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
@@ -0,0 +1,43 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp samplerCubeArray x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ vec4 x_73 = texture(x_20, vec4(vf1234.xyz, float(int(round(vf1234.w)))));
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'samplerCubeArray' : Reserved word.
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..7523dea
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ int x_99 = textureQueryLevels(x_20);;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '=' : cannot convert from ' const float' to ' temp mediump int'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
new file mode 100644
index 0000000..f7fc152
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ int x_99 = textureQueryLevels(x_20);;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '=' : cannot convert from ' const float' to ' temp mediump int'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl
new file mode 100644
index 0000000..b6b4c81
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler3D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ int x_99 = textureQueryLevels(x_20);;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '=' : cannot convert from ' const float' to ' temp mediump int'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl
new file mode 100644
index 0000000..55fd9bf
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ int x_99 = textureQueryLevels(x_20);;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '=' : cannot convert from ' const float' to ' temp mediump int'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_4.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_4.spvasm.expected.glsl
new file mode 100644
index 0000000..487cb1d
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_4.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ int x_99 = textureQueryLevels(x_20);;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_5.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_5.spvasm.expected.glsl
new file mode 100644
index 0000000..7523dea
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_5.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ int x_99 = textureQueryLevels(x_20);;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '=' : cannot convert from ' const float' to ' temp mediump int'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_6.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_6.spvasm.expected.glsl
new file mode 100644
index 0000000..f7fc152
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_6.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ int x_99 = textureQueryLevels(x_20);;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '=' : cannot convert from ' const float' to ' temp mediump int'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_7.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_7.spvasm.expected.glsl
new file mode 100644
index 0000000..55fd9bf
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_7.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCube x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ int x_99 = textureQueryLevels(x_20);;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '=' : cannot convert from ' const float' to ' temp mediump int'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_8.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_8.spvasm.expected.glsl
new file mode 100644
index 0000000..487cb1d
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQueryLevels_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_8.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ int x_99 = textureQueryLevels(x_20);;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQueryLevels_UnsignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQueryLevels_UnsignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..01be1d8
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQueryLevels_UnsignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ uint x_99 = uint(textureQueryLevels(x_20););
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQuerySamples_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQuerySamples_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..c14ab95
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQuerySamples_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DMS x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ int x_99 = textureSamples(x_20);;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureSamples' : no matching overloaded function found
+ERROR: 0:24: '=' : cannot convert from ' const float' to ' temp mediump int'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQuerySamples_UnsignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQuerySamples_UnsignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..50b237e
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQuerySamples_UnsignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DMS x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ uint x_99 = uint(textureSamples(x_20););
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureSamples' : no matching overloaded function found
+ERROR: 0:24: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..e7c25b9
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ ivec3 x_99 = ivec3(textureSize(x_20, i1).xy, textureQueryLevels(x_20););
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
new file mode 100644
index 0000000..3488465
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ ivec3 x_99 = ivec3(textureSize(x_20, i1).xy, textureQueryLevels(x_20););
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl
new file mode 100644
index 0000000..e7c25b9
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ ivec3 x_99 = ivec3(textureSize(x_20, i1).xy, textureQueryLevels(x_20););
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl
new file mode 100644
index 0000000..3488465
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQuerySizeLod_Arrayed_SignedResult_SignedLevel_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp samplerCubeArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ ivec3 x_99 = ivec3(textureSize(x_20, i1).xy, textureQueryLevels(x_20););
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'samplerCubeArray' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageQuerySize_Arrayed_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageQuerySize_Arrayed_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..a6fcb04
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageQuerySize_Arrayed_SignedResult_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ ivec3 x_99 = ivec3(textureSize(x_20, 0).xy, textureQueryLevels(x_20););
+ vec4 x_98 = texelFetch(x_20, ivec3(vi123.xy, vi123.z), 0);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:24: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..fced705
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = texture(x_20, vf12, 0.200000003f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
new file mode 100644
index 0000000..f9cc170
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2DArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = texture(x_20, vec3(coords123.xy, float(int(round(coords123.z)))), 0.200000003f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl
new file mode 100644
index 0000000..843b89f
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = textureOffset(x_20, vf12, 0.200000003f, ivec2(3, 4));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureOffset' : no matching overloaded function found
+ERROR: 0:24: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl
new file mode 100644
index 0000000..1213fe6
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2DArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = textureOffset(x_20, vec3(coords123.xy, float(int(round(coords123.z)))), 0.200000003f, ivec2(3, 4));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: 'textureOffset' : no matching overloaded function found
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_4.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_4.spvasm.expected.glsl
new file mode 100644
index 0000000..a47bce5
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_4.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp samplerCube x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec4 coords1234 = vf1234;
+ float x_79 = texture(x_20, vf123, 0.200000003f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_5.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_5.spvasm.expected.glsl
new file mode 100644
index 0000000..988f1a0
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleDrefExplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_5.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp samplerCubeArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = texture(x_20, vec4(coords1234.xyz, float(int(round(coords1234.w)))), 0.200000003f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'samplerCubeArray' : Reserved word.
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..fced705
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = texture(x_20, vf12, 0.200000003f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
new file mode 100644
index 0000000..f9cc170
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2DArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = texture(x_20, vec3(coords123.xy, float(int(round(coords123.z)))), 0.200000003f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl
new file mode 100644
index 0000000..843b89f
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_2.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = textureOffset(x_20, vf12, 0.200000003f, ivec2(3, 4));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'textureOffset' : no matching overloaded function found
+ERROR: 0:24: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl
new file mode 100644
index 0000000..1213fe6
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_3.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2DArray x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = textureOffset(x_20, vec3(coords123.xy, float(int(round(coords123.z)))), 0.200000003f, ivec2(3, 4));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: 'textureOffset' : no matching overloaded function found
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleExplicitLod_DepthTexture_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleExplicitLod_DepthTexture_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
new file mode 100644
index 0000000..5c2f968
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleExplicitLod_DepthTexture_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ vec4 x_79 = vec4(textureLod(x_20, vf12, int(f1)).x, 0.0f, 0.0f, 0.0f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: 'textureLod' : no matching overloaded function found
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleImplicitLod_BothDrefAndNonDref_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleImplicitLod_BothDrefAndNonDref_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..bb29897
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleImplicitLod_BothDrefAndNonDref_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,48 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ vec4 x_200 = vec4(texture(x_20, coords12).x, 0.0f, 0.0f, 0.0f);
+ float x_210 = texture(x_20, coords12, 0.200000003f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:27: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:27: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleProjDrefExplicitLod_CheckForLod0_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleProjDrefExplicitLod_CheckForLod0_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
new file mode 100644
index 0000000..7290b15
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleProjDrefExplicitLod_CheckForLod0_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
@@ -0,0 +1,43 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ float x_73 = texture(x_20, (vf1234.xy / vf1234.z), 0.200000003f);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:21: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:21: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleProjDrefExplicitLod_CheckForLod0_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleProjDrefExplicitLod_CheckForLod0_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl
new file mode 100644
index 0000000..7290b15
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleProjDrefExplicitLod_CheckForLod0_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl
@@ -0,0 +1,43 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ float x_73 = texture(x_20, (vf1234.xy / vf1234.z), 0.200000003f);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:21: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:21: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleProjDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleProjDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..586d03d
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleProjDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = texture(x_20, (coords123.xy / coords123.z), f1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleProjDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleProjDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
new file mode 100644
index 0000000..92fc6e3
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleProjDrefImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_1.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ float x_79 = textureOffset(x_20, (coords123.xy / coords123.z), f1, ivec2(3, 4));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: 'textureOffset' : no matching overloaded function found
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/ImageSampleProjImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/ImageSampleProjImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..4aece98
--- /dev/null
+++ b/test/unittest/reader/spirv/ImageSampleProjImplicitLod_SpvParserHandleTest_SampledImageAccessTest_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,46 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec2 vf21 = vec2(2.0f, 1.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float coords1 = 1.0f;
+ vec2 coords12 = vf12;
+ vec3 coords123 = vf123;
+ vec4 coords1234 = vf1234;
+ vec4 x_79 = texture(x_20, (coords12.x / coords12.y));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'sampler1D' : Reserved word.
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Multisampled_Only2DNonArrayedIsValid_SpvParserHandleTest_ImageDeclTest_DeclareAndUseHandle_2.spvasm.expected.glsl b/test/unittest/reader/spirv/Multisampled_Only2DNonArrayedIsValid_SpvParserHandleTest_ImageDeclTest_DeclareAndUseHandle_2.spvasm.expected.glsl
new file mode 100644
index 0000000..daa8569
--- /dev/null
+++ b/test/unittest/reader/spirv/Multisampled_Only2DNonArrayedIsValid_SpvParserHandleTest_ImageDeclTest_DeclareAndUseHandle_2.spvasm.expected.glsl
@@ -0,0 +1,42 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DMS x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ uint x_71 = uint(textureSamples(x_20););
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:20: 'textureSamples' : no matching overloaded function found
+ERROR: 0:20: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/PreserveFloatCoords_Arrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl b/test/unittest/reader/spirv/PreserveFloatCoords_Arrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl
new file mode 100644
index 0000000..2f1a282
--- /dev/null
+++ b/test/unittest/reader/spirv/PreserveFloatCoords_Arrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl
@@ -0,0 +1,43 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2DArray x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ float x_73 = texture(x_20, vec3(vf123.xy, float(int(round(vf123.z)))), 0.200000003f);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:21: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:21: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/PreserveFloatCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl b/test/unittest/reader/spirv/PreserveFloatCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
new file mode 100644
index 0000000..735611a
--- /dev/null
+++ b/test/unittest/reader/spirv/PreserveFloatCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
@@ -0,0 +1,43 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ vec4 x_73 = texture(x_20, f1);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'sampler1D' : Reserved word.
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/PreserveFloatCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_4.spvasm.expected.glsl b/test/unittest/reader/spirv/PreserveFloatCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_4.spvasm.expected.glsl
new file mode 100644
index 0000000..1919a37
--- /dev/null
+++ b/test/unittest/reader/spirv/PreserveFloatCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_4.spvasm.expected.glsl
@@ -0,0 +1,43 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ float x_73 = texture(x_20, vf12, 0.200000003f);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:21: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:21: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/PreserveIntCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl b/test/unittest/reader/spirv/PreserveIntCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
new file mode 100644
index 0000000..1b96987
--- /dev/null
+++ b/test/unittest/reader/spirv/PreserveIntCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_0.spvasm.expected.glsl
@@ -0,0 +1,42 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ vec4 x_73 = texelFetch(x_20, i1, 0);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'sampler1D' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/PreserveIntCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl b/test/unittest/reader/spirv/PreserveIntCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl
new file mode 100644
index 0000000..46b327e
--- /dev/null
+++ b/test/unittest/reader/spirv/PreserveIntCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_1.spvasm.expected.glsl
@@ -0,0 +1,42 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ vec4 x_71 = texelFetch(x_20, i1, 0);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'sampler1D' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/PreserveIntCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl b/test/unittest/reader/spirv/PreserveIntCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl
new file mode 100644
index 0000000..c15ccc0
--- /dev/null
+++ b/test/unittest/reader/spirv/PreserveIntCoords_NonArrayed_SpvParserHandleTest_ImageCoordsTest_MakeCoordinateOperandsForImageAccess_2.spvasm.expected.glsl
@@ -0,0 +1,42 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp writeonly image1D x_20;
+
+void main_1() {
+ float float_var = 0.0f;
+ int i1 = 1;
+ ivec2 vi12 = ivec2(1, 2);
+ ivec3 vi123 = ivec3(1, 2, 3);
+ ivec4 vi1234 = ivec4(1, 2, 3, 4);
+ uint u1 = 1u;
+ uvec2 vu12 = uvec2(1u, 2u);
+ uvec3 vu123 = uvec3(1u, 2u, 3u);
+ uvec4 vu1234 = uvec4(1u, 2u, 3u, 4u);
+ float f1 = 1.0f;
+ vec2 vf12 = vec2(1.0f, 2.0f);
+ vec3 vf123 = vec3(1.0f, 2.0f, 3.0f);
+ vec4 vf1234 = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ imageStore(x_20, i1, vf1234);
+ uint x_1000 = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'image1D' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_0.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_0.spvasm.expected.glsl
new file mode 100644
index 0000000..44851bb
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_0.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ vec4 x_125 = texelFetch(x_20, int(1u), 0);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'sampler1D' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_1.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_1.spvasm.expected.glsl
new file mode 100644
index 0000000..e98da9d
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_1.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp writeonly image1D x_20;
+
+void main_1() {
+ imageStore(x_20, int(1u), vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'image1D' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_2.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_2.spvasm.expected.glsl
new file mode 100644
index 0000000..1c9d5de
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_2.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler1D x_20;
+
+void main_1() {
+ vec4 x_125 = texelFetch(x_20, int(0u), 0);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:4: 'sampler1D' : Reserved word.
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_5.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_5.spvasm.expected.glsl
new file mode 100644
index 0000000..67b6484
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_5.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ uint x_125 = uint(textureQueryLevels(x_20););
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:7: 'textureQueryLevels' : no matching overloaded function found
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_6.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_6.spvasm.expected.glsl
new file mode 100644
index 0000000..70e014d
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_RawImage_Variable_6.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uniform highp sampler2DMS x_20;
+
+void main_1() {
+ uint x_125 = uint(textureSamples(x_20););
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:7: 'textureSamples' : no matching overloaded function found
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_SampledImage_Variable_4.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_SampledImage_Variable_4.spvasm.expected.glsl
new file mode 100644
index 0000000..bb550c9
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_SampledImage_Variable_4.spvasm.expected.glsl
@@ -0,0 +1,29 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float x_131 = texture(x_20, vec2(0.0f, 0.0f), 0.200000003f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_SampledImage_Variable_8.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_SampledImage_Variable_8.spvasm.expected.glsl
new file mode 100644
index 0000000..a35480e
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_SampledImage_Variable_8.spvasm.expected.glsl
@@ -0,0 +1,29 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float x_131 = texture(x_20, (vec3(0.0f, 0.0f, 0.0f).xy / vec3(0.0f, 0.0f, 0.0f).z), 0.200000003f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_SampledImage_Variable_9.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_SampledImage_Variable_9.spvasm.expected.glsl
new file mode 100644
index 0000000..a35480e
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserHandleTest_RegisterHandleUsage_SampledImage_Variable_9.spvasm.expected.glsl
@@ -0,0 +1,29 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+
+uniform highp sampler2D x_20;
+
+void main_1() {
+ float x_131 = texture(x_20, (vec3(0.0f, 0.0f, 0.0f).xy / vec3(0.0f, 0.0f, 0.0f).z), 0.200000003f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '=' : cannot convert from ' global highp 4-component vector of float' to ' temp mediump float'
+ERROR: 0:8: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_0.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_0.spvasm.expected.glsl
new file mode 100644
index 0000000..1db22da
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_0.spvasm.expected.glsl
@@ -0,0 +1,55 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack4x8snorm(vec4 param_0) {
+ int4 i = int4(round(clamp(param_0, -1.0, 1.0) * 127.0)) & 0xff;
+ return asuint(i.x | i.y << 8 | i.z << 16 | i.w << 24);
+}
+
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ uint x_1 = tint_pack4x8snorm(v4f1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'int4' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_1.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_1.spvasm.expected.glsl
new file mode 100644
index 0000000..76280e7
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_1.spvasm.expected.glsl
@@ -0,0 +1,55 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack4x8unorm(vec4 param_0) {
+ uint4 i = uint4(round(clamp(param_0, 0.0, 1.0) * 255.0));
+ return (i.x | i.y << 8 | i.z << 16 | i.w << 24);
+}
+
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ uint x_1 = tint_pack4x8unorm(v4f1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint4' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_2.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_2.spvasm.expected.glsl
new file mode 100644
index 0000000..55afea2
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_2.spvasm.expected.glsl
@@ -0,0 +1,55 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack2x16snorm(vec2 param_0) {
+ int2 i = int2(round(clamp(param_0, -1.0, 1.0) * 32767.0)) & 0xffff;
+ return asuint(i.x | i.y << 16);
+}
+
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ uint x_1 = tint_pack2x16snorm(v2f1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'int2' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_3.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_3.spvasm.expected.glsl
new file mode 100644
index 0000000..74e88bc
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_3.spvasm.expected.glsl
@@ -0,0 +1,55 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack2x16unorm(vec2 param_0) {
+ uint2 i = uint2(round(clamp(param_0, 0.0, 1.0) * 65535.0));
+ return (i.x | i.y << 16);
+}
+
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ uint x_1 = tint_pack2x16unorm(v2f1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint2' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_4.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_4.spvasm.expected.glsl
new file mode 100644
index 0000000..8ce76c9
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataPacking_Valid_4.spvasm.expected.glsl
@@ -0,0 +1,55 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack2x16float(vec2 param_0) {
+ uint2 i = f32tof16(param_0);
+ return i.x | (i.y << 16);
+}
+
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ uint x_1 = tint_pack2x16float(v2f1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint2' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_0.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_0.spvasm.expected.glsl
new file mode 100644
index 0000000..7081858
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_0.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_unpack4x8snorm(uint param_0) {
+ int j = int(param_0);
+ int4 i = int4(j << 24, j << 16, j << 8, j) >> 24;
+ return clamp(float4(i) / 127.0, -1.0, 1.0);
+}
+
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ vec4 x_1 = tint_unpack4x8snorm(u1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'int4' : undeclared identifier
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_1.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_1.spvasm.expected.glsl
new file mode 100644
index 0000000..0f28621
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_1.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_unpack4x8unorm(uint param_0) {
+ uint j = param_0;
+ uint4 i = uint4(j & 0xff, (j >> 8) & 0xff, (j >> 16) & 0xff, j >> 24);
+ return float4(i) / 255.0;
+}
+
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ vec4 x_1 = tint_unpack4x8unorm(u1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'uint4' : undeclared identifier
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_2.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_2.spvasm.expected.glsl
new file mode 100644
index 0000000..961eccf
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_2.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec2 tint_unpack2x16snorm(uint param_0) {
+ int j = int(param_0);
+ int2 i = int2(j << 16, j) >> 16;
+ return clamp(float2(i) / 32767.0, -1.0, 1.0);
+}
+
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ vec2 x_1 = tint_unpack2x16snorm(u1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'int2' : undeclared identifier
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_3.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_3.spvasm.expected.glsl
new file mode 100644
index 0000000..9821c7e
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_3.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec2 tint_unpack2x16unorm(uint param_0) {
+ uint j = param_0;
+ uint2 i = uint2(j & 0xffff, j >> 16);
+ return float2(i) / 65535.0;
+}
+
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ vec2 x_1 = tint_unpack2x16unorm(u1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'uint2' : undeclared identifier
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_4.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_4.spvasm.expected.glsl
new file mode 100644
index 0000000..e4ede4b
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_DataUnpacking_Valid_4.spvasm.expected.glsl
@@ -0,0 +1,55 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec2 tint_unpack2x16float(uint param_0) {
+ uint i = param_0;
+ return f16tof32(uint2(i & 0xffff, i >> 16));
+}
+
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ vec2 x_1 = tint_unpack2x16float(u1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp highp uint' and a right operand of type ' const int' (or there is no acceptable conversion)
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_FloatingFloatingFloating_Scalar_2.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_FloatingFloatingFloating_Scalar_2.spvasm.expected.glsl
new file mode 100644
index 0000000..509a7a9
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_FloatingFloatingFloating_Scalar_2.spvasm.expected.glsl
@@ -0,0 +1,49 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ float x_1 = mad(f1, f2, f3);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:27: 'mad' : no matching overloaded function found
+ERROR: 0:27: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_FloatingFloatingFloating_Vector_2.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_FloatingFloatingFloating_Vector_2.spvasm.expected.glsl
new file mode 100644
index 0000000..15652f6
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_FloatingFloatingFloating_Vector_2.spvasm.expected.glsl
@@ -0,0 +1,50 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ vec2 x_1 = mad(v2f1, v2f2, v2f3);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:27: 'mad' : no matching overloaded function found
+ERROR: 0:27: '=' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:27: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Scalar_11.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Scalar_11.spvasm.expected.glsl
new file mode 100644
index 0000000..43605c7
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Scalar_11.spvasm.expected.glsl
@@ -0,0 +1,49 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ float x_1 = frac(f1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:27: 'frac' : no matching overloaded function found
+ERROR: 0:27: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Scalar_12.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Scalar_12.spvasm.expected.glsl
new file mode 100644
index 0000000..2705831
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Scalar_12.spvasm.expected.glsl
@@ -0,0 +1,49 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ float x_1 = rsqrt(f1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:27: 'rsqrt' : no matching overloaded function found
+ERROR: 0:27: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Vector_11.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Vector_11.spvasm.expected.glsl
new file mode 100644
index 0000000..bc1cd52
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Vector_11.spvasm.expected.glsl
@@ -0,0 +1,50 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ vec2 x_1 = frac(v2f1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:27: 'frac' : no matching overloaded function found
+ERROR: 0:27: '=' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:27: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Vector_12.spvasm.expected.glsl b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Vector_12.spvasm.expected.glsl
new file mode 100644
index 0000000..9e1f12d
--- /dev/null
+++ b/test/unittest/reader/spirv/Samples_SpvParserTest_GlslStd450_Floating_Floating_Vector_12.spvasm.expected.glsl
@@ -0,0 +1,50 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ uint u2 = 15u;
+ uint u3 = 20u;
+ int i1 = 30;
+ int i2 = 35;
+ int i3 = 40;
+ float f1 = 50.0f;
+ float f2 = 60.0f;
+ float f3 = 70.0f;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ uvec2 v2u2 = uvec2(20u, 10u);
+ uvec2 v2u3 = uvec2(15u, 15u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 v2i2 = ivec2(40, 30);
+ ivec2 v2i3 = ivec2(35, 35);
+ vec2 v2f1 = vec2(50.0f, 60.0f);
+ vec2 v2f2 = vec2(60.0f, 50.0f);
+ vec2 v2f3 = vec2(70.0f, 70.0f);
+ vec3 v3f1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 v3f2 = vec3(60.0f, 70.0f, 50.0f);
+ vec4 v4f1 = vec4(50.0f, 50.0f, 50.0f, 50.0f);
+ vec4 v4f2 = v4f1;
+ vec2 x_1 = rsqrt(v2f1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:27: 'rsqrt' : no matching overloaded function found
+ERROR: 0:27: '=' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:27: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_0.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_0.spvasm.expected.glsl
new file mode 100644
index 0000000..1d906ca
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_0.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ float x_2 = ddx(50.0f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'ddx' : no matching overloaded function found
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_1.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_1.spvasm.expected.glsl
new file mode 100644
index 0000000..a1105e4
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_1.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec2 x_1 = vec2(50.0f, 60.0f);
+ vec2 x_2 = ddx(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddx' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_10.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_10.spvasm.expected.glsl
new file mode 100644
index 0000000..3456486
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_10.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec2 x_1 = vec2(50.0f, 60.0f);
+ vec2 x_2 = ddx_fine(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddx_fine' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_11.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_11.spvasm.expected.glsl
new file mode 100644
index 0000000..29974e7
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_11.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec3 x_1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 x_2 = ddx_fine(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddx_fine' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 3-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_12.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_12.spvasm.expected.glsl
new file mode 100644
index 0000000..fd3597d
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_12.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ float x_2 = ddy_fine(50.0f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'ddy_fine' : no matching overloaded function found
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_13.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_13.spvasm.expected.glsl
new file mode 100644
index 0000000..1b9ae9b
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_13.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec2 x_1 = vec2(50.0f, 60.0f);
+ vec2 x_2 = ddy_fine(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddy_fine' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_14.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_14.spvasm.expected.glsl
new file mode 100644
index 0000000..1f87b8f
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_14.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec3 x_1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 x_2 = ddy_fine(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddy_fine' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 3-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_18.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_18.spvasm.expected.glsl
new file mode 100644
index 0000000..bb31c48
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_18.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ float x_2 = ddx_coarse(50.0f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'ddx_coarse' : no matching overloaded function found
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_19.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_19.spvasm.expected.glsl
new file mode 100644
index 0000000..b3e61a9
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_19.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec2 x_1 = vec2(50.0f, 60.0f);
+ vec2 x_2 = ddx_coarse(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddx_coarse' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_2.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_2.spvasm.expected.glsl
new file mode 100644
index 0000000..f1a003d
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_2.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec3 x_1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 x_2 = ddx(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddx' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 3-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_20.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_20.spvasm.expected.glsl
new file mode 100644
index 0000000..5c76fe2
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_20.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec3 x_1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 x_2 = ddx_coarse(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddx_coarse' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 3-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_21.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_21.spvasm.expected.glsl
new file mode 100644
index 0000000..01e2652
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_21.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ float x_2 = ddy_coarse(50.0f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'ddy_coarse' : no matching overloaded function found
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_22.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_22.spvasm.expected.glsl
new file mode 100644
index 0000000..83646e2
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_22.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec2 x_1 = vec2(50.0f, 60.0f);
+ vec2 x_2 = ddy_coarse(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddy_coarse' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_23.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_23.spvasm.expected.glsl
new file mode 100644
index 0000000..226a2b7
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_23.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec3 x_1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 x_2 = ddy_coarse(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddy_coarse' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 3-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_3.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_3.spvasm.expected.glsl
new file mode 100644
index 0000000..b19185c
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_3.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ float x_2 = ddy(50.0f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'ddy' : no matching overloaded function found
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_4.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_4.spvasm.expected.glsl
new file mode 100644
index 0000000..862536e
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_4.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec2 x_1 = vec2(50.0f, 60.0f);
+ vec2 x_2 = ddy(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddy' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_5.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_5.spvasm.expected.glsl
new file mode 100644
index 0000000..1572671
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_5.spvasm.expected.glsl
@@ -0,0 +1,28 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec3 x_1 = vec3(50.0f, 60.0f, 70.0f);
+ vec3 x_2 = ddy(x_1);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'ddy' : no matching overloaded function found
+ERROR: 0:6: '=' : cannot convert from ' const float' to ' temp mediump 3-component vector of float'
+ERROR: 0:6: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_9.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_9.spvasm.expected.glsl
new file mode 100644
index 0000000..9436845
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvBinaryDerivativeTest_SpvBinaryDerivativeTest_Derivatives_9.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ float x_2 = ddx_fine(50.0f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'ddx_fine' : no matching overloaded function found
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvFUnordTest_FUnordEqual_Vector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvFUnordTest_FUnordEqual_Vector.spvasm.expected.glsl
new file mode 100644
index 0000000..a766f47
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvFUnordTest_FUnordEqual_Vector.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bvec2 x_1 = !(notEqual(vec2(50.0f, 60.0f), vec2(60.0f, 50.0f)));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '!' : wrong operand type no operation '!' exists that takes an operand of type const 2-component vector of bool (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvFUnordTest_FUnordGreaterThanEqual_Vector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvFUnordTest_FUnordGreaterThanEqual_Vector.spvasm.expected.glsl
new file mode 100644
index 0000000..164f83e
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvFUnordTest_FUnordGreaterThanEqual_Vector.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bvec2 x_1 = !(lessThan(vec2(50.0f, 60.0f), vec2(60.0f, 50.0f)));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '!' : wrong operand type no operation '!' exists that takes an operand of type const 2-component vector of bool (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvFUnordTest_FUnordGreaterThan_Vector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvFUnordTest_FUnordGreaterThan_Vector.spvasm.expected.glsl
new file mode 100644
index 0000000..f2de517
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvFUnordTest_FUnordGreaterThan_Vector.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bvec2 x_1 = !(lessThanEqual(vec2(50.0f, 60.0f), vec2(60.0f, 50.0f)));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '!' : wrong operand type no operation '!' exists that takes an operand of type const 2-component vector of bool (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvFUnordTest_FUnordLessThanEqual_Vector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvFUnordTest_FUnordLessThanEqual_Vector.spvasm.expected.glsl
new file mode 100644
index 0000000..2951a83
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvFUnordTest_FUnordLessThanEqual_Vector.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bvec2 x_1 = !(greaterThan(vec2(50.0f, 60.0f), vec2(60.0f, 50.0f)));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '!' : wrong operand type no operation '!' exists that takes an operand of type const 2-component vector of bool (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvFUnordTest_FUnordLessThan_Vector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvFUnordTest_FUnordLessThan_Vector.spvasm.expected.glsl
new file mode 100644
index 0000000..b5884f8
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvFUnordTest_FUnordLessThan_Vector.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bvec2 x_1 = !(greaterThanEqual(vec2(50.0f, 60.0f), vec2(60.0f, 50.0f)));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '!' : wrong operand type no operation '!' exists that takes an operand of type const 2-component vector of bool (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvFUnordTest_FUnordNotEqual_Vector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvFUnordTest_FUnordNotEqual_Vector.spvasm.expected.glsl
new file mode 100644
index 0000000..dbca9a2
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvFUnordTest_FUnordNotEqual_Vector.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bvec2 x_1 = !(equal(vec2(50.0f, 60.0f), vec2(60.0f, 50.0f)));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '!' : wrong operand type no operation '!' exists that takes an operand of type const 2-component vector of bool (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvLogicalTest_Select_VecBoolCond_VectorParams.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvLogicalTest_Select_VecBoolCond_VectorParams.spvasm.expected.glsl
new file mode 100644
index 0000000..39dbc4e
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvLogicalTest_Select_VecBoolCond_VectorParams.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uvec2 x_1 = (bvec2(true, false) ? uvec2(10u, 20u) : uvec2(20u, 10u));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : boolean expression expected
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_In_Signed.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_In_Signed.spvasm.expected.glsl
new file mode 100644
index 0000000..8c3b3f5
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_In_Signed.spvasm.expected.glsl
@@ -0,0 +1,38 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1[1] = int[1](0);
+
+void main_1() {
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1[0] = int(x_1_param);
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleMask);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_In_Unsigned.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_In_Unsigned.spvasm.expected.glsl
new file mode 100644
index 0000000..637586c
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_In_Unsigned.spvasm.expected.glsl
@@ -0,0 +1,38 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1[1] = uint[1](0u);
+
+void main_1() {
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1[0] = x_1_param;
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleMask);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_Out_Signed_Initializer.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_Out_Signed_Initializer.spvasm.expected.glsl
new file mode 100644
index 0000000..bffe830
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_Out_Signed_Initializer.spvasm.expected.glsl
@@ -0,0 +1,44 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1[1] = int[1](0);
+
+void main_1() {
+ return;
+}
+
+struct main_out {
+ uint x_1_1;
+};
+struct tint_symbol_1 {
+ uint x_1_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(uint(x_1[0]));
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(0u);
+ wrapper_result.x_1_1 = inner_result.x_1_1;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ gl_SampleMask = outputs.x_1_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_Out_Unsigned_Initializer.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_Out_Unsigned_Initializer.spvasm.expected.glsl
new file mode 100644
index 0000000..6cd8aae
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_BuiltinVar_SampleMask_Out_Unsigned_Initializer.spvasm.expected.glsl
@@ -0,0 +1,44 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1[1] = uint[1](0u);
+
+void main_1() {
+ return;
+}
+
+struct main_out {
+ uint x_1_1;
+};
+struct tint_symbol_1 {
+ uint x_1_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_1[0]);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(0u);
+ wrapper_result.x_1_1 = inner_result.x_1_1;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ gl_SampleMask = outputs.x_1_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_IOLocations.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_IOLocations.spvasm.expected.glsl
new file mode 100644
index 0000000..985de6f
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_EntryPointWrapping_IOLocations.spvasm.expected.glsl
@@ -0,0 +1,66 @@
+SKIP: FAILED
+
+warning: integral user-defined fragment inputs must have a flat interpolation attribute
+warning: integral user-defined fragment inputs must have a flat interpolation attribute
+#version 310 es
+precision mediump float;
+
+uint x_1 = 0u;
+uint x_2 = 0u;
+uint x_3 = 0u;
+uint x_4 = 0u;
+
+void main_1() {
+ return;
+}
+
+struct main_out {
+ uint x_2_1;
+ uint x_4_1;
+};
+struct tint_symbol_2 {
+ uint x_1_param;
+ uint x_3_param;
+};
+struct tint_symbol_3 {
+ uint x_2_1;
+ uint x_4_1;
+};
+
+main_out tint_symbol_inner(uint x_1_param, uint x_3_param) {
+ x_1 = x_1_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_2, x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_1_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0u, 0u);
+ wrapper_result.x_2_1 = inner_result.x_2_1;
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in uint x_1_param;
+in uint x_3_param;
+out uint x_2_1;
+out uint x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = x_1_param;
+ inputs.x_3_param = x_3_param;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_2_1 = outputs.x_2_1;
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:41: 'uint' : must be qualified as flat in
+ERROR: 0:41: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_I32_Load_AccessChain.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_I32_Load_AccessChain.spvasm.expected.glsl
new file mode 100644
index 0000000..92de96e
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_I32_Load_AccessChain.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1 = 0;
+
+void main_1() {
+ int x_2 = x_1;
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1 = int(x_1_param);
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleID);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleID' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_I32_Load_CopyObject.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_I32_Load_CopyObject.spvasm.expected.glsl
new file mode 100644
index 0000000..92de96e
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_I32_Load_CopyObject.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1 = 0;
+
+void main_1() {
+ int x_2 = x_1;
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1 = int(x_1_param);
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleID);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleID' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_I32_Load_Direct.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_I32_Load_Direct.spvasm.expected.glsl
new file mode 100644
index 0000000..92de96e
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_I32_Load_Direct.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1 = 0;
+
+void main_1() {
+ int x_2 = x_1;
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1 = int(x_1_param);
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleID);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleID' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_U32_Load_AccessChain.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_U32_Load_AccessChain.spvasm.expected.glsl
new file mode 100644
index 0000000..6436f0c
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_U32_Load_AccessChain.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1 = 0u;
+
+void main_1() {
+ uint x_2 = x_1;
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1 = x_1_param;
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleID);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleID' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_U32_Load_CopyObject.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_U32_Load_CopyObject.spvasm.expected.glsl
new file mode 100644
index 0000000..6436f0c
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_U32_Load_CopyObject.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1 = 0u;
+
+void main_1() {
+ uint x_2 = x_1;
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1 = x_1_param;
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleID);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleID' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_U32_Load_Direct.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_U32_Load_Direct.spvasm.expected.glsl
new file mode 100644
index 0000000..6436f0c
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleId_U32_Load_Direct.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1 = 0u;
+
+void main_1() {
+ uint x_2 = x_1;
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1 = x_1_param;
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleID);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleID' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_I32_AccessChain.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_I32_AccessChain.spvasm.expected.glsl
new file mode 100644
index 0000000..de101d6
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_I32_AccessChain.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1[1] = int[1](0);
+
+void main_1() {
+ int x_4 = x_1[0];
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1[0] = int(x_1_param);
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleMask);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_I32_CopyObject.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_I32_CopyObject.spvasm.expected.glsl
new file mode 100644
index 0000000..de101d6
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_I32_CopyObject.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1[1] = int[1](0);
+
+void main_1() {
+ int x_4 = x_1[0];
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1[0] = int(x_1_param);
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleMask);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_I32_Direct.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_I32_Direct.spvasm.expected.glsl
new file mode 100644
index 0000000..6c0bae1
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_I32_Direct.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1[1] = int[1](0);
+
+void main_1() {
+ int x_3 = x_1[0];
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1[0] = int(x_1_param);
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleMask);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_U32_AccessChain.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_U32_AccessChain.spvasm.expected.glsl
new file mode 100644
index 0000000..f4ee437
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_U32_AccessChain.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1[1] = uint[1](0u);
+
+void main_1() {
+ uint x_4 = x_1[0];
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1[0] = x_1_param;
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleMask);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_U32_CopyObject.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_U32_CopyObject.spvasm.expected.glsl
new file mode 100644
index 0000000..f4ee437
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_U32_CopyObject.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1[1] = uint[1](0u);
+
+void main_1() {
+ uint x_4 = x_1[0];
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1[0] = x_1_param;
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleMask);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_U32_Direct.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_U32_Direct.spvasm.expected.glsl
new file mode 100644
index 0000000..d635d56
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_U32_Direct.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1[1] = uint[1](0u);
+
+void main_1() {
+ uint x_3 = x_1[0];
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1[0] = x_1_param;
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleMask);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_WithStride.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_WithStride.spvasm.expected.glsl
new file mode 100644
index 0000000..d635d56
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_In_WithStride.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1[1] = uint[1](0u);
+
+void main_1() {
+ uint x_3 = x_1[0];
+ return;
+}
+
+struct tint_symbol_2 {
+ uint x_1_param;
+};
+
+void tint_symbol_inner(uint x_1_param) {
+ x_1[0] = x_1_param;
+ main_1();
+}
+
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_1_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_1_param = uint(gl_SampleMask);
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_I32_AccessChain.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_I32_AccessChain.spvasm.expected.glsl
new file mode 100644
index 0000000..379bae1
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_I32_AccessChain.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1[1] = int[1](0);
+
+void main_1() {
+ x_1[0] = 12;
+ return;
+}
+
+struct main_out {
+ uint x_1_1;
+};
+struct tint_symbol_1 {
+ uint x_1_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(uint(x_1[0]));
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(0u);
+ wrapper_result.x_1_1 = inner_result.x_1_1;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ gl_SampleMask = outputs.x_1_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_I32_CopyObject.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_I32_CopyObject.spvasm.expected.glsl
new file mode 100644
index 0000000..379bae1
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_I32_CopyObject.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1[1] = int[1](0);
+
+void main_1() {
+ x_1[0] = 12;
+ return;
+}
+
+struct main_out {
+ uint x_1_1;
+};
+struct tint_symbol_1 {
+ uint x_1_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(uint(x_1[0]));
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(0u);
+ wrapper_result.x_1_1 = inner_result.x_1_1;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ gl_SampleMask = outputs.x_1_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_I32_Direct.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_I32_Direct.spvasm.expected.glsl
new file mode 100644
index 0000000..379bae1
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_I32_Direct.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+int x_1[1] = int[1](0);
+
+void main_1() {
+ x_1[0] = 12;
+ return;
+}
+
+struct main_out {
+ uint x_1_1;
+};
+struct tint_symbol_1 {
+ uint x_1_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(uint(x_1[0]));
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(0u);
+ wrapper_result.x_1_1 = inner_result.x_1_1;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ gl_SampleMask = outputs.x_1_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_U32_AccessChain.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_U32_AccessChain.spvasm.expected.glsl
new file mode 100644
index 0000000..ba1f6fe
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_U32_AccessChain.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1[1] = uint[1](0u);
+
+void main_1() {
+ x_1[0] = 0u;
+ return;
+}
+
+struct main_out {
+ uint x_1_1;
+};
+struct tint_symbol_1 {
+ uint x_1_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_1[0]);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(0u);
+ wrapper_result.x_1_1 = inner_result.x_1_1;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ gl_SampleMask = outputs.x_1_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_U32_CopyObject.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_U32_CopyObject.spvasm.expected.glsl
new file mode 100644
index 0000000..ba1f6fe
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_U32_CopyObject.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1[1] = uint[1](0u);
+
+void main_1() {
+ x_1[0] = 0u;
+ return;
+}
+
+struct main_out {
+ uint x_1_1;
+};
+struct tint_symbol_1 {
+ uint x_1_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_1[0]);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(0u);
+ wrapper_result.x_1_1 = inner_result.x_1_1;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ gl_SampleMask = outputs.x_1_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_U32_Direct.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_U32_Direct.spvasm.expected.glsl
new file mode 100644
index 0000000..ba1f6fe
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_U32_Direct.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1[1] = uint[1](0u);
+
+void main_1() {
+ x_1[0] = 0u;
+ return;
+}
+
+struct main_out {
+ uint x_1_1;
+};
+struct tint_symbol_1 {
+ uint x_1_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_1[0]);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(0u);
+ wrapper_result.x_1_1 = inner_result.x_1_1;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ gl_SampleMask = outputs.x_1_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_WithStride.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_WithStride.spvasm.expected.glsl
new file mode 100644
index 0000000..ba1f6fe
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvModuleScopeVarParserTest_SampleMask_Out_WithStride.spvasm.expected.glsl
@@ -0,0 +1,45 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint x_1[1] = uint[1](0u);
+
+void main_1() {
+ x_1[0] = 0u;
+ return;
+}
+
+struct main_out {
+ uint x_1_1;
+};
+struct tint_symbol_1 {
+ uint x_1_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_1[0]);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(0u);
+ wrapper_result.x_1_1 = inner_result.x_1_1;
+ return wrapper_result;
+}
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ gl_SampleMask = outputs.x_1_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: 'gl_SampleMask' : required extension not requested: GL_OES_sample_variables
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserFunctionVarTest_EmitStatement_UseInPhiCountsAsUse.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserFunctionVarTest_EmitStatement_UseInPhiCountsAsUse.spvasm.expected.glsl
new file mode 100644
index 0000000..30bfae9
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserFunctionVarTest_EmitStatement_UseInPhiCountsAsUse.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0;
+ float field1;
+ uint field2[2];
+};
+
+void main_1() {
+ bool x_101_phi = false;
+ bool x_11 = (true & true);
+ bool x_12 = !(x_11);
+ x_101_phi = x_11;
+ if (true) {
+ x_101_phi = x_12;
+ }
+ bool x_101 = x_101_phi;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:12: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' const bool' and a right operand of type ' const bool' (or there is no acceptable conversion)
+ERROR: 0:12: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserMemoryTest_ArrayLength_FromAccessChain.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserMemoryTest_ArrayLength_FromAccessChain.spvasm.expected.glsl
new file mode 100644
index 0000000..b94f5aa
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserMemoryTest_ArrayLength_FromAccessChain.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint first;
+ uint rtarr[];
+};
+
+layout (binding = 0) buffer S_1 {
+ uint first;
+ uint rtarr[];
+} myvar;
+
+void main_1() {
+ uint tint_symbol_2 = 0u;
+ myvar.GetDimensions(tint_symbol_2);
+ uint tint_symbol_3 = ((tint_symbol_2 - 4u) / 4u);
+ uint x_1 = tint_symbol_3;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '' : array size required
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserMemoryTest_ArrayLength_FromVar.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserMemoryTest_ArrayLength_FromVar.spvasm.expected.glsl
new file mode 100644
index 0000000..b94f5aa
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserMemoryTest_ArrayLength_FromVar.spvasm.expected.glsl
@@ -0,0 +1,39 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint first;
+ uint rtarr[];
+};
+
+layout (binding = 0) buffer S_1 {
+ uint first;
+ uint rtarr[];
+} myvar;
+
+void main_1() {
+ uint tint_symbol_2 = 0u;
+ myvar.GetDimensions(tint_symbol_2);
+ uint tint_symbol_3 = ((tint_symbol_2 - 4u) / 4u);
+ uint x_1 = tint_symbol_3;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '' : array size required
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserMemoryTest_EmitStatement_AccessChain_Struct_RuntimeArray.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserMemoryTest_EmitStatement_AccessChain_Struct_RuntimeArray.spvasm.expected.glsl
new file mode 100644
index 0000000..22449c5
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserMemoryTest_EmitStatement_AccessChain_Struct_RuntimeArray.spvasm.expected.glsl
@@ -0,0 +1,36 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ float field0;
+ float age[];
+};
+
+layout (binding = 0) buffer S_1 {
+ float field0;
+ float age[];
+} myvar;
+
+void main_1() {
+ myvar.age[2u] = 42.0f;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '' : array size required
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_ThroughAccessChain_Cascaded.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_ThroughAccessChain_Cascaded.spvasm.expected.glsl
new file mode 100644
index 0000000..af6e73c
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_ThroughAccessChain_Cascaded.spvasm.expected.glsl
@@ -0,0 +1,36 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0;
+ uint field1[];
+};
+
+layout (binding = 0) buffer S_1 {
+ uint field0;
+ uint field1[];
+} myvar;
+
+void main_1() {
+ myvar.field1[1u] = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '' : array size required
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_ThroughAccessChain_NonCascaded.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_ThroughAccessChain_NonCascaded.spvasm.expected.glsl
new file mode 100644
index 0000000..e3420f7
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_ThroughAccessChain_NonCascaded.spvasm.expected.glsl
@@ -0,0 +1,37 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0;
+ uint field1[];
+};
+
+layout (binding = 0) buffer S_1 {
+ uint field0;
+ uint field1[];
+} myvar;
+
+void main_1() {
+ myvar.field0 = 0u;
+ myvar.field1[1u] = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '' : array size required
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_ThroughAccessChain_NonCascaded_InBoundsAccessChain.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_ThroughAccessChain_NonCascaded_InBoundsAccessChain.spvasm.expected.glsl
new file mode 100644
index 0000000..e3420f7
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_ThroughAccessChain_NonCascaded_InBoundsAccessChain.spvasm.expected.glsl
@@ -0,0 +1,37 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0;
+ uint field1[];
+};
+
+layout (binding = 0) buffer S_1 {
+ uint field0;
+ uint field1[];
+} myvar;
+
+void main_1() {
+ myvar.field0 = 0u;
+ myvar.field1[1u] = 0u;
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '' : array size required
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_TypesAndVarDeclarations.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_TypesAndVarDeclarations.spvasm.expected.glsl
new file mode 100644
index 0000000..4eb2657
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserMemoryTest_RemapStorageBuffer_TypesAndVarDeclarations.spvasm.expected.glsl
@@ -0,0 +1,30 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0;
+ uint field1[];
+};
+
+void main_1() {
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '' : array size required
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserTest_FRem_SpvBinaryArithTest_EmitExpression_0.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserTest_FRem_SpvBinaryArithTest_EmitExpression_0.spvasm.expected.glsl
new file mode 100644
index 0000000..4e6c407
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserTest_FRem_SpvBinaryArithTest_EmitExpression_0.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ float x_1 = (50.0f % 60.0f);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' const float' and a right operand of type ' const float' (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserTest_FRem_SpvBinaryArithTest_EmitExpression_1.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserTest_FRem_SpvBinaryArithTest_EmitExpression_1.spvasm.expected.glsl
new file mode 100644
index 0000000..745736c
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserTest_FRem_SpvBinaryArithTest_EmitExpression_1.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ vec2 x_1 = (vec2(50.0f, 60.0f) % vec2(60.0f, 50.0f));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' const 2-component vector of float' and a right operand of type ' const 2-component vector of float' (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserTest_LogicalAnd_SpvBinaryLogicalTest_EmitExpression_0.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserTest_LogicalAnd_SpvBinaryLogicalTest_EmitExpression_0.spvasm.expected.glsl
new file mode 100644
index 0000000..95c53e7
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserTest_LogicalAnd_SpvBinaryLogicalTest_EmitExpression_0.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bool x_1 = (true & false);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' const bool' and a right operand of type ' const bool' (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserTest_LogicalAnd_SpvBinaryLogicalTest_EmitExpression_1.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserTest_LogicalAnd_SpvBinaryLogicalTest_EmitExpression_1.spvasm.expected.glsl
new file mode 100644
index 0000000..ffdfd77
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserTest_LogicalAnd_SpvBinaryLogicalTest_EmitExpression_1.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bvec2 x_1 = (bvec2(true, false) & bvec2(false, true));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' const 2-component vector of bool' and a right operand of type ' const 2-component vector of bool' (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserTest_LogicalOr_SpvBinaryLogicalTest_EmitExpression_0.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserTest_LogicalOr_SpvBinaryLogicalTest_EmitExpression_0.spvasm.expected.glsl
new file mode 100644
index 0000000..0096563
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserTest_LogicalOr_SpvBinaryLogicalTest_EmitExpression_0.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bool x_1 = (true | false);
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '|' : wrong operand types: no operation '|' exists that takes a left-hand operand of type ' const bool' and a right operand of type ' const bool' (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserTest_LogicalOr_SpvBinaryLogicalTest_EmitExpression_1.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserTest_LogicalOr_SpvBinaryLogicalTest_EmitExpression_1.spvasm.expected.glsl
new file mode 100644
index 0000000..40e3619
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserTest_LogicalOr_SpvBinaryLogicalTest_EmitExpression_1.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bvec2 x_1 = (bvec2(true, false) | bvec2(false, true));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '|' : wrong operand types: no operation '|' exists that takes a left-hand operand of type ' const 2-component vector of bool' and a right operand of type ' const 2-component vector of bool' (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvParserTest_VectorExtractDynamic_UnsignedIndex.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvParserTest_VectorExtractDynamic_UnsignedIndex.spvasm.expected.glsl
new file mode 100644
index 0000000..b471ece
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvParserTest_VectorExtractDynamic_UnsignedIndex.spvasm.expected.glsl
@@ -0,0 +1,34 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ vec2 field0;
+ uint field1;
+ int field2;
+};
+
+void main_1() {
+ uvec2 x_1 = uvec2(3u, 4u);
+ uint x_10 = x_1[3u];
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:12: '[' : vector index out of range '3'
+ERROR: 0:12: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_IntVector_IntVector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_IntVector_IntVector.spvasm.expected.glsl
new file mode 100644
index 0000000..0cdf61d
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_IntVector_IntVector.spvasm.expected.glsl
@@ -0,0 +1,32 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 x_1 = countbits(v2i1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'countbits' : no matching overloaded function found
+ERROR: 0:9: '=' : cannot convert from ' const float' to ' temp highp 2-component vector of int'
+ERROR: 0:9: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_IntVector_UintVector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_IntVector_UintVector.spvasm.expected.glsl
new file mode 100644
index 0000000..ae0458c
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_IntVector_UintVector.spvasm.expected.glsl
@@ -0,0 +1,31 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 x_1 = ivec2(countbits(v2u1));
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'countbits' : no matching overloaded function found
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Int_Int.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Int_Int.spvasm.expected.glsl
new file mode 100644
index 0000000..4e6f39e
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Int_Int.spvasm.expected.glsl
@@ -0,0 +1,32 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ int x_1 = countbits(i1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'countbits' : no matching overloaded function found
+ERROR: 0:9: '=' : cannot convert from ' const float' to ' temp highp int'
+ERROR: 0:9: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Int_Uint.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Int_Uint.spvasm.expected.glsl
new file mode 100644
index 0000000..f2fd90c
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Int_Uint.spvasm.expected.glsl
@@ -0,0 +1,31 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ int x_1 = int(countbits(u1));
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'countbits' : no matching overloaded function found
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_UintVector_IntVector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_UintVector_IntVector.spvasm.expected.glsl
new file mode 100644
index 0000000..1eb004d
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_UintVector_IntVector.spvasm.expected.glsl
@@ -0,0 +1,31 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ uvec2 x_1 = uvec2(countbits(v2i1));
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'countbits' : no matching overloaded function found
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_UintVector_UintVector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_UintVector_UintVector.spvasm.expected.glsl
new file mode 100644
index 0000000..3eb3c66
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_UintVector_UintVector.spvasm.expected.glsl
@@ -0,0 +1,32 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ uvec2 x_1 = countbits(v2u1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'countbits' : no matching overloaded function found
+ERROR: 0:9: '=' : cannot convert from ' const float' to ' temp highp 2-component vector of uint'
+ERROR: 0:9: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Uint_Int.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Uint_Int.spvasm.expected.glsl
new file mode 100644
index 0000000..43f8422
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Uint_Int.spvasm.expected.glsl
@@ -0,0 +1,31 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ uint x_1 = uint(countbits(i1));
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'countbits' : no matching overloaded function found
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Uint_Uint.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Uint_Uint.spvasm.expected.glsl
new file mode 100644
index 0000000..5bd9c57
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitCount_Uint_Uint.spvasm.expected.glsl
@@ -0,0 +1,32 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ uint x_1 = countbits(u1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'countbits' : no matching overloaded function found
+ERROR: 0:9: '=' : cannot convert from ' const float' to ' temp highp uint'
+ERROR: 0:9: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_IntVector_IntVector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_IntVector_IntVector.spvasm.expected.glsl
new file mode 100644
index 0000000..a16703a
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_IntVector_IntVector.spvasm.expected.glsl
@@ -0,0 +1,32 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ ivec2 x_1 = reversebits(v2i1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'reversebits' : no matching overloaded function found
+ERROR: 0:9: '=' : cannot convert from ' const float' to ' temp highp 2-component vector of int'
+ERROR: 0:9: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_Int_Int.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_Int_Int.spvasm.expected.glsl
new file mode 100644
index 0000000..3b1ac96
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_Int_Int.spvasm.expected.glsl
@@ -0,0 +1,32 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ int x_1 = reversebits(i1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'reversebits' : no matching overloaded function found
+ERROR: 0:9: '=' : cannot convert from ' const float' to ' temp highp int'
+ERROR: 0:9: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_UintVector_UintVector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_UintVector_UintVector.spvasm.expected.glsl
new file mode 100644
index 0000000..718f4a6
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_UintVector_UintVector.spvasm.expected.glsl
@@ -0,0 +1,32 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ uvec2 x_1 = reversebits(v2u1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'reversebits' : no matching overloaded function found
+ERROR: 0:9: '=' : cannot convert from ' const float' to ' temp highp 2-component vector of uint'
+ERROR: 0:9: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_Uint_Uint.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_Uint_Uint.spvasm.expected.glsl
new file mode 100644
index 0000000..b4f442d
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryBitTest_BitReverse_Uint_Uint.spvasm.expected.glsl
@@ -0,0 +1,32 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ uint u1 = 10u;
+ int i1 = 30;
+ uvec2 v2u1 = uvec2(10u, 20u);
+ ivec2 v2i1 = ivec2(30, 40);
+ uint x_1 = reversebits(u1);
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: 'reversebits' : no matching overloaded function found
+ERROR: 0:9: '=' : cannot convert from ' const float' to ' temp highp uint'
+ERROR: 0:9: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/unittest/reader/spirv/SpvUnaryLogicalTest_LogicalNot_Vector.spvasm.expected.glsl b/test/unittest/reader/spirv/SpvUnaryLogicalTest_LogicalNot_Vector.spvasm.expected.glsl
new file mode 100644
index 0000000..4782c6f
--- /dev/null
+++ b/test/unittest/reader/spirv/SpvUnaryLogicalTest_LogicalNot_Vector.spvasm.expected.glsl
@@ -0,0 +1,26 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+void main_1() {
+ bvec2 x_1 = !(bvec2(true, false));
+ return;
+}
+
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '!' : wrong operand type no operation '!' exists that takes an operand of type const 2-component vector of bool (or there is no acceptable conversion)
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/barrier-in-loop-with-break/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/barrier-in-loop-with-break/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..0b741de
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/barrier-in-loop-with-break/0-opt.spvasm.expected.glsl
@@ -0,0 +1,78 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct doesNotMatter {
+ int global_seed;
+ int data[];
+};
+struct buf1 {
+ vec2 injectionSwitch;
+};
+
+uvec3 tint_symbol = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer doesNotMatter_1 {
+ int global_seed;
+ int data[];
+} x_7;
+layout (binding = 1) uniform buf1_1 {
+ vec2 injectionSwitch;
+} x_10;
+
+void main_1() {
+ int lid = 0;
+ int val = 0;
+ int i = 0;
+ uint x_40 = tint_symbol.x;
+ lid = int(x_40);
+ int x_43 = x_7.global_seed;
+ val = x_43;
+ i = 0;
+ {
+ for(; (i < 2); i = (i + 1)) {
+ if ((lid > 0)) {
+ int x_58 = x_7.data[(lid - 1)];
+ val = (val + x_58);
+ float x_62 = x_10.injectionSwitch.x;
+ if ((x_62 > 100.0f)) {
+ break;
+ }
+ }
+ memoryBarrierShared();
+ }
+ }
+ if ((lid == 0)) {
+ x_7.data[0] = 42;
+ }
+ return;
+}
+
+struct tint_symbol_4 {
+ uvec3 tint_symbol_2;
+};
+
+void tint_symbol_1_inner(uvec3 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+}
+
+layout(local_size_x = 16, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ return;
+}
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_LocalInvocationID;
+ tint_symbol_1(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '' : array size required
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/barrier-in-loop-with-break/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/barrier-in-loop-with-break/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..0b741de
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/barrier-in-loop-with-break/0-opt.wgsl.expected.glsl
@@ -0,0 +1,78 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct doesNotMatter {
+ int global_seed;
+ int data[];
+};
+struct buf1 {
+ vec2 injectionSwitch;
+};
+
+uvec3 tint_symbol = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer doesNotMatter_1 {
+ int global_seed;
+ int data[];
+} x_7;
+layout (binding = 1) uniform buf1_1 {
+ vec2 injectionSwitch;
+} x_10;
+
+void main_1() {
+ int lid = 0;
+ int val = 0;
+ int i = 0;
+ uint x_40 = tint_symbol.x;
+ lid = int(x_40);
+ int x_43 = x_7.global_seed;
+ val = x_43;
+ i = 0;
+ {
+ for(; (i < 2); i = (i + 1)) {
+ if ((lid > 0)) {
+ int x_58 = x_7.data[(lid - 1)];
+ val = (val + x_58);
+ float x_62 = x_10.injectionSwitch.x;
+ if ((x_62 > 100.0f)) {
+ break;
+ }
+ }
+ memoryBarrierShared();
+ }
+ }
+ if ((lid == 0)) {
+ x_7.data[0] = 42;
+ }
+ return;
+}
+
+struct tint_symbol_4 {
+ uvec3 tint_symbol_2;
+};
+
+void tint_symbol_1_inner(uvec3 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+}
+
+layout(local_size_x = 16, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ return;
+}
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_LocalInvocationID;
+ tint_symbol_1(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: '' : array size required
+ERROR: 0:7: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/control-flow-in-function/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/control-flow-in-function/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..350b540
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/control-flow-in-function/0-opt.spvasm.expected.glsl
@@ -0,0 +1,232 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_25;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+vec3 drawShape_vf2_(inout vec2 pos) {
+ bool c2 = false;
+ bool c3 = false;
+ bool c4 = false;
+ bool c5 = false;
+ bool c6 = false;
+ int GLF_live4i = 0;
+ int GLF_live4_looplimiter5 = 0;
+ mat4x2 GLF_live7m42 = mat4x2(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ mat3 GLF_live7m33 = mat3(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ int GLF_live7cols = 0;
+ int GLF_live7_looplimiter3 = 0;
+ int GLF_live7rows = 0;
+ int GLF_live7_looplimiter2 = 0;
+ int GLF_live7_looplimiter1 = 0;
+ int GLF_live7c = 0;
+ int GLF_live7r = 0;
+ int GLF_live7_looplimiter0 = 0;
+ int GLF_live7sum_index = 0;
+ int GLF_live7_looplimiter7 = 0;
+ int GLF_live7cols_1 = 0;
+ int GLF_live7rows_1 = 0;
+ float GLF_live7sums[9] = float[9](0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ int GLF_live7c_1 = 0;
+ int GLF_live7r_1 = 0;
+ int x_180 = 0;
+ mat3 indexable = mat3(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ float x_182 = pos.x;
+ c2 = (x_182 > 1.0f);
+ if (c2) {
+ return vec3(1.0f, 1.0f, 1.0f);
+ }
+ float x_188 = pos.y;
+ c3 = (x_188 < 1.0f);
+ if (c3) {
+ return vec3(1.0f, 1.0f, 1.0f);
+ }
+ float x_194 = pos.y;
+ c4 = (x_194 > 1.0f);
+ if (c4) {
+ return vec3(1.0f, 1.0f, 1.0f);
+ }
+ float x_200 = pos.x;
+ c5 = (x_200 < 1.0f);
+ if (c5) {
+ return vec3(1.0f, 1.0f, 1.0f);
+ }
+ float x_206 = pos.x;
+ c6 = ((x_206 + 1.0f) > 1.0f);
+ if (c6) {
+ return vec3(1.0f, 1.0f, 1.0f);
+ }
+ GLF_live4i = 0;
+ {
+ for(; (GLF_live4i < 4); GLF_live4i = (GLF_live4i + 1)) {
+ if ((GLF_live4_looplimiter5 >= 7)) {
+ break;
+ }
+ GLF_live4_looplimiter5 = (GLF_live4_looplimiter5 + 1);
+ GLF_live7m42 = mat4x2(vec2(1.0f, 0.0f), vec2(0.0f, 1.0f), vec2(0.0f, 0.0f), vec2(1.0f, 0.0f));
+ GLF_live7m33 = mat3(vec3(1.0f, 0.0f, 0.0f), vec3(0.0f, 1.0f, 0.0f), vec3(0.0f, 0.0f, 1.0f));
+ GLF_live7cols = 2;
+ {
+ for(; (GLF_live7cols < 4); GLF_live7cols = (GLF_live7cols + 1)) {
+ if ((GLF_live7_looplimiter3 >= 7)) {
+ break;
+ }
+ GLF_live7_looplimiter3 = (GLF_live7_looplimiter3 + 1);
+ GLF_live7rows = 2;
+ {
+ for(; (GLF_live7rows < 4); GLF_live7rows = (GLF_live7rows + 1)) {
+ if ((GLF_live7_looplimiter2 >= 7)) {
+ break;
+ }
+ GLF_live7_looplimiter2 = (GLF_live7_looplimiter2 + 1);
+ GLF_live7_looplimiter1 = 0;
+ GLF_live7c = 0;
+ {
+ for(; (GLF_live7c < 3); GLF_live7c = (GLF_live7c + 1)) {
+ if ((GLF_live7_looplimiter1 >= 7)) {
+ break;
+ }
+ GLF_live7_looplimiter1 = (GLF_live7_looplimiter1 + 1);
+ GLF_live7r = 0;
+ {
+ for(; (GLF_live7r < 2); GLF_live7r = (GLF_live7r + 1)) {
+ if ((GLF_live7_looplimiter0 >= 7)) {
+ break;
+ }
+ GLF_live7_looplimiter0 = (GLF_live7_looplimiter0 + 1);
+ GLF_live7m33[(((GLF_live7c >= 0) & (GLF_live7c < 3)) ? GLF_live7c : 0)][(((GLF_live7r >= 0) & (GLF_live7r < 3)) ? GLF_live7r : 0)] = 1.0f;
+ float x_267 = x_25.injectionSwitch.y;
+ if ((0.0f > x_267)) {
+ } else {
+ GLF_live7m42[(((GLF_live7c >= 0) & (GLF_live7c < 4)) ? GLF_live7c : 0)][(((GLF_live7r >= 0) & (GLF_live7r < 2)) ? GLF_live7r : 0)] = 1.0f;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ GLF_live7sum_index = 0;
+ GLF_live7_looplimiter7 = 0;
+ GLF_live7cols_1 = 2;
+ {
+ for(; (GLF_live7cols_1 < 4); GLF_live7cols_1 = (GLF_live7cols_1 + 1)) {
+ if ((GLF_live7_looplimiter7 >= 7)) {
+ break;
+ }
+ GLF_live7_looplimiter7 = (GLF_live7_looplimiter7 + 1);
+ GLF_live7rows_1 = 2;
+ GLF_live7sums[(((GLF_live7sum_index >= 0) & (GLF_live7sum_index < 9)) ? GLF_live7sum_index : 0)] = 0.0f;
+ GLF_live7c_1 = 0;
+ {
+ for(; (GLF_live7c_1 < 1); GLF_live7c_1 = (GLF_live7c_1 + 1)) {
+ GLF_live7r_1 = 0;
+ {
+ for(; (GLF_live7r_1 < GLF_live7rows_1); GLF_live7r_1 = (GLF_live7r_1 + 1)) {
+ int x_310 = (((GLF_live7sum_index >= 0) & (GLF_live7sum_index < 9)) ? GLF_live7sum_index : 0);
+ mat3 x_312 = transpose(GLF_live7m33);
+ if ((GLF_live7c_1 < 3)) {
+ x_180 = 1;
+ } else {
+ float x_318 = x_25.injectionSwitch.x;
+ x_180 = int(x_318);
+ }
+ int x_320 = x_180;
+ int x_93 = GLF_live7r_1;
+ indexable = x_312;
+ float x_324 = indexable[x_320][((x_93 < 3) ? 1 : 0)];
+ float x_326 = GLF_live7sums[x_310];
+ GLF_live7sums[x_310] = (x_326 + x_324);
+ int x_332 = (((GLF_live7sum_index >= 0) & (GLF_live7sum_index < 9)) ? GLF_live7sum_index : 0);
+ float x_334 = GLF_live7m42[1][GLF_live7r_1];
+ float x_336 = GLF_live7sums[x_332];
+ GLF_live7sums[x_332] = (x_336 + x_334);
+ }
+ }
+ }
+ }
+ GLF_live7sum_index = (GLF_live7sum_index + 1);
+ }
+ }
+ }
+ }
+ return vec3(1.0f, 1.0f, 1.0f);
+}
+
+void main_1() {
+ vec2 position = vec2(0.0f, 0.0f);
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ int i = 0;
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ float x_161 = x_25.injectionSwitch.x;
+ if ((x_161 >= 2.0f)) {
+ vec4 x_165 = tint_symbol;
+ position = vec2(x_165.x, x_165.y);
+ param = position;
+ vec3 x_168 = drawShape_vf2_(param);
+ param_1 = position;
+ vec3 x_170 = drawShape_vf2_(param_1);
+ i = 25;
+ {
+ for(; (i > 0); i = (i - 1)) {
+ param_2 = position;
+ vec3 x_178 = drawShape_vf2_(param_2);
+ }
+ }
+ }
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:104: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:104: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-apfloat-mod-zero/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-mod-zero/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..93c7012
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-mod-zero/0-opt.wgsl.expected.glsl
@@ -0,0 +1,90 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[1];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[1];
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float undefined = 0.0f;
+ bool x_51 = false;
+ bool x_52_phi = false;
+ undefined = (5.0f % 0.0f);
+ int x_10 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_11 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_12 = x_6.x_GLF_uniform_int_values[1].el;
+ bool x_44 = (x_10 == (x_11 + x_12));
+ x_52_phi = x_44;
+ if (!(x_44)) {
+ float x_48 = undefined;
+ float x_50 = x_8.x_GLF_uniform_float_values[0].el;
+ x_51 = (x_48 > x_50);
+ x_52_phi = x_51;
+ }
+ if (x_52_phi) {
+ int x_15 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_16 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_17 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_18 = x_6.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_15), float(x_16), float(x_17), float(x_18));
+ } else {
+ int x_19 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_66 = float(x_19);
+ x_GLF_color = vec4(x_66, x_66, x_66, x_66);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:29: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' const float' and a right operand of type ' const float' (or there is no acceptable conversion)
+ERROR: 0:29: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-apfloat-module-small-number/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-module-small-number/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..fccb658
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-module-small-number/0-opt.spvasm.expected.glsl
@@ -0,0 +1,107 @@
+SKIP: FAILED
+
+warning: use of deprecated intrinsic
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[1];
+};
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+} x_8;
+
+void main_1() {
+ float f0 = 0.0f;
+ float s1 = 0.0f;
+ float f1 = 0.0f;
+ bool x_72 = false;
+ bool x_73_phi = false;
+ f0 = (10.0f - (0.000001f * floor((10.0f / 0.000001f))));
+ s1 = 9.99999935e-39f;
+ if ((s1 == 0.0f)) {
+ s1 = 1.0f;
+ }
+ bool x_62 = false;
+ bool x_71 = false;
+ bool x_63_phi = false;
+ bool x_72_phi = false;
+ float x_42 = s1;
+ f1 = (10.0f - (x_42 * floor((10.0f / x_42))));
+ bool x_48 = (isinf(f1) | (s1 == 1.0f));
+ x_73_phi = x_48;
+ if (!(x_48)) {
+ bool x_54 = (f0 == f1);
+ x_63_phi = x_54;
+ if (!(x_54)) {
+ x_62 = ((f0 > 0.99000001f) & (f0 < 0.01f));
+ x_63_phi = x_62;
+ }
+ bool x_63 = x_63_phi;
+ x_72_phi = x_63;
+ if (!(x_63)) {
+ x_71 = ((f1 > 0.99000001f) & (f1 < 0.01f));
+ x_72_phi = x_71;
+ }
+ x_72 = x_72_phi;
+ x_73_phi = x_72;
+ }
+ if ((x_73_phi | (f1 == 10.0f))) {
+ int x_81 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_84 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_87 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_90 = x_8.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(float(x_81), float(x_84), float(x_87), float(x_90));
+ } else {
+ int x_94 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_95 = float(x_94);
+ x_GLF_color = vec4(x_95, x_95, x_95, x_95);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:39: '|' : wrong operand types: no operation '|' exists that takes a left-hand operand of type ' global bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:39: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-apfloat-module-small-number/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-module-small-number/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..1b8c971f
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-module-small-number/0-opt.wgsl.expected.glsl
@@ -0,0 +1,125 @@
+SKIP: FAILED
+
+vk-gl-cts/graphicsfuzz/cov-apfloat-module-small-number/0-opt.wgsl:39:22 warning: use of deprecated intrinsic
+ let x_48 : bool = (isInf(x_44) || (x_46 == 1.0));
+ ^^^^^
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[1];
+};
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+} x_8;
+
+void main_1() {
+ float f0 = 0.0f;
+ float s1 = 0.0f;
+ float f1 = 0.0f;
+ bool x_72 = false;
+ bool x_73_phi = false;
+ f0 = (10.0f % 0.000001f);
+ s1 = 9.99999935e-39f;
+ if ((s1 == 0.0f)) {
+ s1 = 1.0f;
+ }
+ bool x_62 = false;
+ bool x_71 = false;
+ bool x_63_phi = false;
+ bool x_72_phi = false;
+ f1 = (10.0f % s1);
+ bool tint_tmp = isinf(f1);
+ if (!tint_tmp) {
+ tint_tmp = (s1 == 1.0f);
+ }
+ bool x_48 = (tint_tmp);
+ x_73_phi = x_48;
+ if (!(x_48)) {
+ bool x_54 = (f0 == f1);
+ x_63_phi = x_54;
+ if (!(x_54)) {
+ bool tint_tmp_1 = (f0 > 0.99000001f);
+ if (tint_tmp_1) {
+ tint_tmp_1 = (f0 < 0.01f);
+ }
+ x_62 = (tint_tmp_1);
+ x_63_phi = x_62;
+ }
+ bool x_63 = x_63_phi;
+ x_72_phi = x_63;
+ if (!(x_63)) {
+ bool tint_tmp_2 = (f1 > 0.99000001f);
+ if (tint_tmp_2) {
+ tint_tmp_2 = (f1 < 0.01f);
+ }
+ x_71 = (tint_tmp_2);
+ x_72_phi = x_71;
+ }
+ x_72 = x_72_phi;
+ x_73_phi = x_72;
+ }
+ bool tint_tmp_3 = x_73_phi;
+ if (!tint_tmp_3) {
+ tint_tmp_3 = (f1 == 10.0f);
+ }
+ if ((tint_tmp_3)) {
+ int x_81 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_84 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_87 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_90 = x_8.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(float(x_81), float(x_84), float(x_87), float(x_90));
+ } else {
+ int x_94 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_95 = float(x_94);
+ x_GLF_color = vec4(x_95, x_95, x_95, x_95);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:28: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' const float' and a right operand of type ' const float' (or there is no acceptable conversion)
+ERROR: 0:28: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-apfloat-tanh/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-tanh/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..b66d418
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-tanh/0-opt.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec4 v = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float dist1 = 0.0f;
+ float dist2 = 0.0f;
+ v = vec4(1.0f, 2.0f, 3.0f, 4.0f);
+ dist1 = distance(tanh(v), (sinh(v) / cosh(v)));
+ dist2 = distance(tanh(v), vec4(0.761590004f, 0.964030027f, 0.995050013f, 0.999329984f));
+ if (((dist1 < 0.100000001f) & (dist2 < 0.100000001f))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:13: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:13: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-apfloat-unpackunorm-loop/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-unpackunorm-loop/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..e6b95ce
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-unpackunorm-loop/0-opt.spvasm.expected.glsl
@@ -0,0 +1,90 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_unpack4x8unorm(uint param_0) {
+ uint j = param_0;
+ uint4 i = uint4(j & 0xff, (j >> 8) & 0xff, (j >> 16) & 0xff, j >> 24);
+ return float4(i) / 255.0;
+}
+
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int i = 0;
+ vec4 v = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ int x_30 = x_6.x_GLF_uniform_int_values[1].el;
+ i = x_30;
+ while (true) {
+ int x_35 = i;
+ int x_37 = x_6.x_GLF_uniform_int_values[2].el;
+ if ((x_35 < x_37)) {
+ } else {
+ break;
+ }
+ v = tint_unpack4x8unorm(100u);
+ float x_42 = v.x;
+ if ((int(x_42) > i)) {
+ int x_49 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_50 = float(x_49);
+ x_GLF_color = vec4(x_50, x_50, x_50, x_50);
+ return;
+ }
+ {
+ i = (i + 1);
+ }
+ }
+ int x_55 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_58 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_61 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_64 = x_6.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_55), float(x_58), float(x_61), float(x_64));
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'uint4' : undeclared identifier
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-apfloat-unpackunorm-loop/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-unpackunorm-loop/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..e6b95ce
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-apfloat-unpackunorm-loop/0-opt.wgsl.expected.glsl
@@ -0,0 +1,90 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_unpack4x8unorm(uint param_0) {
+ uint j = param_0;
+ uint4 i = uint4(j & 0xff, (j >> 8) & 0xff, (j >> 16) & 0xff, j >> 24);
+ return float4(i) / 255.0;
+}
+
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int i = 0;
+ vec4 v = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ int x_30 = x_6.x_GLF_uniform_int_values[1].el;
+ i = x_30;
+ while (true) {
+ int x_35 = i;
+ int x_37 = x_6.x_GLF_uniform_int_values[2].el;
+ if ((x_35 < x_37)) {
+ } else {
+ break;
+ }
+ v = tint_unpack4x8unorm(100u);
+ float x_42 = v.x;
+ if ((int(x_42) > i)) {
+ int x_49 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_50 = float(x_49);
+ x_GLF_color = vec4(x_50, x_50, x_50, x_50);
+ return;
+ }
+ {
+ i = (i + 1);
+ }
+ }
+ int x_55 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_58 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_61 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_64 = x_6.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_55), float(x_58), float(x_61), float(x_64));
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'uint4' : undeclared identifier
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-bitcount/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-bitcount/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..0c4b966
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-bitcount/0-opt.spvasm.expected.glsl
@@ -0,0 +1,107 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+} x_8;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+} x_11;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+int f1_() {
+ int a = 0;
+ int i = 0;
+ a = 256;
+ float x_65 = tint_symbol.y;
+ float x_67 = x_8.x_GLF_uniform_float_values[0].el;
+ if ((x_65 > x_67)) {
+ a = (a + 1);
+ }
+ i = countbits(a);
+ int x_75 = i;
+ int x_77 = x_11.x_GLF_uniform_int_values[0].el;
+ if ((x_75 < x_77)) {
+ int x_82 = x_11.x_GLF_uniform_int_values[0].el;
+ return x_82;
+ }
+ return i;
+}
+
+void main_1() {
+ int a_1 = 0;
+ int x_38 = f1_();
+ a_1 = x_38;
+ int x_39 = a_1;
+ int x_41 = x_11.x_GLF_uniform_int_values[2].el;
+ if ((x_39 == x_41)) {
+ int x_47 = x_11.x_GLF_uniform_int_values[0].el;
+ int x_50 = x_11.x_GLF_uniform_int_values[1].el;
+ int x_53 = x_11.x_GLF_uniform_int_values[1].el;
+ int x_56 = x_11.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_47), float(x_50), float(x_53), float(x_56));
+ } else {
+ int x_60 = x_11.x_GLF_uniform_int_values[1].el;
+ float x_61 = float(x_60);
+ x_GLF_color = vec4(x_61, x_61, x_61, x_61);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:35: 'countbits' : no matching overloaded function found
+ERROR: 0:35: 'assign' : cannot convert from ' const float' to ' temp mediump int'
+ERROR: 0:35: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-bitcount/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-bitcount/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..0c4b966
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-bitcount/0-opt.wgsl.expected.glsl
@@ -0,0 +1,107 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+} x_8;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+} x_11;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+int f1_() {
+ int a = 0;
+ int i = 0;
+ a = 256;
+ float x_65 = tint_symbol.y;
+ float x_67 = x_8.x_GLF_uniform_float_values[0].el;
+ if ((x_65 > x_67)) {
+ a = (a + 1);
+ }
+ i = countbits(a);
+ int x_75 = i;
+ int x_77 = x_11.x_GLF_uniform_int_values[0].el;
+ if ((x_75 < x_77)) {
+ int x_82 = x_11.x_GLF_uniform_int_values[0].el;
+ return x_82;
+ }
+ return i;
+}
+
+void main_1() {
+ int a_1 = 0;
+ int x_38 = f1_();
+ a_1 = x_38;
+ int x_39 = a_1;
+ int x_41 = x_11.x_GLF_uniform_int_values[2].el;
+ if ((x_39 == x_41)) {
+ int x_47 = x_11.x_GLF_uniform_int_values[0].el;
+ int x_50 = x_11.x_GLF_uniform_int_values[1].el;
+ int x_53 = x_11.x_GLF_uniform_int_values[1].el;
+ int x_56 = x_11.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_47), float(x_50), float(x_53), float(x_56));
+ } else {
+ int x_60 = x_11.x_GLF_uniform_int_values[1].el;
+ float x_61 = float(x_60);
+ x_GLF_color = vec4(x_61, x_61, x_61, x_61);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:35: 'countbits' : no matching overloaded function found
+ERROR: 0:35: 'assign' : cannot convert from ' const float' to ' temp mediump int'
+ERROR: 0:35: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-bitfieldreverse-loop-limit-underflow/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-bitfieldreverse-loop-limit-underflow/0.spvasm.expected.glsl
new file mode 100644
index 0000000..03e7a15
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-bitfieldreverse-loop-limit-underflow/0.spvasm.expected.glsl
@@ -0,0 +1,98 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+} x_5;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int x_28 = 0;
+ int x_29 = 0;
+ int x_28_phi = 0;
+ int x_31_phi = 0;
+ int x_42_phi = 0;
+ int x_24 = min(1, reversebits(1));
+ int x_26 = x_5.x_GLF_uniform_int_values[3].el;
+ x_28_phi = x_26;
+ x_31_phi = 1;
+ while (true) {
+ int x_32 = 0;
+ x_28 = x_28_phi;
+ int x_31 = x_31_phi;
+ x_42_phi = x_28;
+ if ((x_31 <= (x_24 - 1))) {
+ } else {
+ break;
+ }
+ x_29 = (x_28 + x_31);
+ int x_38 = x_5.x_GLF_uniform_int_values[0].el;
+ if ((x_38 == 1)) {
+ x_42_phi = x_29;
+ break;
+ }
+ {
+ x_32 = (x_31 + 1);
+ x_28_phi = x_29;
+ x_31_phi = x_32;
+ }
+ }
+ int x_42 = x_42_phi;
+ int x_44 = x_5.x_GLF_uniform_int_values[2].el;
+ if ((x_42 == x_44)) {
+ int x_50 = x_5.x_GLF_uniform_int_values[0].el;
+ float x_51 = float(x_50);
+ int x_53 = x_5.x_GLF_uniform_int_values[1].el;
+ float x_54 = float(x_53);
+ x_GLF_color = vec4(x_51, x_54, x_54, x_51);
+ } else {
+ int x_57 = x_5.x_GLF_uniform_int_values[1].el;
+ float x_58 = float(x_57);
+ x_GLF_color = vec4(x_58, x_58, x_58, x_58);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:22: 'reversebits' : no matching overloaded function found
+ERROR: 0:22: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-bitfieldreverse-loop-limit-underflow/0.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-bitfieldreverse-loop-limit-underflow/0.wgsl.expected.glsl
new file mode 100644
index 0000000..03e7a15
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-bitfieldreverse-loop-limit-underflow/0.wgsl.expected.glsl
@@ -0,0 +1,98 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+} x_5;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int x_28 = 0;
+ int x_29 = 0;
+ int x_28_phi = 0;
+ int x_31_phi = 0;
+ int x_42_phi = 0;
+ int x_24 = min(1, reversebits(1));
+ int x_26 = x_5.x_GLF_uniform_int_values[3].el;
+ x_28_phi = x_26;
+ x_31_phi = 1;
+ while (true) {
+ int x_32 = 0;
+ x_28 = x_28_phi;
+ int x_31 = x_31_phi;
+ x_42_phi = x_28;
+ if ((x_31 <= (x_24 - 1))) {
+ } else {
+ break;
+ }
+ x_29 = (x_28 + x_31);
+ int x_38 = x_5.x_GLF_uniform_int_values[0].el;
+ if ((x_38 == 1)) {
+ x_42_phi = x_29;
+ break;
+ }
+ {
+ x_32 = (x_31 + 1);
+ x_28_phi = x_29;
+ x_31_phi = x_32;
+ }
+ }
+ int x_42 = x_42_phi;
+ int x_44 = x_5.x_GLF_uniform_int_values[2].el;
+ if ((x_42 == x_44)) {
+ int x_50 = x_5.x_GLF_uniform_int_values[0].el;
+ float x_51 = float(x_50);
+ int x_53 = x_5.x_GLF_uniform_int_values[1].el;
+ float x_54 = float(x_53);
+ x_GLF_color = vec4(x_51, x_54, x_54, x_51);
+ } else {
+ int x_57 = x_5.x_GLF_uniform_int_values[1].el;
+ float x_58 = float(x_57);
+ x_GLF_color = vec4(x_58, x_58, x_58, x_58);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:22: 'reversebits' : no matching overloaded function found
+ERROR: 0:22: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-color-output-undefined-in-unexecuted-branch/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-color-output-undefined-in-unexecuted-branch/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..772e0cc
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-color-output-undefined-in-unexecuted-branch/0-opt.spvasm.expected.glsl
@@ -0,0 +1,164 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_unpack4x8snorm(uint param_0) {
+ int j = int(param_0);
+ int4 i = int4(j << 24, j << 16, j << 8, j) >> 24;
+ return clamp(float4(i) / 127.0, -1.0, 1.0);
+}
+
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[3];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf2 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+struct buf3 {
+ int three;
+};
+struct tint_padded_array_element_2 {
+ uint el;
+};
+struct buf0 {
+ tint_padded_array_element_2 x_GLF_uniform_uint_values[1];
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[3];
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 2) uniform buf2_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_12;
+layout (binding = 3) uniform buf3_1 {
+ int three;
+} x_14;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_2 x_GLF_uniform_uint_values[1];
+} x_16;
+
+void func0_() {
+ vec4 tmp = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float x_112 = tint_symbol.x;
+ float x_114 = x_8.x_GLF_uniform_float_values[1].el;
+ if ((x_112 > x_114)) {
+ tmp = x_GLF_color;
+ }
+ x_GLF_color = tmp;
+ return;
+}
+
+int func1_() {
+ int a = 0;
+ int x_122 = x_12.x_GLF_uniform_int_values[1].el;
+ a = x_122;
+ while (true) {
+ int x_127 = a;
+ int x_129 = x_12.x_GLF_uniform_int_values[3].el;
+ if ((x_127 < x_129)) {
+ } else {
+ break;
+ }
+ int x_133 = x_14.three;
+ int x_135 = x_12.x_GLF_uniform_int_values[1].el;
+ if ((x_133 > x_135)) {
+ func0_();
+ int x_142 = x_12.x_GLF_uniform_int_values[3].el;
+ a = x_142;
+ } else {
+ func0_();
+ }
+ }
+ return a;
+}
+
+void main_1() {
+ int a_1 = 0;
+ int i = 0;
+ int j = 0;
+ float x_56 = tint_symbol.x;
+ float x_58 = x_8.x_GLF_uniform_float_values[1].el;
+ if ((x_56 > x_58)) {
+ float x_64 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_66 = x_8.x_GLF_uniform_float_values[1].el;
+ float x_68 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_70 = x_8.x_GLF_uniform_float_values[2].el;
+ x_GLF_color = vec4(x_64, x_66, x_68, x_70);
+ } else {
+ uint x_73 = x_16.x_GLF_uniform_uint_values[0].el;
+ x_GLF_color = tint_unpack4x8snorm(x_73);
+ }
+ int x_76 = x_12.x_GLF_uniform_int_values[2].el;
+ a_1 = x_76;
+ i = 0;
+ {
+ for(; (i < 5); i = (i + 1)) {
+ j = 0;
+ {
+ for(; (j < 2); j = (j + 1)) {
+ int x_91 = func1_();
+ a_1 = (a_1 + x_91);
+ }
+ }
+ }
+ }
+ int x_98 = a_1;
+ int x_100 = x_12.x_GLF_uniform_int_values[0].el;
+ if ((x_98 == x_100)) {
+ float x_105 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_107 = x_GLF_color.z;
+ x_GLF_color.z = (x_107 - x_105);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'int4' : undeclared identifier
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-color-output-undefined-in-unexecuted-branch/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-color-output-undefined-in-unexecuted-branch/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..772e0cc
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-color-output-undefined-in-unexecuted-branch/0-opt.wgsl.expected.glsl
@@ -0,0 +1,164 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_unpack4x8snorm(uint param_0) {
+ int j = int(param_0);
+ int4 i = int4(j << 24, j << 16, j << 8, j) >> 24;
+ return clamp(float4(i) / 127.0, -1.0, 1.0);
+}
+
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[3];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf2 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+struct buf3 {
+ int three;
+};
+struct tint_padded_array_element_2 {
+ uint el;
+};
+struct buf0 {
+ tint_padded_array_element_2 x_GLF_uniform_uint_values[1];
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[3];
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 2) uniform buf2_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_12;
+layout (binding = 3) uniform buf3_1 {
+ int three;
+} x_14;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_2 x_GLF_uniform_uint_values[1];
+} x_16;
+
+void func0_() {
+ vec4 tmp = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float x_112 = tint_symbol.x;
+ float x_114 = x_8.x_GLF_uniform_float_values[1].el;
+ if ((x_112 > x_114)) {
+ tmp = x_GLF_color;
+ }
+ x_GLF_color = tmp;
+ return;
+}
+
+int func1_() {
+ int a = 0;
+ int x_122 = x_12.x_GLF_uniform_int_values[1].el;
+ a = x_122;
+ while (true) {
+ int x_127 = a;
+ int x_129 = x_12.x_GLF_uniform_int_values[3].el;
+ if ((x_127 < x_129)) {
+ } else {
+ break;
+ }
+ int x_133 = x_14.three;
+ int x_135 = x_12.x_GLF_uniform_int_values[1].el;
+ if ((x_133 > x_135)) {
+ func0_();
+ int x_142 = x_12.x_GLF_uniform_int_values[3].el;
+ a = x_142;
+ } else {
+ func0_();
+ }
+ }
+ return a;
+}
+
+void main_1() {
+ int a_1 = 0;
+ int i = 0;
+ int j = 0;
+ float x_56 = tint_symbol.x;
+ float x_58 = x_8.x_GLF_uniform_float_values[1].el;
+ if ((x_56 > x_58)) {
+ float x_64 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_66 = x_8.x_GLF_uniform_float_values[1].el;
+ float x_68 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_70 = x_8.x_GLF_uniform_float_values[2].el;
+ x_GLF_color = vec4(x_64, x_66, x_68, x_70);
+ } else {
+ uint x_73 = x_16.x_GLF_uniform_uint_values[0].el;
+ x_GLF_color = tint_unpack4x8snorm(x_73);
+ }
+ int x_76 = x_12.x_GLF_uniform_int_values[2].el;
+ a_1 = x_76;
+ i = 0;
+ {
+ for(; (i < 5); i = (i + 1)) {
+ j = 0;
+ {
+ for(; (j < 2); j = (j + 1)) {
+ int x_91 = func1_();
+ a_1 = (a_1 + x_91);
+ }
+ }
+ }
+ }
+ int x_98 = a_1;
+ int x_100 = x_12.x_GLF_uniform_int_values[0].el;
+ if ((x_98 == x_100)) {
+ float x_105 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_107 = x_GLF_color.z;
+ x_GLF_color.z = (x_107 - x_105);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'int4' : undeclared identifier
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-const-folding-clamp-inside-while/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-const-folding-clamp-inside-while/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..6aadfa9
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-const-folding-clamp-inside-while/0-opt.spvasm.expected.glsl
@@ -0,0 +1,62 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int i = 0;
+ int j = 0;
+ i = 0;
+ j = 1;
+ while (true) {
+ if ((i < clamp(j, 5, 9))) {
+ } else {
+ break;
+ }
+ i = (i + 1);
+ j = (j + 1);
+ }
+ if (((i == 9) & (j == 10))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:19: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:19: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-const-folding-mod-one-one-lte/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-const-folding-mod-one-one-lte/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..08ead30
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-const-folding-mod-one-one-lte/0-opt.wgsl.expected.glsl
@@ -0,0 +1,65 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+};
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+} x_5;
+
+void main_1() {
+ if (((1.0f % 1.0f) <= 0.01f)) {
+ int x_29 = x_5.x_GLF_uniform_int_values[0].el;
+ int x_32 = x_5.x_GLF_uniform_int_values[0].el;
+ int x_35 = x_5.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(1.0f, float(x_29), float(x_32), float(x_35));
+ } else {
+ int x_39 = x_5.x_GLF_uniform_int_values[0].el;
+ float x_40 = float(x_39);
+ x_GLF_color = vec4(x_40, x_40, x_40, x_40);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:17: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' const float' and a right operand of type ' const float' (or there is no acceptable conversion)
+ERROR: 0:17: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-constant-folding-atan-over-tanh/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-constant-folding-atan-over-tanh/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..a6959c5
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-constant-folding-atan-over-tanh/0-opt.spvasm.expected.glsl
@@ -0,0 +1,52 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float f = 0.0f;
+ f = atan(1.0f, tanh(1.0f));
+ if (((f > 0.910000026f) & (f < 0.930000007f))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-dag-combiner-loop-bitfieldreverse/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-dag-combiner-loop-bitfieldreverse/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..44e0b9e
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-dag-combiner-loop-bitfieldreverse/0-opt.spvasm.expected.glsl
@@ -0,0 +1,84 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int a = 0;
+ int i = 0;
+ int x_27 = x_6.x_GLF_uniform_int_values[1].el;
+ a = x_27;
+ int x_29 = x_6.x_GLF_uniform_int_values[3].el;
+ i = -(x_29);
+ while (true) {
+ int x_36 = (i + 1);
+ i = x_36;
+ int x_39 = x_6.x_GLF_uniform_int_values[2].el;
+ if ((reversebits(x_36) <= x_39)) {
+ } else {
+ break;
+ }
+ a = (a + 1);
+ }
+ int x_44 = a;
+ int x_46 = x_6.x_GLF_uniform_int_values[0].el;
+ if ((x_44 == x_46)) {
+ int x_52 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_55 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_58 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_61 = x_6.x_GLF_uniform_int_values[2].el;
+ x_GLF_color = vec4(float(x_52), float(x_55), float(x_58), float(x_61));
+ } else {
+ int x_65 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_66 = float(x_65);
+ x_GLF_color = vec4(x_66, x_66, x_66, x_66);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:27: 'reversebits' : no matching overloaded function found
+ERROR: 0:27: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-dag-combiner-loop-bitfieldreverse/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-dag-combiner-loop-bitfieldreverse/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..44e0b9e
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-dag-combiner-loop-bitfieldreverse/0-opt.wgsl.expected.glsl
@@ -0,0 +1,84 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int a = 0;
+ int i = 0;
+ int x_27 = x_6.x_GLF_uniform_int_values[1].el;
+ a = x_27;
+ int x_29 = x_6.x_GLF_uniform_int_values[3].el;
+ i = -(x_29);
+ while (true) {
+ int x_36 = (i + 1);
+ i = x_36;
+ int x_39 = x_6.x_GLF_uniform_int_values[2].el;
+ if ((reversebits(x_36) <= x_39)) {
+ } else {
+ break;
+ }
+ a = (a + 1);
+ }
+ int x_44 = a;
+ int x_46 = x_6.x_GLF_uniform_int_values[0].el;
+ if ((x_44 == x_46)) {
+ int x_52 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_55 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_58 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_61 = x_6.x_GLF_uniform_int_values[2].el;
+ x_GLF_color = vec4(float(x_52), float(x_55), float(x_58), float(x_61));
+ } else {
+ int x_65 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_66 = float(x_65);
+ x_GLF_color = vec4(x_66, x_66, x_66, x_66);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:27: 'reversebits' : no matching overloaded function found
+ERROR: 0:27: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-derivative-uniform-vector-global-loop-count/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-derivative-uniform-vector-global-loop-count/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..80f91e5
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-derivative-uniform-vector-global-loop-count/0-opt.spvasm.expected.glsl
@@ -0,0 +1,114 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+};
+struct buf2 {
+ vec2 injectionSwitch;
+};
+
+int x_GLF_global_loop_count = 0;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_7;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+} x_10;
+layout (binding = 2) uniform buf2_1 {
+ vec2 injectionSwitch;
+} x_12;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float f = 0.0f;
+ int r = 0;
+ x_GLF_global_loop_count = 0;
+ float x_42 = x_7.x_GLF_uniform_float_values[0].el;
+ f = x_42;
+ int x_44 = x_10.x_GLF_uniform_int_values[1].el;
+ r = x_44;
+ while (true) {
+ int x_49 = r;
+ int x_51 = x_10.x_GLF_uniform_int_values[2].el;
+ if ((x_49 < x_51)) {
+ } else {
+ break;
+ }
+ x_GLF_global_loop_count = (x_GLF_global_loop_count + 1);
+ vec2 x_57 = x_12.injectionSwitch;
+ f = (f + ddx(x_57).y);
+ {
+ r = (r + 1);
+ }
+ }
+ while (true) {
+ if ((x_GLF_global_loop_count < 100)) {
+ } else {
+ break;
+ }
+ x_GLF_global_loop_count = (x_GLF_global_loop_count + 1);
+ float x_74 = x_7.x_GLF_uniform_float_values[0].el;
+ f = (f + x_74);
+ }
+ float x_77 = f;
+ float x_79 = x_7.x_GLF_uniform_float_values[1].el;
+ if ((x_77 == x_79)) {
+ int x_85 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_88 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_91 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_94 = x_10.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_85), float(x_88), float(x_91), float(x_94));
+ } else {
+ int x_98 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_99 = float(x_98);
+ x_GLF_color = vec4(x_99, x_99, x_99, x_99);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:49: 'ddx' : no matching overloaded function found
+ERROR: 0:49: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-derivative-uniform-vector-global-loop-count/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-derivative-uniform-vector-global-loop-count/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..80f91e5
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-derivative-uniform-vector-global-loop-count/0-opt.wgsl.expected.glsl
@@ -0,0 +1,114 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+};
+struct buf2 {
+ vec2 injectionSwitch;
+};
+
+int x_GLF_global_loop_count = 0;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_7;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+} x_10;
+layout (binding = 2) uniform buf2_1 {
+ vec2 injectionSwitch;
+} x_12;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float f = 0.0f;
+ int r = 0;
+ x_GLF_global_loop_count = 0;
+ float x_42 = x_7.x_GLF_uniform_float_values[0].el;
+ f = x_42;
+ int x_44 = x_10.x_GLF_uniform_int_values[1].el;
+ r = x_44;
+ while (true) {
+ int x_49 = r;
+ int x_51 = x_10.x_GLF_uniform_int_values[2].el;
+ if ((x_49 < x_51)) {
+ } else {
+ break;
+ }
+ x_GLF_global_loop_count = (x_GLF_global_loop_count + 1);
+ vec2 x_57 = x_12.injectionSwitch;
+ f = (f + ddx(x_57).y);
+ {
+ r = (r + 1);
+ }
+ }
+ while (true) {
+ if ((x_GLF_global_loop_count < 100)) {
+ } else {
+ break;
+ }
+ x_GLF_global_loop_count = (x_GLF_global_loop_count + 1);
+ float x_74 = x_7.x_GLF_uniform_float_values[0].el;
+ f = (f + x_74);
+ }
+ float x_77 = f;
+ float x_79 = x_7.x_GLF_uniform_float_values[1].el;
+ if ((x_77 == x_79)) {
+ int x_85 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_88 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_91 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_94 = x_10.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_85), float(x_88), float(x_91), float(x_94));
+ } else {
+ int x_98 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_99 = float(x_98);
+ x_GLF_color = vec4(x_99, x_99, x_99, x_99);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:49: 'ddx' : no matching overloaded function found
+ERROR: 0:49: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-divide-matrix-transpose-by-constant/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-divide-matrix-transpose-by-constant/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..26f07aa
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-divide-matrix-transpose-by-constant/0-opt.spvasm.expected.glsl
@@ -0,0 +1,53 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat2 m = mat2(0.0f, 0.0f, 0.0f, 0.0f);
+ m = (transpose(mat2(vec2(1.0f, 2.0f), vec2(3.0f, 4.0f))) * (1.0f / 2.0f));
+ mat2 x_33 = m;
+ if ((all(equal(x_33[0u], mat2(vec2(0.5f, 1.5f), vec2(1.0f, 2.0f))[0u])) & all(equal(x_33[1u], mat2(vec2(0.5f, 1.5f), vec2(1.0f, 2.0f))[1u])))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:10: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' global bool' and a right operand of type ' global bool' (or there is no acceptable conversion)
+ERROR: 0:10: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-fold-logical-and-const-variable/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-fold-logical-and-const-variable/0.spvasm.expected.glsl
new file mode 100644
index 0000000..7c50a57
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-fold-logical-and-const-variable/0.spvasm.expected.glsl
@@ -0,0 +1,52 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ bool a = false;
+ a = false;
+ if ((true & a)) {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ } else {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' const bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-fold-logical-and-constant/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-fold-logical-and-constant/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..db352d2
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-fold-logical-and-constant/0-opt.spvasm.expected.glsl
@@ -0,0 +1,69 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int i = 0;
+ i = 2;
+ while (true) {
+ i = (i + 1);
+ {
+ float x_35 = tint_symbol.x;
+ if (((x_35 >= 0.0f) & false)) {
+ } else {
+ break;
+ }
+ }
+ }
+ if ((i == 3)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:14: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' const bool' (or there is no acceptable conversion)
+ERROR: 0:14: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-fold-logical-or-constant/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-fold-logical-or-constant/0.spvasm.expected.glsl
new file mode 100644
index 0000000..8ffa575
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-fold-logical-or-constant/0.spvasm.expected.glsl
@@ -0,0 +1,58 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float x_22 = tint_symbol.x;
+ if (((x_22 < 0.0f) | true)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:9: '|' : wrong operand types: no operation '|' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' const bool' (or there is no acceptable conversion)
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-fold-shift-gte32/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-fold-shift-gte32/0.spvasm.expected.glsl
new file mode 100644
index 0000000..12d6dcf
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-fold-shift-gte32/0.spvasm.expected.glsl
@@ -0,0 +1,93 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ uint one;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ uint one;
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ uint b = 0u;
+ uint c = 0u;
+ uint d = 0u;
+ uint e = 0u;
+ uint f = 0u;
+ uint x_41 = x_6.one;
+ a = ((77u + x_41) >> 32u);
+ uint x_45 = x_6.one;
+ b = ((3243u + x_45) >> 33u);
+ uint x_49 = x_6.one;
+ c = ((23u + x_49) >> 345u);
+ uint x_53 = x_6.one;
+ d = ((2395u + x_53) << 32u);
+ uint x_57 = x_6.one;
+ e = ((290485u + x_57) << 33u);
+ uint x_61 = x_6.one;
+ f = ((44321u + x_61) << 345u);
+ if ((a != 1u)) {
+ a = 1u;
+ }
+ if ((b != 0u)) {
+ b = 0u;
+ }
+ if ((c != 1u)) {
+ c = 1u;
+ }
+ if ((d != 0u)) {
+ d = 0u;
+ }
+ if ((e != 1u)) {
+ e = 1u;
+ }
+ if ((f != 0u)) {
+ f = 0u;
+ }
+ if (((((((a == 1u) & (b == 0u)) & (c == 1u)) & (d == 0u)) & (e == 1u)) & (f == 0u))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:50: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:50: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-merge-div-mul/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-merge-div-mul/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..82afd88
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-merge-div-mul/0-opt.spvasm.expected.glsl
@@ -0,0 +1,60 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ float one;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ float one;
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float f = 0.0f;
+ float x_28 = x_6.one;
+ f = (4.0f / (2.0f * x_28));
+ if (((f > 1.899999976f) & (f < 2.099999905f))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:17: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:17: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-merge-divs/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-merge-divs/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..59134fc
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-merge-divs/0-opt.spvasm.expected.glsl
@@ -0,0 +1,60 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ float four;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ float four;
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float a = 0.0f;
+ float x_27 = x_6.four;
+ a = (2.0f / (1.0f / x_27));
+ if (((a > 7.900000095f) & (a < 8.100000381f))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:17: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:17: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-merge-mul-div/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-merge-mul-div/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..c273c0b
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-merge-mul-div/0-opt.spvasm.expected.glsl
@@ -0,0 +1,60 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ float one;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ float one;
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float f = 0.0f;
+ float x_28 = x_6.one;
+ f = (4.0f * (2.0f / x_28));
+ if (((f > 7.900000095f) & (f < 8.100000381f))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:17: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:17: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-extract/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-extract/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..9f8169e
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-extract/0-opt.spvasm.expected.glsl
@@ -0,0 +1,58 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_5;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec2 x_29 = x_5.injectionSwitch;
+ if (((bvec2(false, false) ? vec2(1.0f, 1.0f) : x_29).x == 0.0f)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:15: '' : boolean expression expected
+ERROR: 0:15: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-extract/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-extract/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..9f8169e
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-extract/0-opt.wgsl.expected.glsl
@@ -0,0 +1,58 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_5;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec2 x_29 = x_5.injectionSwitch;
+ if (((bvec2(false, false) ? vec2(1.0f, 1.0f) : x_29).x == 0.0f)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:15: '' : boolean expression expected
+ERROR: 0:15: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-mix/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-mix/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..00b8169
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-mix/0-opt.spvasm.expected.glsl
@@ -0,0 +1,63 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 threeandfour;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 threeandfour;
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec4 v = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ v = vec4(2.0f, 3.0f, 4.0f, 5.0f);
+ float x_40 = x_6.threeandfour.y;
+ vec2 x_42 = (bvec2(true, false) ? vec2(1.0f, x_40) : vec2(2.0f, 6.0f));
+ vec4 x_43 = v;
+ v = vec4(x_42.x, x_42.y, x_43.z, x_43.w);
+ if (all(equal(v, vec4(1.0f, 6.0f, 4.0f, 5.0f)))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:17: '' : boolean expression expected
+ERROR: 0:17: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-mix/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-mix/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..00b8169
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-folding-rules-shuffle-mix/0-opt.wgsl.expected.glsl
@@ -0,0 +1,63 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 threeandfour;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 threeandfour;
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec4 v = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ v = vec4(2.0f, 3.0f, 4.0f, 5.0f);
+ float x_40 = x_6.threeandfour.y;
+ vec2 x_42 = (bvec2(true, false) ? vec2(1.0f, x_40) : vec2(2.0f, 6.0f));
+ vec4 x_43 = v;
+ v = vec4(x_42.x, x_42.y, x_43.z, x_43.w);
+ if (all(equal(v, vec4(1.0f, 6.0f, 4.0f, 5.0f)))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:17: '' : boolean expression expected
+ERROR: 0:17: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-fract-asin-undefined-never-used/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-fract-asin-undefined-never-used/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..631f881
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-fract-asin-undefined-never-used/0-opt.spvasm.expected.glsl
@@ -0,0 +1,87 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+} x_10;
+
+void main_1() {
+ float f0 = 0.0f;
+ float f1 = 0.0f;
+ f0 = uintBitsToFloat(0x7fc00000u);
+ f1 = frac(f0);
+ float x_38 = tint_symbol.x;
+ float x_40 = x_8.x_GLF_uniform_float_values[0].el;
+ if ((x_38 > x_40)) {
+ int x_46 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_49 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_52 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_55 = x_10.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(float(x_46), float(x_49), float(x_52), float(x_55));
+ } else {
+ float x_58 = f1;
+ x_GLF_color = vec4(x_58, x_58, x_58, x_58);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:30: 'frac' : no matching overloaded function found
+ERROR: 0:30: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-fract-asin-undefined-never-used/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-fract-asin-undefined-never-used/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..ec7d617
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-fract-asin-undefined-never-used/0-opt.wgsl.expected.glsl
@@ -0,0 +1,87 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+} x_10;
+
+void main_1() {
+ float f0 = 0.0f;
+ float f1 = 0.0f;
+ f0 = uintBitsToFloat(0x7f800000u);
+ f1 = frac(f0);
+ float x_38 = tint_symbol.x;
+ float x_40 = x_8.x_GLF_uniform_float_values[0].el;
+ if ((x_38 > x_40)) {
+ int x_46 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_49 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_52 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_55 = x_10.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(float(x_46), float(x_49), float(x_52), float(x_55));
+ } else {
+ float x_58 = f1;
+ x_GLF_color = vec4(x_58, x_58, x_58, x_58);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:30: 'frac' : no matching overloaded function found
+ERROR: 0:30: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-fract-smoothstep-undefined/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-fract-smoothstep-undefined/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..5df889b
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-fract-smoothstep-undefined/0-opt.spvasm.expected.glsl
@@ -0,0 +1,88 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec2 v1 = vec2(0.0f, 0.0f);
+ vec2 b = vec2(0.0f, 0.0f);
+ float a = 0.0f;
+ bool x_51 = false;
+ bool x_52_phi = false;
+ float x_30 = x_6.x_GLF_uniform_float_values[0].el;
+ v1 = vec2(x_30, x_30);
+ b = frac(v1);
+ a = smoothstep(vec2(1.0f, 1.0f), vec2(1.0f, 1.0f), b).x;
+ float x_38 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_39 = a;
+ float x_40 = a;
+ float x_42 = x_6.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_38, x_39, x_40, x_42);
+ float x_45 = b.x;
+ bool x_46 = (x_45 < 1.0f);
+ x_52_phi = x_46;
+ if (x_46) {
+ float x_50 = b.y;
+ x_51 = (x_50 < 1.0f);
+ x_52_phi = x_51;
+ }
+ if (x_52_phi) {
+ float x_57 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_59 = b.x;
+ float x_61 = b.y;
+ float x_63 = x_6.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_57, x_59, x_61, x_63);
+ } else {
+ float x_66 = x_6.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_66, x_66, x_66, x_66);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'frac' : no matching overloaded function found
+ERROR: 0:24: 'assign' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-fract-smoothstep-undefined/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-fract-smoothstep-undefined/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..5df889b
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-fract-smoothstep-undefined/0-opt.wgsl.expected.glsl
@@ -0,0 +1,88 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec2 v1 = vec2(0.0f, 0.0f);
+ vec2 b = vec2(0.0f, 0.0f);
+ float a = 0.0f;
+ bool x_51 = false;
+ bool x_52_phi = false;
+ float x_30 = x_6.x_GLF_uniform_float_values[0].el;
+ v1 = vec2(x_30, x_30);
+ b = frac(v1);
+ a = smoothstep(vec2(1.0f, 1.0f), vec2(1.0f, 1.0f), b).x;
+ float x_38 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_39 = a;
+ float x_40 = a;
+ float x_42 = x_6.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_38, x_39, x_40, x_42);
+ float x_45 = b.x;
+ bool x_46 = (x_45 < 1.0f);
+ x_52_phi = x_46;
+ if (x_46) {
+ float x_50 = b.y;
+ x_51 = (x_50 < 1.0f);
+ x_52_phi = x_51;
+ }
+ if (x_52_phi) {
+ float x_57 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_59 = b.x;
+ float x_61 = b.y;
+ float x_63 = x_6.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_57, x_59, x_61, x_63);
+ } else {
+ float x_66 = x_6.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_66, x_66, x_66, x_66);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:24: 'frac' : no matching overloaded function found
+ERROR: 0:24: 'assign' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:24: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-global-loop-counter-main-function-call/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-global-loop-counter-main-function-call/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..0c368eb
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-global-loop-counter-main-function-call/0-opt.spvasm.expected.glsl
@@ -0,0 +1,99 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+};
+
+int x_GLF_global_loop_count = 0;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+} x_7;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+int func_() {
+ while (true) {
+ if ((x_GLF_global_loop_count < 100)) {
+ } else {
+ break;
+ }
+ x_GLF_global_loop_count = (x_GLF_global_loop_count + 1);
+ int x_78 = x_7.x_GLF_uniform_int_values[0].el;
+ return x_78;
+ }
+ int x_80 = x_7.x_GLF_uniform_int_values[2].el;
+ return x_80;
+}
+
+void main_1() {
+ int a = 0;
+ x_GLF_global_loop_count = 0;
+ while (true) {
+ x_GLF_global_loop_count = (x_GLF_global_loop_count + 1);
+ if (false) {
+ return;
+ }
+ {
+ if ((true & (x_GLF_global_loop_count < 100))) {
+ } else {
+ break;
+ }
+ }
+ }
+ int x_42 = func_();
+ a = x_42;
+ int x_43 = a;
+ int x_45 = x_7.x_GLF_uniform_int_values[2].el;
+ if ((x_43 == x_45)) {
+ int x_51 = x_7.x_GLF_uniform_int_values[0].el;
+ int x_54 = x_7.x_GLF_uniform_int_values[1].el;
+ int x_57 = x_7.x_GLF_uniform_int_values[1].el;
+ int x_60 = x_7.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_51), float(x_54), float(x_57), float(x_60));
+ } else {
+ int x_64 = x_7.x_GLF_uniform_int_values[1].el;
+ float x_65 = float(x_64);
+ x_GLF_color = vec4(x_65, x_65, x_65, x_65);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:40: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' const bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:40: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-increment-multiple-integers/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-increment-multiple-integers/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..4fd5731
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-increment-multiple-integers/0-opt.spvasm.expected.glsl
@@ -0,0 +1,121 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[5];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[5];
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int a = 0;
+ int b = 0;
+ int c = 0;
+ bool x_76 = false;
+ bool x_83 = false;
+ bool x_77_phi = false;
+ bool x_84_phi = false;
+ int x_31 = x_6.x_GLF_uniform_int_values[0].el;
+ a = x_31;
+ int x_33 = x_6.x_GLF_uniform_int_values[2].el;
+ b = x_33;
+ c = 1;
+ while (true) {
+ int x_38 = b;
+ int x_40 = x_6.x_GLF_uniform_int_values[4].el;
+ if (((x_38 < x_40) & (a < 10))) {
+ } else {
+ break;
+ }
+ if ((c > 5)) {
+ break;
+ }
+ a = (a + 1);
+ c = (c + 1);
+ b = (b + 1);
+ }
+ while (true) {
+ int x_60 = a;
+ int x_62 = x_6.x_GLF_uniform_int_values[1].el;
+ if ((x_60 < x_62)) {
+ } else {
+ break;
+ }
+ {
+ a = (a + 1);
+ }
+ }
+ int x_67 = a;
+ int x_69 = x_6.x_GLF_uniform_int_values[1].el;
+ bool x_70 = (x_67 == x_69);
+ x_77_phi = x_70;
+ if (x_70) {
+ int x_73 = b;
+ int x_75 = x_6.x_GLF_uniform_int_values[3].el;
+ x_76 = (x_73 == x_75);
+ x_77_phi = x_76;
+ }
+ bool x_77 = x_77_phi;
+ x_84_phi = x_77;
+ if (x_77) {
+ int x_80 = c;
+ int x_82 = x_6.x_GLF_uniform_int_values[3].el;
+ x_83 = (x_80 == x_82);
+ x_84_phi = x_83;
+ }
+ if (x_84_phi) {
+ int x_89 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_92 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_95 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_98 = x_6.x_GLF_uniform_int_values[2].el;
+ x_GLF_color = vec4(float(x_89), float(x_92), float(x_95), float(x_98));
+ } else {
+ int x_102 = x_6.x_GLF_uniform_int_values[0].el;
+ float x_103 = float(x_102);
+ x_GLF_color = vec4(x_103, x_103, x_103, x_103);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-and-or-xor-pack-unpack/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-and-or-xor-pack-unpack/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..bd6f6a5
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-and-or-xor-pack-unpack/0-opt.spvasm.expected.glsl
@@ -0,0 +1,142 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack4x8unorm(vec4 param_0) {
+ uint4 i = uint4(round(clamp(param_0, 0.0, 1.0) * 255.0));
+ return (i.x | i.y << 8 | i.z << 16 | i.w << 24);
+}
+
+vec4 tint_unpack4x8snorm(uint param_0) {
+ int j = int(param_0);
+ int4 i = int4(j << 24, j << 16, j << 8, j) >> 24;
+ return clamp(float4(i) / 127.0, -1.0, 1.0);
+}
+
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_6;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ vec4 v1 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ vec4 ref = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ bool x_85 = false;
+ bool x_97 = false;
+ bool x_109 = false;
+ bool x_86_phi = false;
+ bool x_98_phi = false;
+ bool x_110_phi = false;
+ float x_36 = x_6.x_GLF_uniform_float_values[0].el;
+ a = tint_pack4x8unorm(vec4(x_36, x_36, x_36, x_36));
+ v1 = tint_unpack4x8snorm(a);
+ float x_42 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_45 = x_6.x_GLF_uniform_float_values[1].el;
+ float x_48 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_51 = x_6.x_GLF_uniform_float_values[1].el;
+ float x_54 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_57 = x_6.x_GLF_uniform_float_values[1].el;
+ float x_60 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_63 = x_6.x_GLF_uniform_float_values[1].el;
+ ref = vec4((-(x_42) / x_45), (-(x_48) / x_51), (-(x_54) / x_57), (-(x_60) / x_63));
+ int x_67 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_69 = v1[x_67];
+ int x_71 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_73 = ref[x_71];
+ bool x_74 = (x_69 == x_73);
+ x_86_phi = x_74;
+ if (x_74) {
+ int x_78 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_80 = v1[x_78];
+ int x_82 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_84 = ref[x_82];
+ x_85 = (x_80 == x_84);
+ x_86_phi = x_85;
+ }
+ bool x_86 = x_86_phi;
+ x_98_phi = x_86;
+ if (x_86) {
+ int x_90 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_92 = v1[x_90];
+ int x_94 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_96 = ref[x_94];
+ x_97 = (x_92 == x_96);
+ x_98_phi = x_97;
+ }
+ bool x_98 = x_98_phi;
+ x_110_phi = x_98;
+ if (x_98) {
+ int x_102 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_104 = v1[x_102];
+ int x_106 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_108 = ref[x_106];
+ x_109 = (x_104 == x_108);
+ x_110_phi = x_109;
+ }
+ if (x_110_phi) {
+ int x_115 = x_10.x_GLF_uniform_int_values[3].el;
+ int x_118 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_121 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_124 = x_10.x_GLF_uniform_int_values[3].el;
+ x_GLF_color = vec4(float(x_115), float(x_118), float(x_121), float(x_124));
+ } else {
+ int x_128 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_130 = v1[x_128];
+ x_GLF_color = vec4(x_130, x_130, x_130, x_130);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint4' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-and-or-xor-pack-unpack/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-and-or-xor-pack-unpack/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..bd6f6a5
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-and-or-xor-pack-unpack/0-opt.wgsl.expected.glsl
@@ -0,0 +1,142 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack4x8unorm(vec4 param_0) {
+ uint4 i = uint4(round(clamp(param_0, 0.0, 1.0) * 255.0));
+ return (i.x | i.y << 8 | i.z << 16 | i.w << 24);
+}
+
+vec4 tint_unpack4x8snorm(uint param_0) {
+ int j = int(param_0);
+ int4 i = int4(j << 24, j << 16, j << 8, j) >> 24;
+ return clamp(float4(i) / 127.0, -1.0, 1.0);
+}
+
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_6;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ vec4 v1 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ vec4 ref = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ bool x_85 = false;
+ bool x_97 = false;
+ bool x_109 = false;
+ bool x_86_phi = false;
+ bool x_98_phi = false;
+ bool x_110_phi = false;
+ float x_36 = x_6.x_GLF_uniform_float_values[0].el;
+ a = tint_pack4x8unorm(vec4(x_36, x_36, x_36, x_36));
+ v1 = tint_unpack4x8snorm(a);
+ float x_42 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_45 = x_6.x_GLF_uniform_float_values[1].el;
+ float x_48 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_51 = x_6.x_GLF_uniform_float_values[1].el;
+ float x_54 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_57 = x_6.x_GLF_uniform_float_values[1].el;
+ float x_60 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_63 = x_6.x_GLF_uniform_float_values[1].el;
+ ref = vec4((-(x_42) / x_45), (-(x_48) / x_51), (-(x_54) / x_57), (-(x_60) / x_63));
+ int x_67 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_69 = v1[x_67];
+ int x_71 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_73 = ref[x_71];
+ bool x_74 = (x_69 == x_73);
+ x_86_phi = x_74;
+ if (x_74) {
+ int x_78 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_80 = v1[x_78];
+ int x_82 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_84 = ref[x_82];
+ x_85 = (x_80 == x_84);
+ x_86_phi = x_85;
+ }
+ bool x_86 = x_86_phi;
+ x_98_phi = x_86;
+ if (x_86) {
+ int x_90 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_92 = v1[x_90];
+ int x_94 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_96 = ref[x_94];
+ x_97 = (x_92 == x_96);
+ x_98_phi = x_97;
+ }
+ bool x_98 = x_98_phi;
+ x_110_phi = x_98;
+ if (x_98) {
+ int x_102 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_104 = v1[x_102];
+ int x_106 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_108 = ref[x_106];
+ x_109 = (x_104 == x_108);
+ x_110_phi = x_109;
+ }
+ if (x_110_phi) {
+ int x_115 = x_10.x_GLF_uniform_int_values[3].el;
+ int x_118 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_121 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_124 = x_10.x_GLF_uniform_int_values[3].el;
+ x_GLF_color = vec4(float(x_115), float(x_118), float(x_121), float(x_124));
+ } else {
+ int x_128 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_130 = v1[x_128];
+ x_GLF_color = vec4(x_130, x_130, x_130, x_130);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint4' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-mul-div-rem-if-undefined-divide-mix/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-mul-div-rem-if-undefined-divide-mix/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..b438ac4
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-mul-div-rem-if-undefined-divide-mix/0-opt.spvasm.expected.glsl
@@ -0,0 +1,111 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+};
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+} x_8;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+} x_10;
+
+float f1_f1_(inout float a) {
+ float x_100 = a;
+ return ddx(x_100);
+}
+
+void main_1() {
+ vec4 v2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float a_1 = 0.0f;
+ float x_40 = 0.0f;
+ float param = 0.0f;
+ int x_42 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_45 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_48 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_51 = x_8.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_42), float(x_45), float(x_48), float(x_51));
+ float x_55 = tint_symbol.x;
+ float x_57 = x_10.x_GLF_uniform_float_values[1].el;
+ if ((x_55 < x_57)) {
+ float x_62 = v2.x;
+ if (!((x_62 < 1.0f))) {
+ float x_68 = x_10.x_GLF_uniform_float_values[1].el;
+ float x_70 = x_10.x_GLF_uniform_float_values[1].el;
+ float x_72 = x_10.x_GLF_uniform_float_values[0].el;
+ if ((x_70 > x_72)) {
+ float x_78 = x_10.x_GLF_uniform_float_values[0].el;
+ param = x_78;
+ float x_79 = f1_f1_(param);
+ x_40 = x_79;
+ } else {
+ float x_81 = x_10.x_GLF_uniform_float_values[0].el;
+ x_40 = x_81;
+ }
+ a_1 = (x_68 / x_40);
+ float x_85 = x_10.x_GLF_uniform_float_values[0].el;
+ float x_88 = x_10.x_GLF_uniform_float_values[0].el;
+ float x_90 = a_1;
+ vec3 x_92 = mix(vec3(x_85, x_85, x_85), vec3(x_88, x_88, x_88), vec3(x_90, x_90, x_90));
+ float x_94 = x_10.x_GLF_uniform_float_values[1].el;
+ x_GLF_color = vec4(x_92.x, x_92.y, x_92.z, x_94);
+ }
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:28: 'ddx' : no matching overloaded function found
+ERROR: 0:28: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-mul-div-rem-if-undefined-divide-mix/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-mul-div-rem-if-undefined-divide-mix/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..b438ac4
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-mul-div-rem-if-undefined-divide-mix/0-opt.wgsl.expected.glsl
@@ -0,0 +1,111 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+};
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+} x_8;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+} x_10;
+
+float f1_f1_(inout float a) {
+ float x_100 = a;
+ return ddx(x_100);
+}
+
+void main_1() {
+ vec4 v2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float a_1 = 0.0f;
+ float x_40 = 0.0f;
+ float param = 0.0f;
+ int x_42 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_45 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_48 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_51 = x_8.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_42), float(x_45), float(x_48), float(x_51));
+ float x_55 = tint_symbol.x;
+ float x_57 = x_10.x_GLF_uniform_float_values[1].el;
+ if ((x_55 < x_57)) {
+ float x_62 = v2.x;
+ if (!((x_62 < 1.0f))) {
+ float x_68 = x_10.x_GLF_uniform_float_values[1].el;
+ float x_70 = x_10.x_GLF_uniform_float_values[1].el;
+ float x_72 = x_10.x_GLF_uniform_float_values[0].el;
+ if ((x_70 > x_72)) {
+ float x_78 = x_10.x_GLF_uniform_float_values[0].el;
+ param = x_78;
+ float x_79 = f1_f1_(param);
+ x_40 = x_79;
+ } else {
+ float x_81 = x_10.x_GLF_uniform_float_values[0].el;
+ x_40 = x_81;
+ }
+ a_1 = (x_68 / x_40);
+ float x_85 = x_10.x_GLF_uniform_float_values[0].el;
+ float x_88 = x_10.x_GLF_uniform_float_values[0].el;
+ float x_90 = a_1;
+ vec3 x_92 = mix(vec3(x_85, x_85, x_85), vec3(x_88, x_88, x_88), vec3(x_90, x_90, x_90));
+ float x_94 = x_10.x_GLF_uniform_float_values[1].el;
+ x_GLF_color = vec4(x_92.x, x_92.y, x_92.z, x_94);
+ }
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:28: 'ddx' : no matching overloaded function found
+ERROR: 0:28: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-pack-unpack/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-pack-unpack/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..61f4a60
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-pack-unpack/0-opt.spvasm.expected.glsl
@@ -0,0 +1,134 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack2x16unorm(vec2 param_0) {
+ uint2 i = uint2(round(clamp(param_0, 0.0, 1.0) * 65535.0));
+ return (i.x | i.y << 16);
+}
+
+vec4 tint_unpack4x8snorm(uint param_0) {
+ int j = int(param_0);
+ int4 i = int4(j << 24, j << 16, j << 8, j) >> 24;
+ return clamp(float4(i) / 127.0, -1.0, 1.0);
+}
+
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[7];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[7];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ vec4 v1 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float E = 0.0f;
+ bool x_75 = false;
+ bool x_92 = false;
+ bool x_109 = false;
+ bool x_76_phi = false;
+ bool x_93_phi = false;
+ bool x_110_phi = false;
+ float x_41 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_43 = x_6.x_GLF_uniform_float_values[1].el;
+ a = tint_pack2x16unorm(vec2(x_41, x_43));
+ v1 = tint_unpack4x8snorm(a);
+ E = 0.01f;
+ int x_49 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_51 = v1[x_49];
+ float x_53 = x_6.x_GLF_uniform_float_values[2].el;
+ float x_55 = x_6.x_GLF_uniform_float_values[3].el;
+ bool x_60 = (abs((x_51 - (x_53 / x_55))) < E);
+ x_76_phi = x_60;
+ if (x_60) {
+ int x_64 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_66 = v1[x_64];
+ float x_68 = x_6.x_GLF_uniform_float_values[4].el;
+ float x_70 = x_6.x_GLF_uniform_float_values[3].el;
+ x_75 = (abs((x_66 - (x_68 / x_70))) < E);
+ x_76_phi = x_75;
+ }
+ bool x_76 = x_76_phi;
+ x_93_phi = x_76;
+ if (x_76) {
+ int x_80 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_82 = v1[x_80];
+ float x_84 = x_6.x_GLF_uniform_float_values[5].el;
+ float x_87 = x_6.x_GLF_uniform_float_values[3].el;
+ x_92 = (abs((x_82 - (-(x_84) / x_87))) < E);
+ x_93_phi = x_92;
+ }
+ bool x_93 = x_93_phi;
+ x_110_phi = x_93;
+ if (x_93) {
+ int x_97 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_99 = v1[x_97];
+ float x_101 = x_6.x_GLF_uniform_float_values[6].el;
+ float x_104 = x_6.x_GLF_uniform_float_values[3].el;
+ x_109 = (abs((x_99 - (-(x_101) / x_104))) < E);
+ x_110_phi = x_109;
+ }
+ if (x_110_phi) {
+ int x_115 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_118 = x_10.x_GLF_uniform_int_values[2].el;
+ int x_121 = x_10.x_GLF_uniform_int_values[2].el;
+ int x_124 = x_10.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(float(x_115), float(x_118), float(x_121), float(x_124));
+ } else {
+ float x_128 = x_6.x_GLF_uniform_float_values[5].el;
+ x_GLF_color = vec4(x_128, x_128, x_128, x_128);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint2' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-pack-unpack/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-pack-unpack/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..61f4a60
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-pack-unpack/0-opt.wgsl.expected.glsl
@@ -0,0 +1,134 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack2x16unorm(vec2 param_0) {
+ uint2 i = uint2(round(clamp(param_0, 0.0, 1.0) * 65535.0));
+ return (i.x | i.y << 16);
+}
+
+vec4 tint_unpack4x8snorm(uint param_0) {
+ int j = int(param_0);
+ int4 i = int4(j << 24, j << 16, j << 8, j) >> 24;
+ return clamp(float4(i) / 127.0, -1.0, 1.0);
+}
+
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[7];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[7];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ vec4 v1 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float E = 0.0f;
+ bool x_75 = false;
+ bool x_92 = false;
+ bool x_109 = false;
+ bool x_76_phi = false;
+ bool x_93_phi = false;
+ bool x_110_phi = false;
+ float x_41 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_43 = x_6.x_GLF_uniform_float_values[1].el;
+ a = tint_pack2x16unorm(vec2(x_41, x_43));
+ v1 = tint_unpack4x8snorm(a);
+ E = 0.01f;
+ int x_49 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_51 = v1[x_49];
+ float x_53 = x_6.x_GLF_uniform_float_values[2].el;
+ float x_55 = x_6.x_GLF_uniform_float_values[3].el;
+ bool x_60 = (abs((x_51 - (x_53 / x_55))) < E);
+ x_76_phi = x_60;
+ if (x_60) {
+ int x_64 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_66 = v1[x_64];
+ float x_68 = x_6.x_GLF_uniform_float_values[4].el;
+ float x_70 = x_6.x_GLF_uniform_float_values[3].el;
+ x_75 = (abs((x_66 - (x_68 / x_70))) < E);
+ x_76_phi = x_75;
+ }
+ bool x_76 = x_76_phi;
+ x_93_phi = x_76;
+ if (x_76) {
+ int x_80 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_82 = v1[x_80];
+ float x_84 = x_6.x_GLF_uniform_float_values[5].el;
+ float x_87 = x_6.x_GLF_uniform_float_values[3].el;
+ x_92 = (abs((x_82 - (-(x_84) / x_87))) < E);
+ x_93_phi = x_92;
+ }
+ bool x_93 = x_93_phi;
+ x_110_phi = x_93;
+ if (x_93) {
+ int x_97 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_99 = v1[x_97];
+ float x_101 = x_6.x_GLF_uniform_float_values[6].el;
+ float x_104 = x_6.x_GLF_uniform_float_values[3].el;
+ x_109 = (abs((x_99 - (-(x_101) / x_104))) < E);
+ x_110_phi = x_109;
+ }
+ if (x_110_phi) {
+ int x_115 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_118 = x_10.x_GLF_uniform_int_values[2].el;
+ int x_121 = x_10.x_GLF_uniform_int_values[2].el;
+ int x_124 = x_10.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(float(x_115), float(x_118), float(x_121), float(x_124));
+ } else {
+ float x_128 = x_6.x_GLF_uniform_float_values[5].el;
+ x_GLF_color = vec4(x_128, x_128, x_128, x_128);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint2' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-shifts-mix-mix-clamp/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-shifts-mix-mix-clamp/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..9287556
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-shifts-mix-mix-clamp/0-opt.spvasm.expected.glsl
@@ -0,0 +1,122 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int A[2] = int[2](0, 0);
+ int i = 0;
+ int a = 0;
+ vec2 v1 = vec2(0.0f, 0.0f);
+ vec2 v2 = vec2(0.0f, 0.0f);
+ int b = 0;
+ int x_46 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_48 = x_6.x_GLF_uniform_int_values[0].el;
+ A[x_46] = x_48;
+ int x_51 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_53 = x_6.x_GLF_uniform_int_values[1].el;
+ A[x_51] = x_53;
+ int x_56 = x_6.x_GLF_uniform_int_values[0].el;
+ i = x_56;
+ while (true) {
+ int x_61 = i;
+ int x_63 = x_6.x_GLF_uniform_int_values[2].el;
+ if ((x_61 > x_63)) {
+ } else {
+ break;
+ }
+ i = (i - 1);
+ }
+ float x_69 = x_10.x_GLF_uniform_float_values[1].el;
+ float x_71 = x_10.x_GLF_uniform_float_values[1].el;
+ int x_76 = A[((x_69 >= x_71) ? 1 : i)];
+ a = x_76;
+ int x_78 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_80 = a;
+ int x_84 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_87 = x_6.x_GLF_uniform_int_values[0].el;
+ float x_91 = x_10.x_GLF_uniform_float_values[1].el;
+ float x_93 = x_10.x_GLF_uniform_float_values[0].el;
+ v1 = (bvec2((x_91 < x_93), true) ? vec2(float(x_84), float(x_87)) : vec2(float(x_78), float(x_80)));
+ int x_98 = x_6.x_GLF_uniform_int_values[2].el;
+ float x_100 = v1[x_98];
+ int x_103 = x_6.x_GLF_uniform_int_values[0].el;
+ float x_105 = v1[x_103];
+ v2 = (bvec2(false, false) ? vec2(x_105, x_105) : vec2(x_100, x_100));
+ int x_109 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_110 = float(x_109);
+ int x_113 = x_6.x_GLF_uniform_int_values[0].el;
+ float x_114 = float(x_113);
+ int x_121 = A[int(clamp(vec2(x_110, x_110), vec2(x_114, x_114), v2).x)];
+ b = x_121;
+ int x_122 = b;
+ int x_124 = x_6.x_GLF_uniform_int_values[1].el;
+ if ((x_122 == x_124)) {
+ int x_130 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_133 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_136 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_139 = x_6.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_130), float(x_133), float(x_136), float(x_139));
+ } else {
+ int x_143 = x_6.x_GLF_uniform_int_values[2].el;
+ float x_144 = float(x_143);
+ x_GLF_color = vec4(x_144, x_144, x_144, x_144);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:59: '' : boolean expression expected
+ERROR: 0:59: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-shifts-mix-mix-clamp/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-shifts-mix-mix-clamp/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..9287556
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-shifts-mix-mix-clamp/0-opt.wgsl.expected.glsl
@@ -0,0 +1,122 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[3];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int A[2] = int[2](0, 0);
+ int i = 0;
+ int a = 0;
+ vec2 v1 = vec2(0.0f, 0.0f);
+ vec2 v2 = vec2(0.0f, 0.0f);
+ int b = 0;
+ int x_46 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_48 = x_6.x_GLF_uniform_int_values[0].el;
+ A[x_46] = x_48;
+ int x_51 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_53 = x_6.x_GLF_uniform_int_values[1].el;
+ A[x_51] = x_53;
+ int x_56 = x_6.x_GLF_uniform_int_values[0].el;
+ i = x_56;
+ while (true) {
+ int x_61 = i;
+ int x_63 = x_6.x_GLF_uniform_int_values[2].el;
+ if ((x_61 > x_63)) {
+ } else {
+ break;
+ }
+ i = (i - 1);
+ }
+ float x_69 = x_10.x_GLF_uniform_float_values[1].el;
+ float x_71 = x_10.x_GLF_uniform_float_values[1].el;
+ int x_76 = A[((x_69 >= x_71) ? 1 : i)];
+ a = x_76;
+ int x_78 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_80 = a;
+ int x_84 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_87 = x_6.x_GLF_uniform_int_values[0].el;
+ float x_91 = x_10.x_GLF_uniform_float_values[1].el;
+ float x_93 = x_10.x_GLF_uniform_float_values[0].el;
+ v1 = (bvec2((x_91 < x_93), true) ? vec2(float(x_84), float(x_87)) : vec2(float(x_78), float(x_80)));
+ int x_98 = x_6.x_GLF_uniform_int_values[2].el;
+ float x_100 = v1[x_98];
+ int x_103 = x_6.x_GLF_uniform_int_values[0].el;
+ float x_105 = v1[x_103];
+ v2 = (bvec2(false, false) ? vec2(x_105, x_105) : vec2(x_100, x_100));
+ int x_109 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_110 = float(x_109);
+ int x_113 = x_6.x_GLF_uniform_int_values[0].el;
+ float x_114 = float(x_113);
+ int x_121 = A[int(clamp(vec2(x_110, x_110), vec2(x_114, x_114), v2).x)];
+ b = x_121;
+ int x_122 = b;
+ int x_124 = x_6.x_GLF_uniform_int_values[1].el;
+ if ((x_122 == x_124)) {
+ int x_130 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_133 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_136 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_139 = x_6.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_130), float(x_133), float(x_136), float(x_139));
+ } else {
+ int x_143 = x_6.x_GLF_uniform_int_values[2].el;
+ float x_144 = float(x_143);
+ x_GLF_color = vec4(x_144, x_144, x_144, x_144);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:59: '' : boolean expression expected
+ERROR: 0:59: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-pack-unpack/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-pack-unpack/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..add7f7f
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-pack-unpack/0-opt.spvasm.expected.glsl
@@ -0,0 +1,133 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack2x16float(vec2 param_0) {
+ uint2 i = f32tof16(param_0);
+ return i.x | (i.y << 16);
+}
+
+vec4 tint_unpack4x8snorm(uint param_0) {
+ int j = int(param_0);
+ int4 i = int4(j << 24, j << 16, j << 8, j) >> 24;
+ return clamp(float4(i) / 127.0, -1.0, 1.0);
+}
+
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[3];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+} x_8;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[3];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ vec4 v1 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float E = 0.0f;
+ bool x_69 = false;
+ bool x_85 = false;
+ bool x_101 = false;
+ bool x_70_phi = false;
+ bool x_86_phi = false;
+ bool x_102_phi = false;
+ a = tint_pack2x16float(vec2(1.0f, 1.0f));
+ v1 = tint_unpack4x8snorm(a);
+ E = 0.01f;
+ int x_43 = x_8.x_GLF_uniform_int_values[1].el;
+ float x_45 = v1[x_43];
+ float x_47 = x_10.x_GLF_uniform_float_values[0].el;
+ float x_49 = x_10.x_GLF_uniform_float_values[1].el;
+ bool x_54 = (abs((x_45 - (x_47 / x_49))) < E);
+ x_70_phi = x_54;
+ if (x_54) {
+ int x_58 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_60 = v1[x_58];
+ float x_62 = x_10.x_GLF_uniform_float_values[2].el;
+ float x_64 = x_10.x_GLF_uniform_float_values[1].el;
+ x_69 = (abs((x_60 - (x_62 / x_64))) < E);
+ x_70_phi = x_69;
+ }
+ bool x_70 = x_70_phi;
+ x_86_phi = x_70;
+ if (x_70) {
+ int x_74 = x_8.x_GLF_uniform_int_values[2].el;
+ float x_76 = v1[x_74];
+ float x_78 = x_10.x_GLF_uniform_float_values[0].el;
+ float x_80 = x_10.x_GLF_uniform_float_values[1].el;
+ x_85 = (abs((x_76 - (x_78 / x_80))) < E);
+ x_86_phi = x_85;
+ }
+ bool x_86 = x_86_phi;
+ x_102_phi = x_86;
+ if (x_86) {
+ int x_90 = x_8.x_GLF_uniform_int_values[3].el;
+ float x_92 = v1[x_90];
+ float x_94 = x_10.x_GLF_uniform_float_values[2].el;
+ float x_96 = x_10.x_GLF_uniform_float_values[1].el;
+ x_101 = (abs((x_92 - (x_94 / x_96))) < E);
+ x_102_phi = x_101;
+ }
+ if (x_102_phi) {
+ int x_107 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_110 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_113 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_116 = x_8.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_107), float(x_110), float(x_113), float(x_116));
+ } else {
+ int x_120 = x_8.x_GLF_uniform_int_values[1].el;
+ float x_122 = v1[x_120];
+ x_GLF_color = vec4(x_122, x_122, x_122, x_122);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint2' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-pack-unpack/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-pack-unpack/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..add7f7f
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-pack-unpack/0-opt.wgsl.expected.glsl
@@ -0,0 +1,133 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack2x16float(vec2 param_0) {
+ uint2 i = f32tof16(param_0);
+ return i.x | (i.y << 16);
+}
+
+vec4 tint_unpack4x8snorm(uint param_0) {
+ int j = int(param_0);
+ int4 i = int4(j << 24, j << 16, j << 8, j) >> 24;
+ return clamp(float4(i) / 127.0, -1.0, 1.0);
+}
+
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[3];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+} x_8;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[3];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ vec4 v1 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float E = 0.0f;
+ bool x_69 = false;
+ bool x_85 = false;
+ bool x_101 = false;
+ bool x_70_phi = false;
+ bool x_86_phi = false;
+ bool x_102_phi = false;
+ a = tint_pack2x16float(vec2(1.0f, 1.0f));
+ v1 = tint_unpack4x8snorm(a);
+ E = 0.01f;
+ int x_43 = x_8.x_GLF_uniform_int_values[1].el;
+ float x_45 = v1[x_43];
+ float x_47 = x_10.x_GLF_uniform_float_values[0].el;
+ float x_49 = x_10.x_GLF_uniform_float_values[1].el;
+ bool x_54 = (abs((x_45 - (x_47 / x_49))) < E);
+ x_70_phi = x_54;
+ if (x_54) {
+ int x_58 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_60 = v1[x_58];
+ float x_62 = x_10.x_GLF_uniform_float_values[2].el;
+ float x_64 = x_10.x_GLF_uniform_float_values[1].el;
+ x_69 = (abs((x_60 - (x_62 / x_64))) < E);
+ x_70_phi = x_69;
+ }
+ bool x_70 = x_70_phi;
+ x_86_phi = x_70;
+ if (x_70) {
+ int x_74 = x_8.x_GLF_uniform_int_values[2].el;
+ float x_76 = v1[x_74];
+ float x_78 = x_10.x_GLF_uniform_float_values[0].el;
+ float x_80 = x_10.x_GLF_uniform_float_values[1].el;
+ x_85 = (abs((x_76 - (x_78 / x_80))) < E);
+ x_86_phi = x_85;
+ }
+ bool x_86 = x_86_phi;
+ x_102_phi = x_86;
+ if (x_86) {
+ int x_90 = x_8.x_GLF_uniform_int_values[3].el;
+ float x_92 = v1[x_90];
+ float x_94 = x_10.x_GLF_uniform_float_values[2].el;
+ float x_96 = x_10.x_GLF_uniform_float_values[1].el;
+ x_101 = (abs((x_92 - (x_94 / x_96))) < E);
+ x_102_phi = x_101;
+ }
+ if (x_102_phi) {
+ int x_107 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_110 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_113 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_116 = x_8.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_107), float(x_110), float(x_113), float(x_116));
+ } else {
+ int x_120 = x_8.x_GLF_uniform_int_values[1].el;
+ float x_122 = v1[x_120];
+ x_GLF_color = vec4(x_122, x_122, x_122, x_122);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint2' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-packsnorm-unpackunorm/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-packsnorm-unpackunorm/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..146f9a2
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-packsnorm-unpackunorm/0-opt.spvasm.expected.glsl
@@ -0,0 +1,135 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack4x8snorm(vec4 param_0) {
+ int4 i = int4(round(clamp(param_0, -1.0, 1.0) * 127.0)) & 0xff;
+ return asuint(i.x | i.y << 8 | i.z << 16 | i.w << 24);
+}
+
+vec4 tint_unpack4x8unorm(uint param_0) {
+ uint j = param_0;
+ uint4 i = uint4(j & 0xff, (j >> 8) & 0xff, (j >> 16) & 0xff, j >> 24);
+ return float4(i) / 255.0;
+}
+
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[4];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[4];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ vec4 v1 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float E = 0.0f;
+ bool x_69 = false;
+ bool x_85 = false;
+ bool x_101 = false;
+ bool x_70_phi = false;
+ bool x_86_phi = false;
+ bool x_102_phi = false;
+ float x_35 = x_6.x_GLF_uniform_float_values[1].el;
+ a = tint_pack4x8snorm(vec4(x_35, x_35, x_35, x_35));
+ v1 = tint_unpack4x8unorm(a);
+ float x_41 = x_6.x_GLF_uniform_float_values[0].el;
+ E = x_41;
+ int x_43 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_45 = v1[x_43];
+ float x_47 = x_6.x_GLF_uniform_float_values[2].el;
+ float x_49 = x_6.x_GLF_uniform_float_values[3].el;
+ bool x_54 = (abs((x_45 - (x_47 / x_49))) < E);
+ x_70_phi = x_54;
+ if (x_54) {
+ int x_58 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_60 = v1[x_58];
+ float x_62 = x_6.x_GLF_uniform_float_values[2].el;
+ float x_64 = x_6.x_GLF_uniform_float_values[3].el;
+ x_69 = (abs((x_60 - (x_62 / x_64))) < E);
+ x_70_phi = x_69;
+ }
+ bool x_70 = x_70_phi;
+ x_86_phi = x_70;
+ if (x_70) {
+ int x_74 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_76 = v1[x_74];
+ float x_78 = x_6.x_GLF_uniform_float_values[2].el;
+ float x_80 = x_6.x_GLF_uniform_float_values[3].el;
+ x_85 = (abs((x_76 - (x_78 / x_80))) < E);
+ x_86_phi = x_85;
+ }
+ bool x_86 = x_86_phi;
+ x_102_phi = x_86;
+ if (x_86) {
+ int x_90 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_92 = v1[x_90];
+ float x_94 = x_6.x_GLF_uniform_float_values[2].el;
+ float x_96 = x_6.x_GLF_uniform_float_values[3].el;
+ x_101 = (abs((x_92 - (x_94 / x_96))) < E);
+ x_102_phi = x_101;
+ }
+ if (x_102_phi) {
+ int x_107 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_110 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_113 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_116 = x_10.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_107), float(x_110), float(x_113), float(x_116));
+ } else {
+ int x_120 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_121 = float(x_120);
+ x_GLF_color = vec4(x_121, x_121, x_121, x_121);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'int4' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-packsnorm-unpackunorm/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-packsnorm-unpackunorm/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..146f9a2
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-combine-simplify-demanded-packsnorm-unpackunorm/0-opt.wgsl.expected.glsl
@@ -0,0 +1,135 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack4x8snorm(vec4 param_0) {
+ int4 i = int4(round(clamp(param_0, -1.0, 1.0) * 127.0)) & 0xff;
+ return asuint(i.x | i.y << 8 | i.z << 16 | i.w << 24);
+}
+
+vec4 tint_unpack4x8unorm(uint param_0) {
+ uint j = param_0;
+ uint4 i = uint4(j & 0xff, (j >> 8) & 0xff, (j >> 16) & 0xff, j >> 24);
+ return float4(i) / 255.0;
+}
+
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[4];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[4];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ vec4 v1 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ float E = 0.0f;
+ bool x_69 = false;
+ bool x_85 = false;
+ bool x_101 = false;
+ bool x_70_phi = false;
+ bool x_86_phi = false;
+ bool x_102_phi = false;
+ float x_35 = x_6.x_GLF_uniform_float_values[1].el;
+ a = tint_pack4x8snorm(vec4(x_35, x_35, x_35, x_35));
+ v1 = tint_unpack4x8unorm(a);
+ float x_41 = x_6.x_GLF_uniform_float_values[0].el;
+ E = x_41;
+ int x_43 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_45 = v1[x_43];
+ float x_47 = x_6.x_GLF_uniform_float_values[2].el;
+ float x_49 = x_6.x_GLF_uniform_float_values[3].el;
+ bool x_54 = (abs((x_45 - (x_47 / x_49))) < E);
+ x_70_phi = x_54;
+ if (x_54) {
+ int x_58 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_60 = v1[x_58];
+ float x_62 = x_6.x_GLF_uniform_float_values[2].el;
+ float x_64 = x_6.x_GLF_uniform_float_values[3].el;
+ x_69 = (abs((x_60 - (x_62 / x_64))) < E);
+ x_70_phi = x_69;
+ }
+ bool x_70 = x_70_phi;
+ x_86_phi = x_70;
+ if (x_70) {
+ int x_74 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_76 = v1[x_74];
+ float x_78 = x_6.x_GLF_uniform_float_values[2].el;
+ float x_80 = x_6.x_GLF_uniform_float_values[3].el;
+ x_85 = (abs((x_76 - (x_78 / x_80))) < E);
+ x_86_phi = x_85;
+ }
+ bool x_86 = x_86_phi;
+ x_102_phi = x_86;
+ if (x_86) {
+ int x_90 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_92 = v1[x_90];
+ float x_94 = x_6.x_GLF_uniform_float_values[2].el;
+ float x_96 = x_6.x_GLF_uniform_float_values[3].el;
+ x_101 = (abs((x_92 - (x_94 / x_96))) < E);
+ x_102_phi = x_101;
+ }
+ if (x_102_phi) {
+ int x_107 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_110 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_113 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_116 = x_10.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_107), float(x_110), float(x_113), float(x_116));
+ } else {
+ int x_120 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_121 = float(x_120);
+ x_GLF_color = vec4(x_121, x_121, x_121, x_121);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'int4' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-value-tracking-inversesqrt/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-value-tracking-inversesqrt/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..971f64a
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-value-tracking-inversesqrt/0-opt.spvasm.expected.glsl
@@ -0,0 +1,66 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_5;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float x_23 = x_5.x_GLF_uniform_float_values[1].el;
+ if ((rsqrt(x_23) < -1.0f)) {
+ float x_30 = x_5.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_30, x_30, x_30, x_30);
+ } else {
+ float x_33 = x_5.x_GLF_uniform_float_values[1].el;
+ float x_35 = x_5.x_GLF_uniform_float_values[0].el;
+ float x_37 = x_5.x_GLF_uniform_float_values[0].el;
+ float x_39 = x_5.x_GLF_uniform_float_values[1].el;
+ x_GLF_color = vec4(x_33, x_35, x_37, x_39);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:18: 'rsqrt' : no matching overloaded function found
+ERROR: 0:18: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-inst-value-tracking-inversesqrt/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-inst-value-tracking-inversesqrt/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..971f64a
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-inst-value-tracking-inversesqrt/0-opt.wgsl.expected.glsl
@@ -0,0 +1,66 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_5;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float x_23 = x_5.x_GLF_uniform_float_values[1].el;
+ if ((rsqrt(x_23) < -1.0f)) {
+ float x_30 = x_5.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_30, x_30, x_30, x_30);
+ } else {
+ float x_33 = x_5.x_GLF_uniform_float_values[1].el;
+ float x_35 = x_5.x_GLF_uniform_float_values[0].el;
+ float x_37 = x_5.x_GLF_uniform_float_values[0].el;
+ float x_39 = x_5.x_GLF_uniform_float_values[1].el;
+ x_GLF_color = vec4(x_33, x_35, x_37, x_39);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:18: 'rsqrt' : no matching overloaded function found
+ERROR: 0:18: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-instruction-simplify-mod-acos-undefined/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-instruction-simplify-mod-acos-undefined/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..e409ce1
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-instruction-simplify-mod-acos-undefined/0-opt.wgsl.expected.glsl
@@ -0,0 +1,78 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+};
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+} x_5;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+} x_8;
+
+void main_1() {
+ float a = 0.0f;
+ int x_10 = x_5.x_GLF_uniform_int_values[0].el;
+ int x_11 = x_5.x_GLF_uniform_int_values[1].el;
+ int x_12 = x_5.x_GLF_uniform_int_values[1].el;
+ int x_13 = x_5.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_10), float(x_11), float(x_12), float(x_13));
+ float x_45 = x_8.x_GLF_uniform_float_values[1].el;
+ a = (x_45 % uintBitsToFloat(0x7f800000u));
+ float x_47 = a;
+ float x_49 = x_8.x_GLF_uniform_float_values[0].el;
+ if ((x_47 != x_49)) {
+ float x_54 = x_8.x_GLF_uniform_float_values[0].el;
+ x_GLF_color.y = x_54;
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp mediump float' and a right operand of type ' global highp float' (or there is no acceptable conversion)
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-instruction-simplify-mod-sqrt-undefined/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-instruction-simplify-mod-sqrt-undefined/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..6059d04
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-instruction-simplify-mod-sqrt-undefined/0-opt.wgsl.expected.glsl
@@ -0,0 +1,78 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+};
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+} x_5;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[2];
+} x_8;
+
+void main_1() {
+ float a = 0.0f;
+ int x_10 = x_5.x_GLF_uniform_int_values[0].el;
+ int x_11 = x_5.x_GLF_uniform_int_values[1].el;
+ int x_12 = x_5.x_GLF_uniform_int_values[1].el;
+ int x_13 = x_5.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_10), float(x_11), float(x_12), float(x_13));
+ float x_45 = x_8.x_GLF_uniform_float_values[1].el;
+ a = (uintBitsToFloat(0xff800000u) % x_45);
+ float x_47 = a;
+ float x_49 = x_8.x_GLF_uniform_float_values[0].el;
+ if ((x_47 != x_49)) {
+ float x_54 = x_8.x_GLF_uniform_float_values[0].el;
+ x_GLF_color.y = x_54;
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' global highp float' and a right operand of type ' temp mediump float' (or there is no acceptable conversion)
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-loop-condition-double-negate/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-loop-condition-double-negate/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..0feee82
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-loop-condition-double-negate/0-opt.spvasm.expected.glsl
@@ -0,0 +1,117 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[6];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[6];
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int arr[3] = int[3](0, 0, 0);
+ int index = 0;
+ bool x_76 = false;
+ bool x_86 = false;
+ bool x_77_phi = false;
+ bool x_87_phi = false;
+ int x_33 = x_6.x_GLF_uniform_int_values[3].el;
+ int x_35 = x_6.x_GLF_uniform_int_values[5].el;
+ int x_37 = x_6.x_GLF_uniform_int_values[2].el;
+ int tint_symbol_2[3] = int[3](x_33, x_35, x_37);
+ arr = tint_symbol_2;
+ index = 1;
+ while (true) {
+ bool x_51 = false;
+ bool x_52_phi = false;
+ x_52_phi = true;
+ if (true) {
+ int x_46 = x_6.x_GLF_uniform_int_values[0].el;
+ x_51 = !(((x_46 == 1) & (index <= 1)));
+ x_52_phi = x_51;
+ }
+ if (!(x_52_phi)) {
+ } else {
+ break;
+ }
+ int x_56_save = index;
+ int x_57 = arr[x_56_save];
+ arr[x_56_save] = (x_57 + 1);
+ index = (index + 1);
+ }
+ int x_62 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_64 = arr[x_62];
+ int x_66 = x_6.x_GLF_uniform_int_values[3].el;
+ bool x_67 = (x_64 == x_66);
+ x_77_phi = x_67;
+ if (x_67) {
+ int x_71 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_73 = arr[x_71];
+ int x_75 = x_6.x_GLF_uniform_int_values[4].el;
+ x_76 = (x_73 == x_75);
+ x_77_phi = x_76;
+ }
+ bool x_77 = x_77_phi;
+ x_87_phi = x_77;
+ if (x_77) {
+ int x_81 = x_6.x_GLF_uniform_int_values[3].el;
+ int x_83 = arr[x_81];
+ int x_85 = x_6.x_GLF_uniform_int_values[2].el;
+ x_86 = (x_83 == x_85);
+ x_87_phi = x_86;
+ }
+ if (x_87_phi) {
+ int x_92 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_95 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_98 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_101 = x_6.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_92), float(x_95), float(x_98), float(x_101));
+ } else {
+ int x_105 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_106 = float(x_105);
+ x_GLF_color = vec4(x_106, x_106, x_106, x_106);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_3 = main_out(x_GLF_color);
+ return tint_symbol_3;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:35: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:35: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-loop-dfdx-constant-divide/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-loop-dfdx-constant-divide/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..b22034f
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-loop-dfdx-constant-divide/0-opt.spvasm.expected.glsl
@@ -0,0 +1,109 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_6;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+} x_11;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float a = 0.0f;
+ float b = 0.0f;
+ float c = 0.0f;
+ int i = 0;
+ float x_35 = x_6.x_GLF_uniform_float_values[1].el;
+ a = x_35;
+ float x_37 = x_6.x_GLF_uniform_float_values[1].el;
+ b = x_37;
+ float x_39 = x_6.x_GLF_uniform_float_values[1].el;
+ c = x_39;
+ int x_41 = x_11.x_GLF_uniform_int_values[1].el;
+ i = x_41;
+ while (true) {
+ int x_46 = i;
+ int x_48 = x_11.x_GLF_uniform_int_values[0].el;
+ if ((x_46 < x_48)) {
+ } else {
+ break;
+ }
+ int x_51 = i;
+ int x_53 = x_11.x_GLF_uniform_int_values[2].el;
+ if ((x_51 == x_53)) {
+ float x_57 = a;
+ float x_60 = x_6.x_GLF_uniform_float_values[1].el;
+ b = (ddx(x_57) + x_60);
+ }
+ c = ddx(a);
+ a = (c / b);
+ {
+ i = (i + 1);
+ }
+ }
+ float x_69 = a;
+ float x_71 = x_6.x_GLF_uniform_float_values[0].el;
+ if ((x_69 == x_71)) {
+ int x_77 = x_11.x_GLF_uniform_int_values[2].el;
+ int x_80 = x_11.x_GLF_uniform_int_values[1].el;
+ int x_83 = x_11.x_GLF_uniform_int_values[1].el;
+ int x_86 = x_11.x_GLF_uniform_int_values[2].el;
+ x_GLF_color = vec4(float(x_77), float(x_80), float(x_83), float(x_86));
+ } else {
+ int x_90 = x_11.x_GLF_uniform_int_values[1].el;
+ float x_91 = float(x_90);
+ x_GLF_color = vec4(x_91, x_91, x_91, x_91);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:50: 'ddx' : no matching overloaded function found
+ERROR: 0:50: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-loop-dfdx-constant-divide/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-loop-dfdx-constant-divide/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..b22034f
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-loop-dfdx-constant-divide/0-opt.wgsl.expected.glsl
@@ -0,0 +1,109 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_6;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+} x_11;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float a = 0.0f;
+ float b = 0.0f;
+ float c = 0.0f;
+ int i = 0;
+ float x_35 = x_6.x_GLF_uniform_float_values[1].el;
+ a = x_35;
+ float x_37 = x_6.x_GLF_uniform_float_values[1].el;
+ b = x_37;
+ float x_39 = x_6.x_GLF_uniform_float_values[1].el;
+ c = x_39;
+ int x_41 = x_11.x_GLF_uniform_int_values[1].el;
+ i = x_41;
+ while (true) {
+ int x_46 = i;
+ int x_48 = x_11.x_GLF_uniform_int_values[0].el;
+ if ((x_46 < x_48)) {
+ } else {
+ break;
+ }
+ int x_51 = i;
+ int x_53 = x_11.x_GLF_uniform_int_values[2].el;
+ if ((x_51 == x_53)) {
+ float x_57 = a;
+ float x_60 = x_6.x_GLF_uniform_float_values[1].el;
+ b = (ddx(x_57) + x_60);
+ }
+ c = ddx(a);
+ a = (c / b);
+ {
+ i = (i + 1);
+ }
+ }
+ float x_69 = a;
+ float x_71 = x_6.x_GLF_uniform_float_values[0].el;
+ if ((x_69 == x_71)) {
+ int x_77 = x_11.x_GLF_uniform_int_values[2].el;
+ int x_80 = x_11.x_GLF_uniform_int_values[1].el;
+ int x_83 = x_11.x_GLF_uniform_int_values[1].el;
+ int x_86 = x_11.x_GLF_uniform_int_values[2].el;
+ x_GLF_color = vec4(float(x_77), float(x_80), float(x_83), float(x_86));
+ } else {
+ int x_90 = x_11.x_GLF_uniform_int_values[1].el;
+ float x_91 = float(x_90);
+ x_GLF_color = vec4(x_91, x_91, x_91, x_91);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:50: 'ddx' : no matching overloaded function found
+ERROR: 0:50: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-loop-increment-matrix-element-break-after-first-iteration/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-loop-increment-matrix-element-break-after-first-iteration/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..03e10a5
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-loop-increment-matrix-element-break-after-first-iteration/0-opt.spvasm.expected.glsl
@@ -0,0 +1,126 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_7;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_10;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat2x3 m23 = mat2x3(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ int i = 0;
+ float x_46 = x_7.x_GLF_uniform_float_values[1].el;
+ m23 = mat2x3(vec3(x_46, 0.0f, 0.0f), vec3(0.0f, x_46, 0.0f));
+ i = 1;
+ while (true) {
+ bool x_80 = false;
+ bool x_81_phi = false;
+ int x_54 = i;
+ int x_56 = x_10.x_GLF_uniform_int_values[3].el;
+ if ((x_54 < x_56)) {
+ } else {
+ break;
+ }
+ int x_60 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_62 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_64 = x_7.x_GLF_uniform_float_values[0].el;
+ float x_66 = m23[x_60][x_62];
+ m23[x_60][x_62] = (x_66 + x_64);
+ float x_70 = tint_symbol.y;
+ float x_72 = x_7.x_GLF_uniform_float_values[0].el;
+ if ((x_70 < x_72)) {
+ }
+ x_81_phi = true;
+ if (true) {
+ float x_79 = tint_symbol.x;
+ x_80 = (x_79 < 0.0f);
+ x_81_phi = x_80;
+ }
+ if (!(x_81_phi)) {
+ break;
+ }
+ {
+ i = (i + 1);
+ }
+ }
+ mat2x3 x_87 = m23;
+ int x_89 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_92 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_95 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_98 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_101 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_104 = x_10.x_GLF_uniform_int_values[0].el;
+ mat2x3 x_108 = mat2x3(vec3(float(x_89), float(x_92), float(x_95)), vec3(float(x_98), float(x_101), float(x_104)));
+ if ((all(equal(x_87[0u], x_108[0u])) & all(equal(x_87[1u], x_108[1u])))) {
+ int x_122 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_125 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_128 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_131 = x_10.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_122), float(x_125), float(x_128), float(x_131));
+ } else {
+ int x_135 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_136 = float(x_135);
+ x_GLF_color = vec4(x_136, x_136, x_136, x_136);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:71: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' global bool' and a right operand of type ' global bool' (or there is no acceptable conversion)
+ERROR: 0:71: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-matrix-double-transpose/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-matrix-double-transpose/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..56e5699
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-matrix-double-transpose/0-opt.spvasm.expected.glsl
@@ -0,0 +1,74 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[2];
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat2 m = mat2(0.0f, 0.0f, 0.0f, 0.0f);
+ int x_29 = x_6.x_GLF_uniform_int_values[0].el;
+ float x_30 = float(x_29);
+ m = transpose(transpose(mat2(vec2(x_30, 0.0f), vec2(0.0f, x_30))));
+ mat2 x_36 = m;
+ int x_38 = x_6.x_GLF_uniform_int_values[0].el;
+ float x_39 = float(x_38);
+ mat2 x_42 = mat2(vec2(x_39, 0.0f), vec2(0.0f, x_39));
+ if ((all(equal(x_36[0u], x_42[0u])) & all(equal(x_36[1u], x_42[1u])))) {
+ int x_56 = x_6.x_GLF_uniform_int_values[0].el;
+ int x_59 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_62 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_65 = x_6.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_56), float(x_59), float(x_62), float(x_65));
+ } else {
+ int x_69 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_70 = float(x_69);
+ x_GLF_color = vec4(x_70, x_70, x_70, x_70);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' global bool' and a right operand of type ' global bool' (or there is no acceptable conversion)
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-missing-return-value-function-never-called/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-missing-return-value-function-never-called/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..243be09
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-missing-return-value-function-never-called/0-opt.spvasm.expected.glsl
@@ -0,0 +1,105 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack4x8unorm(vec4 param_0) {
+ uint4 i = uint4(round(clamp(param_0, 0.0, 1.0) * 255.0));
+ return (i.x | i.y << 8 | i.z << 16 | i.w << 24);
+}
+
+
+struct buf1 {
+ uint one;
+};
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[1];
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ uint one;
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[1];
+} x_10;
+
+float func_() {
+ switch(1) {
+ case 0: {
+ return 1.0f;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ return 0.0f;
+}
+
+void main_1() {
+ vec4 v = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ v = vec4(1.0f, 1.0f, 1.0f, 1.0f);
+ float x_38 = tint_symbol.y;
+ if ((x_38 < 0.0f)) {
+ float x_42 = func_();
+ v = vec4(x_42, x_42, x_42, x_42);
+ }
+ if ((tint_pack4x8unorm(v) == 1u)) {
+ return;
+ }
+ uint x_50 = x_8.one;
+ if (((1u << x_50) == 2u)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ int x_57 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_58 = float(x_57);
+ x_GLF_color = vec4(x_58, x_58, x_58, x_58);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint4' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-missing-return-value-function-never-called/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-missing-return-value-function-never-called/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..243be09
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-missing-return-value-function-never-called/0-opt.wgsl.expected.glsl
@@ -0,0 +1,105 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack4x8unorm(vec4 param_0) {
+ uint4 i = uint4(round(clamp(param_0, 0.0, 1.0) * 255.0));
+ return (i.x | i.y << 8 | i.z << 16 | i.w << 24);
+}
+
+
+struct buf1 {
+ uint one;
+};
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[1];
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ uint one;
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[1];
+} x_10;
+
+float func_() {
+ switch(1) {
+ case 0: {
+ return 1.0f;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ return 0.0f;
+}
+
+void main_1() {
+ vec4 v = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ v = vec4(1.0f, 1.0f, 1.0f, 1.0f);
+ float x_38 = tint_symbol.y;
+ if ((x_38 < 0.0f)) {
+ float x_42 = func_();
+ v = vec4(x_42, x_42, x_42, x_42);
+ }
+ if ((tint_pack4x8unorm(v) == 1u)) {
+ return;
+ }
+ uint x_50 = x_8.one;
+ if (((1u << x_50) == 2u)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ int x_57 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_58 = float(x_57);
+ x_GLF_color = vec4(x_58, x_58, x_58, x_58);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint4' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-mod-uint-bits-float/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-mod-uint-bits-float/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..6cad8e7
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-mod-uint-bits-float/0-opt.wgsl.expected.glsl
@@ -0,0 +1,68 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[3];
+};
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[3];
+} x_6;
+
+void main_1() {
+ float a = 0.0f;
+ a = (uintBitsToFloat(1u) % 1.0f);
+ float x_29 = x_6.x_GLF_uniform_float_values[1].el;
+ x_GLF_color = vec4(x_29, x_29, x_29, x_29);
+ float x_31 = a;
+ float x_33 = x_6.x_GLF_uniform_float_values[2].el;
+ if ((x_31 < x_33)) {
+ float x_38 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_40 = x_6.x_GLF_uniform_float_values[1].el;
+ float x_42 = x_6.x_GLF_uniform_float_values[1].el;
+ float x_44 = x_6.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_38, x_40, x_42, x_44);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:18: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' global highp float' and a right operand of type ' const float' (or there is no acceptable conversion)
+ERROR: 0:18: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-nested-functions-accumulate-global-matrix/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-nested-functions-accumulate-global-matrix/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..1adabe4
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-nested-functions-accumulate-global-matrix/0-opt.spvasm.expected.glsl
@@ -0,0 +1,161 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf2 {
+ float one;
+};
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+mat4x2 m = mat4x2(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 2) uniform buf2_1 {
+ float one;
+} x_10;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[1];
+} x_12;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_16;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void func0_i1_(inout int x) {
+ int i = 0;
+ bool x_137 = false;
+ bool x_138 = false;
+ bool x_138_phi = false;
+ bool x_139_phi = false;
+ int x_124 = x;
+ bool x_125 = (x_124 < 1);
+ x_139_phi = x_125;
+ if (!(x_125)) {
+ int x_129 = x;
+ bool x_130 = (x_129 > 1);
+ x_138_phi = x_130;
+ if (x_130) {
+ float x_134 = x_10.one;
+ float x_136 = x_12.x_GLF_uniform_float_values[0].el;
+ x_137 = (x_134 > x_136);
+ x_138_phi = x_137;
+ }
+ x_138 = x_138_phi;
+ x_139_phi = x_138;
+ }
+ if (x_139_phi) {
+ return;
+ }
+ float x_143 = x_10.one;
+ float x_145 = x_12.x_GLF_uniform_float_values[0].el;
+ if ((x_143 == x_145)) {
+ i = 0;
+ while (true) {
+ if ((i < 2)) {
+ } else {
+ break;
+ }
+ {
+ int x_154 = x;
+ int x_155 = clamp(x_154, 0, 3);
+ int x_156 = i;
+ float x_158 = x_12.x_GLF_uniform_float_values[0].el;
+ float x_160 = m[x_155][x_156];
+ m[x_155][x_156] = (x_160 + x_158);
+ i = (i + 1);
+ }
+ }
+ }
+ return;
+}
+
+void func1_() {
+ int param = 0;
+ float x_167 = tint_symbol.y;
+ if ((x_167 < 0.0f)) {
+ return;
+ }
+ param = 1;
+ func0_i1_(param);
+ return;
+}
+
+void main_1() {
+ m = mat4x2(vec2(0.0f, 0.0f), vec2(0.0f, 0.0f), vec2(0.0f, 0.0f), vec2(0.0f, 0.0f));
+ func1_();
+ func1_();
+ mat4x2 x_54 = m;
+ int x_56 = x_16.x_GLF_uniform_int_values[0].el;
+ int x_59 = x_16.x_GLF_uniform_int_values[0].el;
+ int x_62 = x_16.x_GLF_uniform_int_values[1].el;
+ int x_65 = x_16.x_GLF_uniform_int_values[1].el;
+ int x_68 = x_16.x_GLF_uniform_int_values[0].el;
+ int x_71 = x_16.x_GLF_uniform_int_values[0].el;
+ int x_74 = x_16.x_GLF_uniform_int_values[0].el;
+ int x_77 = x_16.x_GLF_uniform_int_values[0].el;
+ mat4x2 x_83 = mat4x2(vec2(float(x_56), float(x_59)), vec2(float(x_62), float(x_65)), vec2(float(x_68), float(x_71)), vec2(float(x_74), float(x_77)));
+ if ((((all(equal(x_54[0u], x_83[0u])) & all(equal(x_54[1u], x_83[1u]))) & all(equal(x_54[2u], x_83[2u]))) & all(equal(x_54[3u], x_83[3u])))) {
+ int x_107 = x_16.x_GLF_uniform_int_values[3].el;
+ int x_110 = x_16.x_GLF_uniform_int_values[0].el;
+ int x_113 = x_16.x_GLF_uniform_int_values[0].el;
+ int x_116 = x_16.x_GLF_uniform_int_values[3].el;
+ x_GLF_color = vec4(float(x_107), float(x_110), float(x_113), float(x_116));
+ } else {
+ int x_120 = x_16.x_GLF_uniform_int_values[0].el;
+ float x_121 = float(x_120);
+ x_GLF_color = vec4(x_121, x_121, x_121, x_121);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:106: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' global bool' and a right operand of type ' global bool' (or there is no acceptable conversion)
+ERROR: 0:106: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-packhalf-unpackunorm/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-packhalf-unpackunorm/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..aca1432
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-packhalf-unpackunorm/0-opt.spvasm.expected.glsl
@@ -0,0 +1,144 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack2x16float(vec2 param_0) {
+ uint2 i = f32tof16(param_0);
+ return i.x | (i.y << 16);
+}
+
+vec4 tint_unpack4x8unorm(uint param_0) {
+ uint j = param_0;
+ uint4 i = uint4(j & 0xff, (j >> 8) & 0xff, (j >> 16) & 0xff, j >> 24);
+ return float4(i) / 255.0;
+}
+
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[4];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[4];
+} x_8;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ vec4 values = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ vec4 ref = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ bool x_85 = false;
+ bool x_101 = false;
+ bool x_117 = false;
+ bool x_86_phi = false;
+ bool x_102_phi = false;
+ bool x_118_phi = false;
+ a = tint_pack2x16float(vec2(1.0f, 1.0f));
+ values = tint_unpack4x8unorm(a);
+ float x_41 = x_8.x_GLF_uniform_float_values[3].el;
+ float x_43 = x_8.x_GLF_uniform_float_values[1].el;
+ float x_45 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_48 = x_8.x_GLF_uniform_float_values[3].el;
+ float x_50 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_53 = x_8.x_GLF_uniform_float_values[1].el;
+ float x_55 = x_8.x_GLF_uniform_float_values[0].el;
+ ref = vec4(x_41, (x_43 / x_45), (x_48 / x_50), (x_53 / x_55));
+ int x_59 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_61 = values[x_59];
+ int x_63 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_65 = ref[x_63];
+ float x_69 = x_8.x_GLF_uniform_float_values[2].el;
+ bool x_70 = (abs((x_61 - x_65)) < x_69);
+ x_86_phi = x_70;
+ if (x_70) {
+ int x_74 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_76 = values[x_74];
+ int x_78 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_80 = ref[x_78];
+ float x_84 = x_8.x_GLF_uniform_float_values[2].el;
+ x_85 = (abs((x_76 - x_80)) < x_84);
+ x_86_phi = x_85;
+ }
+ bool x_86 = x_86_phi;
+ x_102_phi = x_86;
+ if (x_86) {
+ int x_90 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_92 = values[x_90];
+ int x_94 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_96 = ref[x_94];
+ float x_100 = x_8.x_GLF_uniform_float_values[2].el;
+ x_101 = (abs((x_92 - x_96)) < x_100);
+ x_102_phi = x_101;
+ }
+ bool x_102 = x_102_phi;
+ x_118_phi = x_102;
+ if (x_102) {
+ int x_106 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_108 = values[x_106];
+ int x_110 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_112 = ref[x_110];
+ float x_116 = x_8.x_GLF_uniform_float_values[2].el;
+ x_117 = (abs((x_108 - x_112)) < x_116);
+ x_118_phi = x_117;
+ }
+ if (x_118_phi) {
+ int x_123 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_126 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_129 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_132 = x_10.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(float(x_123), float(x_126), float(x_129), float(x_132));
+ } else {
+ int x_136 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_137 = float(x_136);
+ x_GLF_color = vec4(x_137, x_137, x_137, x_137);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint2' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-packhalf-unpackunorm/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-packhalf-unpackunorm/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..aca1432
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-packhalf-unpackunorm/0-opt.wgsl.expected.glsl
@@ -0,0 +1,144 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+uint tint_pack2x16float(vec2 param_0) {
+ uint2 i = f32tof16(param_0);
+ return i.x | (i.y << 16);
+}
+
+vec4 tint_unpack4x8unorm(uint param_0) {
+ uint j = param_0;
+ uint4 i = uint4(j & 0xff, (j >> 8) & 0xff, (j >> 16) & 0xff, j >> 24);
+ return float4(i) / 255.0;
+}
+
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[4];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[4];
+} x_8;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ uint a = 0u;
+ vec4 values = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ vec4 ref = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ bool x_85 = false;
+ bool x_101 = false;
+ bool x_117 = false;
+ bool x_86_phi = false;
+ bool x_102_phi = false;
+ bool x_118_phi = false;
+ a = tint_pack2x16float(vec2(1.0f, 1.0f));
+ values = tint_unpack4x8unorm(a);
+ float x_41 = x_8.x_GLF_uniform_float_values[3].el;
+ float x_43 = x_8.x_GLF_uniform_float_values[1].el;
+ float x_45 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_48 = x_8.x_GLF_uniform_float_values[3].el;
+ float x_50 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_53 = x_8.x_GLF_uniform_float_values[1].el;
+ float x_55 = x_8.x_GLF_uniform_float_values[0].el;
+ ref = vec4(x_41, (x_43 / x_45), (x_48 / x_50), (x_53 / x_55));
+ int x_59 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_61 = values[x_59];
+ int x_63 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_65 = ref[x_63];
+ float x_69 = x_8.x_GLF_uniform_float_values[2].el;
+ bool x_70 = (abs((x_61 - x_65)) < x_69);
+ x_86_phi = x_70;
+ if (x_70) {
+ int x_74 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_76 = values[x_74];
+ int x_78 = x_10.x_GLF_uniform_int_values[1].el;
+ float x_80 = ref[x_78];
+ float x_84 = x_8.x_GLF_uniform_float_values[2].el;
+ x_85 = (abs((x_76 - x_80)) < x_84);
+ x_86_phi = x_85;
+ }
+ bool x_86 = x_86_phi;
+ x_102_phi = x_86;
+ if (x_86) {
+ int x_90 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_92 = values[x_90];
+ int x_94 = x_10.x_GLF_uniform_int_values[3].el;
+ float x_96 = ref[x_94];
+ float x_100 = x_8.x_GLF_uniform_float_values[2].el;
+ x_101 = (abs((x_92 - x_96)) < x_100);
+ x_102_phi = x_101;
+ }
+ bool x_102 = x_102_phi;
+ x_118_phi = x_102;
+ if (x_102) {
+ int x_106 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_108 = values[x_106];
+ int x_110 = x_10.x_GLF_uniform_int_values[2].el;
+ float x_112 = ref[x_110];
+ float x_116 = x_8.x_GLF_uniform_float_values[2].el;
+ x_117 = (abs((x_108 - x_112)) < x_116);
+ x_118_phi = x_117;
+ }
+ if (x_118_phi) {
+ int x_123 = x_10.x_GLF_uniform_int_values[1].el;
+ int x_126 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_129 = x_10.x_GLF_uniform_int_values[0].el;
+ int x_132 = x_10.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(float(x_123), float(x_126), float(x_129), float(x_132));
+ } else {
+ int x_136 = x_10.x_GLF_uniform_int_values[0].el;
+ float x_137 = float(x_136);
+ x_GLF_color = vec4(x_137, x_137, x_137, x_137);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: 'uint2' : undeclared identifier
+ERROR: 0:5: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-pow-undefined/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-pow-undefined/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..cf68f0f
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-pow-undefined/0-opt.spvasm.expected.glsl
@@ -0,0 +1,73 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_8;
+
+void main_1() {
+ float a = 0.0f;
+ float b = 0.0f;
+ float c = 0.0f;
+ a = -1.0f;
+ b = 1.700000048f;
+ c = pow(a, b);
+ float x_30 = c;
+ x_GLF_color = vec4(x_30, x_30, x_30, x_30);
+ if (((a == -1.0f) & (b == 1.700000048f))) {
+ float x_41 = x_8.x_GLF_uniform_float_values[0].el;
+ float x_43 = x_8.x_GLF_uniform_float_values[1].el;
+ float x_45 = x_8.x_GLF_uniform_float_values[1].el;
+ float x_47 = x_8.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_41, x_43, x_45, x_47);
+ } else {
+ float x_50 = x_8.x_GLF_uniform_float_values[0].el;
+ x_GLF_color = vec4(x_50, x_50, x_50, x_50);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:25: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:25: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-reduce-load-array-replace-extract/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-reduce-load-array-replace-extract/0.spvasm.expected.glsl
new file mode 100644
index 0000000..377b176
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-reduce-load-array-replace-extract/0.spvasm.expected.glsl
@@ -0,0 +1,72 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ int zero;
+};
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ int zero;
+} x_5;
+
+void main_1() {
+ int x_9[1] = int[1](0);
+ int x_10_phi = 0;
+ int x_6 = x_9[0u];
+ while (true) {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ int x_7 = x_5.zero;
+ int x_8 = x_9[x_7];
+ if ((x_8 == x_6)) {
+ x_10_phi = 1;
+ break;
+ }
+ x_10_phi = 2;
+ break;
+ }
+ int x_10 = x_10_phi;
+ if (((x_10 == 1) | (x_10 == 2))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:29: '|' : wrong operand types: no operation '|' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:29: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-reinitialize-matrix-after-undefined-value/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-reinitialize-matrix-after-undefined-value/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..6dc5558
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-reinitialize-matrix-after-undefined-value/0-opt.spvasm.expected.glsl
@@ -0,0 +1,112 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+} x_5;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat2 m = mat2(0.0f, 0.0f, 0.0f, 0.0f);
+ float f = 0.0f;
+ int i = 0;
+ int j = 0;
+ int x_36 = x_5.x_GLF_uniform_int_values[1].el;
+ if ((x_36 == 1)) {
+ float x_40 = f;
+ m = mat2(vec2(x_40, 0.0f), vec2(0.0f, x_40));
+ }
+ int x_45 = x_5.x_GLF_uniform_int_values[1].el;
+ i = x_45;
+ while (true) {
+ int x_50 = i;
+ int x_52 = x_5.x_GLF_uniform_int_values[0].el;
+ if ((x_50 < x_52)) {
+ } else {
+ break;
+ }
+ int x_56 = x_5.x_GLF_uniform_int_values[1].el;
+ j = x_56;
+ while (true) {
+ int x_61 = j;
+ int x_63 = x_5.x_GLF_uniform_int_values[0].el;
+ if ((x_61 < x_63)) {
+ } else {
+ break;
+ }
+ int x_66 = i;
+ int x_67 = j;
+ int x_68 = i;
+ int x_70 = x_5.x_GLF_uniform_int_values[0].el;
+ m[x_66][x_67] = float(((x_68 * x_70) + j));
+ {
+ j = (j + 1);
+ }
+ }
+ {
+ i = (i + 1);
+ }
+ }
+ mat2 x_80 = m;
+ int x_82 = x_5.x_GLF_uniform_int_values[1].el;
+ int x_85 = x_5.x_GLF_uniform_int_values[2].el;
+ int x_88 = x_5.x_GLF_uniform_int_values[0].el;
+ int x_91 = x_5.x_GLF_uniform_int_values[3].el;
+ mat2 x_95 = mat2(vec2(float(x_82), float(x_85)), vec2(float(x_88), float(x_91)));
+ if ((all(equal(x_80[0u], x_95[0u])) & all(equal(x_80[1u], x_95[1u])))) {
+ int x_109 = x_5.x_GLF_uniform_int_values[2].el;
+ int x_112 = x_5.x_GLF_uniform_int_values[1].el;
+ int x_115 = x_5.x_GLF_uniform_int_values[1].el;
+ int x_118 = x_5.x_GLF_uniform_int_values[2].el;
+ x_GLF_color = vec4(float(x_109), float(x_112), float(x_115), float(x_118));
+ } else {
+ int x_122 = x_5.x_GLF_uniform_int_values[1].el;
+ float x_123 = float(x_122);
+ x_GLF_color = vec4(x_123, x_123, x_123, x_123);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:63: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' global bool' and a right operand of type ' global bool' (or there is no acceptable conversion)
+ERROR: 0:63: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-simplify-modulo-1/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-simplify-modulo-1/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..ba52642
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-simplify-modulo-1/0-opt.wgsl.expected.glsl
@@ -0,0 +1,79 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[1];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[1];
+} x_8;
+
+void main_1() {
+ float a = 0.0f;
+ float x_30 = x_6.x_GLF_uniform_float_values[0].el;
+ a = (x_30 % 1.0f);
+ float x_32 = a;
+ float x_34 = x_6.x_GLF_uniform_float_values[0].el;
+ if ((x_32 == x_34)) {
+ int x_40 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_42 = a;
+ float x_43 = a;
+ int x_45 = x_8.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_40), x_42, x_43, float(x_45));
+ } else {
+ float x_48 = a;
+ x_GLF_color = vec4(x_48, x_48, x_48, x_48);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:28: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp mediump float' and a right operand of type ' const float' (or there is no acceptable conversion)
+ERROR: 0:28: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-target-lowering-dfdx-cos/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-target-lowering-dfdx-cos/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..17f021c
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-target-lowering-dfdx-cos/0-opt.spvasm.expected.glsl
@@ -0,0 +1,70 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ float two;
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ float two;
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float a = 0.0f;
+ float b = 0.0f;
+ float x_33 = tint_symbol.x;
+ a = ddx(cos(x_33));
+ float x_37 = x_8.two;
+ b = mix(2.0f, x_37, a);
+ if (((b >= 1.899999976f) & (b <= 2.099999905f))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:18: 'ddx' : no matching overloaded function found
+ERROR: 0:18: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-target-lowering-dfdx-cos/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-target-lowering-dfdx-cos/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..c484a7a
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-target-lowering-dfdx-cos/0-opt.wgsl.expected.glsl
@@ -0,0 +1,74 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ float two;
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ float two;
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ float a = 0.0f;
+ float b = 0.0f;
+ float x_33 = tint_symbol.x;
+ a = ddx(cos(x_33));
+ float x_37 = x_8.two;
+ b = mix(2.0f, x_37, a);
+ bool tint_tmp = (b >= 1.899999976f);
+ if (tint_tmp) {
+ tint_tmp = (b <= 2.099999905f);
+ }
+ if ((tint_tmp)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:18: 'ddx' : no matching overloaded function found
+ERROR: 0:18: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-transpose-multiply/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-transpose-multiply/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..14f9f57
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-transpose-multiply/0-opt.spvasm.expected.glsl
@@ -0,0 +1,54 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat2 m = mat2(0.0f, 0.0f, 0.0f, 0.0f);
+ m = mat2(vec2(1.0f, 2.0f), vec2(3.0f, 4.0f));
+ mat2 x_30 = (transpose(m) * transpose(m));
+ mat2 x_34 = transpose((m * m));
+ if ((all(equal(x_30[0u], x_34[0u])) & all(equal(x_30[1u], x_34[1u])))) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:11: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' global bool' and a right operand of type ' global bool' (or there is no acceptable conversion)
+ERROR: 0:11: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-trunc-fract-always-zero/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-trunc-fract-always-zero/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..675c1f7
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-trunc-fract-always-zero/0-opt.spvasm.expected.glsl
@@ -0,0 +1,88 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_7;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+} x_9;
+
+void main_1() {
+ float f = 0.0f;
+ float x_35 = tint_symbol.y;
+ float x_37 = x_7.x_GLF_uniform_float_values[1].el;
+ f = frac(trunc(((x_35 < x_37) ? 0.100000001f : 1.0f)));
+ float x_42 = f;
+ float x_44 = x_7.x_GLF_uniform_float_values[0].el;
+ if ((x_42 == x_44)) {
+ int x_50 = x_9.x_GLF_uniform_int_values[0].el;
+ int x_53 = x_9.x_GLF_uniform_int_values[1].el;
+ int x_56 = x_9.x_GLF_uniform_int_values[1].el;
+ int x_59 = x_9.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_50), float(x_53), float(x_56), float(x_59));
+ } else {
+ int x_63 = x_9.x_GLF_uniform_int_values[1].el;
+ float x_64 = float(x_63);
+ x_GLF_color = vec4(x_64, x_64, x_64, x_64);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:30: 'frac' : no matching overloaded function found
+ERROR: 0:30: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-trunc-fract-always-zero/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-trunc-fract-always-zero/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..675c1f7
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-trunc-fract-always-zero/0-opt.wgsl.expected.glsl
@@ -0,0 +1,88 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_7;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+} x_9;
+
+void main_1() {
+ float f = 0.0f;
+ float x_35 = tint_symbol.y;
+ float x_37 = x_7.x_GLF_uniform_float_values[1].el;
+ f = frac(trunc(((x_35 < x_37) ? 0.100000001f : 1.0f)));
+ float x_42 = f;
+ float x_44 = x_7.x_GLF_uniform_float_values[0].el;
+ if ((x_42 == x_44)) {
+ int x_50 = x_9.x_GLF_uniform_int_values[0].el;
+ int x_53 = x_9.x_GLF_uniform_int_values[1].el;
+ int x_56 = x_9.x_GLF_uniform_int_values[1].el;
+ int x_59 = x_9.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_50), float(x_53), float(x_56), float(x_59));
+ } else {
+ int x_63 = x_9.x_GLF_uniform_int_values[1].el;
+ float x_64 = float(x_63);
+ x_GLF_color = vec4(x_64, x_64, x_64, x_64);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:30: 'frac' : no matching overloaded function found
+ERROR: 0:30: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-unpack-unorm-mix-always-one/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-unpack-unorm-mix-always-one/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..087d848
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-unpack-unorm-mix-always-one/0-opt.spvasm.expected.glsl
@@ -0,0 +1,102 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_unpack4x8unorm(uint param_0) {
+ uint j = param_0;
+ uint4 i = uint4(j & 0xff, (j >> 8) & 0xff, (j >> 16) & 0xff, j >> 24);
+ return float4(i) / 255.0;
+}
+
+
+struct tint_padded_array_element {
+ uint el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_uint_values[1];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+};
+struct tint_padded_array_element_2 {
+ float el;
+};
+struct buf2 {
+ tint_padded_array_element_2 x_GLF_uniform_float_values[3];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_uint_values[1];
+} x_6;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+} x_8;
+layout (binding = 2) uniform buf2_1 {
+ tint_padded_array_element_2 x_GLF_uniform_float_values[3];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec4 v = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ uint x_39 = x_6.x_GLF_uniform_uint_values[0].el;
+ uint x_41 = x_6.x_GLF_uniform_uint_values[0].el;
+ v = tint_unpack4x8unorm((x_39 / (true ? 92382u : x_41)));
+ vec4 x_45 = v;
+ int x_47 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_50 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_53 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_56 = x_10.x_GLF_uniform_float_values[1].el;
+ float x_58 = x_10.x_GLF_uniform_float_values[2].el;
+ float x_63 = x_10.x_GLF_uniform_float_values[0].el;
+ if ((distance(x_45, vec4(float(x_47), float(x_50), float(x_53), (x_56 / x_58))) < x_63)) {
+ int x_69 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_72 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_75 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_78 = x_8.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(float(x_69), float(x_72), float(x_75), float(x_78));
+ } else {
+ int x_82 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_83 = float(x_82);
+ x_GLF_color = vec4(x_83, x_83, x_83, x_83);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'uint4' : undeclared identifier
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-unpack-unorm-mix-always-one/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-unpack-unorm-mix-always-one/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..087d848
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-unpack-unorm-mix-always-one/0-opt.wgsl.expected.glsl
@@ -0,0 +1,102 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_unpack4x8unorm(uint param_0) {
+ uint j = param_0;
+ uint4 i = uint4(j & 0xff, (j >> 8) & 0xff, (j >> 16) & 0xff, j >> 24);
+ return float4(i) / 255.0;
+}
+
+
+struct tint_padded_array_element {
+ uint el;
+};
+struct buf0 {
+ tint_padded_array_element x_GLF_uniform_uint_values[1];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+};
+struct tint_padded_array_element_2 {
+ float el;
+};
+struct buf2 {
+ tint_padded_array_element_2 x_GLF_uniform_float_values[3];
+};
+
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element x_GLF_uniform_uint_values[1];
+} x_6;
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[2];
+} x_8;
+layout (binding = 2) uniform buf2_1 {
+ tint_padded_array_element_2 x_GLF_uniform_float_values[3];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec4 v = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ uint x_39 = x_6.x_GLF_uniform_uint_values[0].el;
+ uint x_41 = x_6.x_GLF_uniform_uint_values[0].el;
+ v = tint_unpack4x8unorm((x_39 / (true ? 92382u : x_41)));
+ vec4 x_45 = v;
+ int x_47 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_50 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_53 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_56 = x_10.x_GLF_uniform_float_values[1].el;
+ float x_58 = x_10.x_GLF_uniform_float_values[2].el;
+ float x_63 = x_10.x_GLF_uniform_float_values[0].el;
+ if ((distance(x_45, vec4(float(x_47), float(x_50), float(x_53), (x_56 / x_58))) < x_63)) {
+ int x_69 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_72 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_75 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_78 = x_8.x_GLF_uniform_int_values[1].el;
+ x_GLF_color = vec4(float(x_69), float(x_72), float(x_75), float(x_78));
+ } else {
+ int x_82 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_83 = float(x_82);
+ x_GLF_color = vec4(x_83, x_83, x_83, x_83);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:6: 'uint4' : undeclared identifier
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-unused-access-past-matrix-elements/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-unused-access-past-matrix-elements/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..4e1a680
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-unused-access-past-matrix-elements/0-opt.spvasm.expected.glsl
@@ -0,0 +1,128 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[3];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[3];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat4x3 m43 = mat4x3(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ tint_padded_array_element sums[3] = tint_padded_array_element[3](tint_padded_array_element(0.0f), tint_padded_array_element(0.0f), tint_padded_array_element(0.0f));
+ int i = 0;
+ int a = 0;
+ int x_67_phi = 0;
+ float x_44 = x_6.x_GLF_uniform_float_values[1].el;
+ vec3 x_48 = vec3(0.0f, 0.0f, 0.0f);
+ m43 = mat4x3(vec3(x_44, 0.0f, 0.0f), vec3(0.0f, x_44, 0.0f), vec3(0.0f, 0.0f, x_44), vec3(0.0f, 0.0f, 0.0f));
+ int x_51 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_53 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_55 = x_6.x_GLF_uniform_float_values[0].el;
+ m43[x_51][x_53] = x_55;
+ float x_58 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_60 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_62 = x_6.x_GLF_uniform_float_values[0].el;
+ tint_padded_array_element tint_symbol_2[3] = tint_padded_array_element[3](tint_padded_array_element(x_58), tint_padded_array_element(x_60), tint_padded_array_element(x_62));
+ sums = tint_symbol_2;
+ int x_65 = x_8.x_GLF_uniform_int_values[0].el;
+ i = x_65;
+ x_67_phi = x_65;
+ while (true) {
+ int x_67 = x_67_phi;
+ int x_73 = x_8.x_GLF_uniform_int_values[3].el;
+ if ((x_67 < x_73)) {
+ } else {
+ break;
+ }
+ int x_77 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_79 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_81 = m43[x_67][x_79];
+ float x_83 = sums[x_77].el;
+ sums[x_77].el = (x_83 + x_81);
+ {
+ int x_68 = (x_67 + 1);
+ i = x_68;
+ x_67_phi = x_68;
+ }
+ }
+ int x_87 = x_8.x_GLF_uniform_int_values[1].el;
+ if ((x_87 == 1)) {
+ a = 4;
+ int x_92 = x_8.x_GLF_uniform_int_values[2].el;
+ int x_94 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_96 = m43[4][x_94];
+ float x_98 = sums[x_92].el;
+ sums[x_92].el = (x_98 + x_96);
+ }
+ int x_102 = x_8.x_GLF_uniform_int_values[1].el;
+ float x_104 = sums[x_102].el;
+ int x_106 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_108 = sums[x_106].el;
+ float x_111 = x_6.x_GLF_uniform_float_values[2].el;
+ if (((x_104 + x_108) == x_111)) {
+ int x_117 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_120 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_123 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_126 = x_8.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_117), float(x_120), float(x_123), float(x_126));
+ } else {
+ int x_130 = x_8.x_GLF_uniform_int_values[1].el;
+ float x_131 = float(x_130);
+ x_GLF_color = vec4(x_131, x_131, x_131, x_131);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_3 = main_out(x_GLF_color);
+ return tint_symbol_3;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:69: '[' : matrix index out of range '4'
+ERROR: 0:69: '=' : cannot convert from ' temp mediump 3-component vector of float' to ' temp mediump float'
+ERROR: 0:69: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-unused-access-past-matrix-elements/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-unused-access-past-matrix-elements/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..4e1a680
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-unused-access-past-matrix-elements/0-opt.wgsl.expected.glsl
@@ -0,0 +1,128 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[3];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[3];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[4];
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat4x3 m43 = mat4x3(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ tint_padded_array_element sums[3] = tint_padded_array_element[3](tint_padded_array_element(0.0f), tint_padded_array_element(0.0f), tint_padded_array_element(0.0f));
+ int i = 0;
+ int a = 0;
+ int x_67_phi = 0;
+ float x_44 = x_6.x_GLF_uniform_float_values[1].el;
+ vec3 x_48 = vec3(0.0f, 0.0f, 0.0f);
+ m43 = mat4x3(vec3(x_44, 0.0f, 0.0f), vec3(0.0f, x_44, 0.0f), vec3(0.0f, 0.0f, x_44), vec3(0.0f, 0.0f, 0.0f));
+ int x_51 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_53 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_55 = x_6.x_GLF_uniform_float_values[0].el;
+ m43[x_51][x_53] = x_55;
+ float x_58 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_60 = x_6.x_GLF_uniform_float_values[0].el;
+ float x_62 = x_6.x_GLF_uniform_float_values[0].el;
+ tint_padded_array_element tint_symbol_2[3] = tint_padded_array_element[3](tint_padded_array_element(x_58), tint_padded_array_element(x_60), tint_padded_array_element(x_62));
+ sums = tint_symbol_2;
+ int x_65 = x_8.x_GLF_uniform_int_values[0].el;
+ i = x_65;
+ x_67_phi = x_65;
+ while (true) {
+ int x_67 = x_67_phi;
+ int x_73 = x_8.x_GLF_uniform_int_values[3].el;
+ if ((x_67 < x_73)) {
+ } else {
+ break;
+ }
+ int x_77 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_79 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_81 = m43[x_67][x_79];
+ float x_83 = sums[x_77].el;
+ sums[x_77].el = (x_83 + x_81);
+ {
+ int x_68 = (x_67 + 1);
+ i = x_68;
+ x_67_phi = x_68;
+ }
+ }
+ int x_87 = x_8.x_GLF_uniform_int_values[1].el;
+ if ((x_87 == 1)) {
+ a = 4;
+ int x_92 = x_8.x_GLF_uniform_int_values[2].el;
+ int x_94 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_96 = m43[4][x_94];
+ float x_98 = sums[x_92].el;
+ sums[x_92].el = (x_98 + x_96);
+ }
+ int x_102 = x_8.x_GLF_uniform_int_values[1].el;
+ float x_104 = sums[x_102].el;
+ int x_106 = x_8.x_GLF_uniform_int_values[0].el;
+ float x_108 = sums[x_106].el;
+ float x_111 = x_6.x_GLF_uniform_float_values[2].el;
+ if (((x_104 + x_108) == x_111)) {
+ int x_117 = x_8.x_GLF_uniform_int_values[0].el;
+ int x_120 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_123 = x_8.x_GLF_uniform_int_values[1].el;
+ int x_126 = x_8.x_GLF_uniform_int_values[0].el;
+ x_GLF_color = vec4(float(x_117), float(x_120), float(x_123), float(x_126));
+ } else {
+ int x_130 = x_8.x_GLF_uniform_int_values[1].el;
+ float x_131 = float(x_130);
+ x_GLF_color = vec4(x_131, x_131, x_131, x_131);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_3 = main_out(x_GLF_color);
+ return tint_symbol_3;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:69: '[' : matrix index out of range '4'
+ERROR: 0:69: '=' : cannot convert from ' temp mediump 3-component vector of float' to ' temp mediump float'
+ERROR: 0:69: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-unused-matrix-copy-inside-loop/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-unused-matrix-copy-inside-loop/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..3a914ca
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-unused-matrix-copy-inside-loop/0-opt.spvasm.expected.glsl
@@ -0,0 +1,123 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ int el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+};
+struct tint_padded_array_element_1 {
+ float el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[1];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_int_values[4];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_float_values[1];
+} x_10;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat4 m0 = mat4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ int c = 0;
+ mat4 m1 = mat4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ int x_40 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_41 = float(x_40);
+ m0 = mat4(vec4(x_41, 0.0f, 0.0f, 0.0f), vec4(0.0f, x_41, 0.0f, 0.0f), vec4(0.0f, 0.0f, x_41, 0.0f), vec4(0.0f, 0.0f, 0.0f, x_41));
+ int x_48 = x_6.x_GLF_uniform_int_values[2].el;
+ c = x_48;
+ while (true) {
+ int x_53 = c;
+ int x_55 = x_6.x_GLF_uniform_int_values[0].el;
+ if ((x_53 < x_55)) {
+ } else {
+ break;
+ }
+ m1 = m0;
+ int x_59 = c;
+ int x_61 = x_6.x_GLF_uniform_int_values[3].el;
+ int x_64 = x_6.x_GLF_uniform_int_values[2].el;
+ float x_66 = x_10.x_GLF_uniform_float_values[0].el;
+ m1[(x_59 % x_61)][x_64] = x_66;
+ int x_68 = c;
+ int x_70 = x_6.x_GLF_uniform_int_values[3].el;
+ int x_73 = x_6.x_GLF_uniform_int_values[2].el;
+ float x_75 = x_10.x_GLF_uniform_float_values[0].el;
+ m0[(x_68 % x_70)][x_73] = x_75;
+ {
+ c = (c + 1);
+ }
+ }
+ mat4 x_79 = m0;
+ int x_81 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_84 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_87 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_90 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_93 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_96 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_99 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_102 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_105 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_108 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_111 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_114 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_117 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_120 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_123 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_126 = x_6.x_GLF_uniform_int_values[1].el;
+ mat4 x_132 = mat4(vec4(float(x_81), float(x_84), float(x_87), float(x_90)), vec4(float(x_93), float(x_96), float(x_99), float(x_102)), vec4(float(x_105), float(x_108), float(x_111), float(x_114)), vec4(float(x_117), float(x_120), float(x_123), float(x_126)));
+ if ((((all(equal(x_79[0u], x_132[0u])) & all(equal(x_79[1u], x_132[1u]))) & all(equal(x_79[2u], x_132[2u]))) & all(equal(x_79[3u], x_132[3u])))) {
+ int x_156 = x_6.x_GLF_uniform_int_values[2].el;
+ int x_159 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_162 = x_6.x_GLF_uniform_int_values[1].el;
+ int x_165 = x_6.x_GLF_uniform_int_values[2].el;
+ x_GLF_color = vec4(float(x_156), float(x_159), float(x_162), float(x_165));
+ } else {
+ int x_169 = x_6.x_GLF_uniform_int_values[1].el;
+ float x_170 = float(x_169);
+ x_GLF_color = vec4(x_170, x_170, x_170, x_170);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:74: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' global bool' and a right operand of type ' global bool' (or there is no acceptable conversion)
+ERROR: 0:74: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-vector-dce-unused-component/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-vector-dce-unused-component/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..57b760a
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-vector-dce-unused-component/0-opt.spvasm.expected.glsl
@@ -0,0 +1,58 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec2 a = vec2(0.0f, 0.0f);
+ vec2 b = vec2(0.0f, 0.0f);
+ a = vec2(1.0f, 1.0f);
+ float x_25 = a.x;
+ a.x = (x_25 + 0.5f);
+ b = frac(a);
+ float x_31 = b.x;
+ if ((x_31 == 0.5f)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:12: 'frac' : no matching overloaded function found
+ERROR: 0:12: 'assign' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:12: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-vector-dce-unused-component/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-vector-dce-unused-component/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..57b760a
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-vector-dce-unused-component/0-opt.wgsl.expected.glsl
@@ -0,0 +1,58 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ vec2 a = vec2(0.0f, 0.0f);
+ vec2 b = vec2(0.0f, 0.0f);
+ a = vec2(1.0f, 1.0f);
+ float x_25 = a.x;
+ a.x = (x_25 + 0.5f);
+ b = frac(a);
+ float x_31 = b.x;
+ if ((x_31 == 0.5f)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:12: 'frac' : no matching overloaded function found
+ERROR: 0:12: 'assign' : cannot convert from ' const float' to ' temp mediump 2-component vector of float'
+ERROR: 0:12: '' : compilation terminated
+ERROR: 3 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-write-past-matrix-elements-unused/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-write-past-matrix-elements-unused/0.spvasm.expected.glsl
new file mode 100644
index 0000000..e552f1d
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-write-past-matrix-elements-unused/0.spvasm.expected.glsl
@@ -0,0 +1,98 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat3x2 m32 = mat3x2(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ float sums[3] = float[3](0.0f, 0.0f, 0.0f);
+ int x_52_phi = 0;
+ float x_40 = x_6.x_GLF_uniform_float_values[0].el;
+ m32 = mat3x2(vec2(x_40, 0.0f), vec2(0.0f, x_40), vec2(0.0f, 0.0f));
+ int x_45 = x_8.x_GLF_uniform_int_values[0].el;
+ if ((x_45 == 1)) {
+ m32[3][x_45] = x_40;
+ }
+ float tint_symbol_2[3] = float[3](x_40, x_40, x_40);
+ sums = tint_symbol_2;
+ x_52_phi = x_45;
+ while (true) {
+ int x_53 = 0;
+ int x_52 = x_52_phi;
+ int x_56 = x_8.x_GLF_uniform_int_values[2].el;
+ if ((x_52 < x_56)) {
+ } else {
+ break;
+ }
+ {
+ float x_60 = m32[x_52][x_45];
+ int x_61_save = x_56;
+ float x_62 = sums[x_61_save];
+ sums[x_61_save] = (x_62 + x_60);
+ x_53 = (x_52 + 1);
+ x_52_phi = x_53;
+ }
+ }
+ float x_65 = sums[x_45];
+ float x_67 = x_6.x_GLF_uniform_float_values[1].el;
+ int x_69 = x_8.x_GLF_uniform_int_values[1].el;
+ float x_71 = sums[x_69];
+ x_GLF_color = vec4(x_65, x_67, x_67, x_71);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_3 = main_out(x_GLF_color);
+ return tint_symbol_3;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: '[' : matrix index out of range '3'
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/cov-write-past-matrix-elements-unused/0.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/cov-write-past-matrix-elements-unused/0.wgsl.expected.glsl
new file mode 100644
index 0000000..e552f1d
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/cov-write-past-matrix-elements-unused/0.wgsl.expected.glsl
@@ -0,0 +1,98 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct tint_padded_array_element {
+ float el;
+};
+struct buf1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+};
+struct tint_padded_array_element_1 {
+ int el;
+};
+struct buf0 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+};
+
+layout (binding = 1) uniform buf1_1 {
+ tint_padded_array_element x_GLF_uniform_float_values[2];
+} x_6;
+layout (binding = 0) uniform buf0_1 {
+ tint_padded_array_element_1 x_GLF_uniform_int_values[3];
+} x_8;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat3x2 m32 = mat3x2(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ float sums[3] = float[3](0.0f, 0.0f, 0.0f);
+ int x_52_phi = 0;
+ float x_40 = x_6.x_GLF_uniform_float_values[0].el;
+ m32 = mat3x2(vec2(x_40, 0.0f), vec2(0.0f, x_40), vec2(0.0f, 0.0f));
+ int x_45 = x_8.x_GLF_uniform_int_values[0].el;
+ if ((x_45 == 1)) {
+ m32[3][x_45] = x_40;
+ }
+ float tint_symbol_2[3] = float[3](x_40, x_40, x_40);
+ sums = tint_symbol_2;
+ x_52_phi = x_45;
+ while (true) {
+ int x_53 = 0;
+ int x_52 = x_52_phi;
+ int x_56 = x_8.x_GLF_uniform_int_values[2].el;
+ if ((x_52 < x_56)) {
+ } else {
+ break;
+ }
+ {
+ float x_60 = m32[x_52][x_45];
+ int x_61_save = x_56;
+ float x_62 = sums[x_61_save];
+ sums[x_61_save] = (x_62 + x_60);
+ x_53 = (x_52 + 1);
+ x_52_phi = x_53;
+ }
+ }
+ float x_65 = sums[x_45];
+ float x_67 = x_6.x_GLF_uniform_float_values[1].el;
+ int x_69 = x_8.x_GLF_uniform_int_values[1].el;
+ float x_71 = sums[x_69];
+ x_GLF_color = vec4(x_65, x_67, x_67, x_71);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_3 = main_out(x_GLF_color);
+ return tint_symbol_3;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:33: '[' : matrix index out of range '3'
+ERROR: 0:33: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/loop-dead-if-loop/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/loop-dead-if-loop/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..6fb4a0e
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/loop-dead-if-loop/0-opt.spvasm.expected.glsl
@@ -0,0 +1,93 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int k = 0;
+ int GLF_dead0j = 0;
+ int donor_replacementGLF_dead0stack[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+ int donor_replacementGLF_dead0top = 0;
+ int x_54 = 0;
+ vec4 matrix_b = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ int b = 0;
+ k = 0;
+ {
+ for(; (k < 4); k = (k + 1)) {
+ float x_62 = x_6.injectionSwitch.y;
+ if ((0.0f > x_62)) {
+ GLF_dead0j = 1;
+ while (true) {
+ int x_13 = donor_replacementGLF_dead0stack[0];
+ if ((1 <= x_13)) {
+ } else {
+ break;
+ }
+ }
+ if (((donor_replacementGLF_dead0top >= 0) & (donor_replacementGLF_dead0top < 9))) {
+ int x_17 = (donor_replacementGLF_dead0top + 1);
+ donor_replacementGLF_dead0top = x_17;
+ x_54 = x_17;
+ } else {
+ x_54 = 0;
+ }
+ donor_replacementGLF_dead0stack[x_54] = 1;
+ }
+ matrix_b = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ b = 3;
+ {
+ for(; (b >= 0); b = (b - 1)) {
+ int x_20 = b;
+ float x_87 = matrix_b[b];
+ matrix_b[x_20] = (x_87 - 1.0f);
+ }
+ }
+ }
+ }
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:34: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:34: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/nested-loops-switch/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/nested-loops-switch/0.spvasm.expected.glsl
new file mode 100644
index 0000000..623f7f4
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/nested-loops-switch/0.spvasm.expected.glsl
@@ -0,0 +1,111 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_6;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int i = 0;
+ int GLF_dead5cols = 0;
+ int GLF_dead5rows = 0;
+ int GLF_dead5c = 0;
+ int GLF_dead5r = 0;
+ int msb10 = 0;
+ float donor_replacementGLF_dead5sums[9] = float[9](0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ i = 0;
+ while (true) {
+ int x_45 = i;
+ float x_47 = x_6.injectionSwitch.x;
+ if ((x_45 >= int(x_47))) {
+ break;
+ }
+ float x_53 = x_6.injectionSwitch.y;
+ if ((0.0f > x_53)) {
+ GLF_dead5cols = 2;
+ {
+ for(; (GLF_dead5cols <= 4); GLF_dead5cols = (GLF_dead5cols + 1)) {
+ GLF_dead5rows = 2;
+ {
+ for(; (GLF_dead5rows <= 4); GLF_dead5rows = (GLF_dead5rows + 1)) {
+ GLF_dead5c = 0;
+ {
+ for(; (GLF_dead5c < GLF_dead5cols); GLF_dead5c = (GLF_dead5c + 1)) {
+ GLF_dead5r = 0;
+ {
+ for(; (GLF_dead5r < GLF_dead5rows); GLF_dead5r = (GLF_dead5r + 1)) {
+ switch(msb10) {
+ case 1:
+ case 8: {
+ int x_96 = (((msb10 >= 0) & (msb10 < 9)) ? msb10 : 0);
+ float x_98 = donor_replacementGLF_dead5sums[x_96];
+ donor_replacementGLF_dead5sums[x_96] = (x_98 + 1.0f);
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ }
+ }
+ }
+ }
+ msb10 = (msb10 + 1);
+ }
+ }
+ }
+ }
+ }
+ i = (i + 1);
+ {
+ if ((i < 200)) {
+ } else {
+ break;
+ }
+ }
+ }
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:45: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:45: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-double-branch-to-same-block/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-double-branch-to-same-block/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..e8123dc
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-double-branch-to-same-block/0-opt.spvasm.expected.glsl
@@ -0,0 +1,294 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+struct buf1 {
+ vec2 resolution;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_28;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_254 = from;
+ k = x_254;
+ int x_255 = from;
+ i = x_255;
+ int x_256 = mid;
+ j = (x_256 + 1);
+ while (true) {
+ int x_262 = i;
+ int x_263 = mid;
+ int x_265 = j;
+ int x_266 = to;
+ if (((x_262 <= x_263) & (x_265 <= x_266))) {
+ } else {
+ break;
+ }
+ int x_272 = data[i];
+ int x_275 = data[j];
+ if ((x_272 < x_275)) {
+ int x_280 = k;
+ k = (x_280 + 1);
+ int x_282 = i;
+ i = (x_282 + 1);
+ int x_285 = data[x_282];
+ temp[x_280] = x_285;
+ } else {
+ int x_287 = k;
+ k = (x_287 + 1);
+ int x_289 = j;
+ j = (x_289 + 1);
+ int x_292 = data[x_289];
+ temp[x_287] = x_292;
+ }
+ }
+ while (true) {
+ int x_298 = i;
+ int x_300 = i;
+ int x_301 = mid;
+ if (((x_298 < 10) & (x_300 <= x_301))) {
+ } else {
+ break;
+ }
+ int x_305 = k;
+ k = (x_305 + 1);
+ int x_307 = i;
+ i = (x_307 + 1);
+ int x_310 = data[x_307];
+ temp[x_305] = x_310;
+ }
+ int x_312 = from;
+ i_1 = x_312;
+ while (true) {
+ int x_317 = i_1;
+ int x_318 = to;
+ if ((x_317 <= x_318)) {
+ } else {
+ break;
+ }
+ int x_321 = i_1;
+ int x_324 = temp[i_1];
+ data[x_321] = x_324;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+void mergeSort_() {
+ int low = 0;
+ int high = 0;
+ int m = 0;
+ int i_2 = 0;
+ int from_1 = 0;
+ int mid_1 = 0;
+ int to_1 = 0;
+ int param = 0;
+ int param_1 = 0;
+ int param_2 = 0;
+ low = 0;
+ high = 9;
+ m = 1;
+ {
+ for(; (m <= high); m = (2 * m)) {
+ i_2 = low;
+ {
+ for(; (i_2 < high); i_2 = (i_2 + (2 * m))) {
+ from_1 = i_2;
+ mid_1 = ((i_2 + m) - 1);
+ to_1 = min(((i_2 + (2 * m)) - 1), high);
+ param = from_1;
+ param_1 = mid_1;
+ param_2 = to_1;
+ merge_i1_i1_i1_(param, param_1, param_2);
+ }
+ }
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ float x_87 = x_28.injectionSwitch.x;
+ i_3 = int(x_87);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ {
+ for(; (j_1 < 10); j_1 = (j_1 + 1)) {
+ int x_136 = j_1;
+ int x_139 = data[j_1];
+ temp[x_136] = x_139;
+ }
+ }
+ mergeSort_();
+ float x_145 = tint_symbol.y;
+ if ((int(x_145) < 30)) {
+ int x_152 = data[0];
+ grey = (0.5f + (float(x_152) / 10.0f));
+ } else {
+ float x_157 = tint_symbol.y;
+ if ((int(x_157) < 60)) {
+ int x_164 = data[1];
+ grey = (0.5f + (float(x_164) / 10.0f));
+ } else {
+ float x_169 = tint_symbol.y;
+ if ((int(x_169) < 90)) {
+ int x_176 = data[2];
+ grey = (0.5f + (float(x_176) / 10.0f));
+ } else {
+ float x_181 = tint_symbol.y;
+ if ((int(x_181) < 120)) {
+ int x_188 = data[3];
+ grey = (0.5f + (float(x_188) / 10.0f));
+ } else {
+ float x_193 = tint_symbol.y;
+ if ((int(x_193) < 150)) {
+ discard;
+ } else {
+ float x_200 = tint_symbol.y;
+ if ((int(x_200) < 180)) {
+ int x_207 = data[5];
+ grey = (0.5f + (float(x_207) / 10.0f));
+ } else {
+ float x_212 = tint_symbol.y;
+ if ((int(x_212) < 210)) {
+ int x_219 = data[6];
+ grey = (0.5f + (float(x_219) / 10.0f));
+ } else {
+ float x_224 = tint_symbol.y;
+ if ((int(x_224) < 240)) {
+ int x_231 = data[7];
+ grey = (0.5f + (float(x_231) / 10.0f));
+ } else {
+ float x_236 = tint_symbol.y;
+ if ((int(x_236) < 270)) {
+ int x_243 = data[8];
+ grey = (0.5f + (float(x_243) / 10.0f));
+ } else {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_247 = grey;
+ vec3 x_248 = vec3(x_247, x_247, x_247);
+ x_GLF_color = vec4(x_248.x, x_248.y, x_248.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:35: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:35: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-double-branch-to-same-block/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-double-branch-to-same-block/1.spvasm.expected.glsl
new file mode 100644
index 0000000..01f526e
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-double-branch-to-same-block/1.spvasm.expected.glsl
@@ -0,0 +1,304 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+struct buf1 {
+ vec2 resolution;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_28;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_255 = from;
+ k = x_255;
+ int x_256 = from;
+ i = x_256;
+ int x_257 = mid;
+ j = (x_257 + 1);
+ while (true) {
+ int x_263 = i;
+ int x_264 = mid;
+ int x_266 = j;
+ int x_267 = to;
+ if (((x_263 <= x_264) & (x_266 <= x_267))) {
+ } else {
+ break;
+ }
+ int x_273 = data[i];
+ int x_276 = data[j];
+ if ((x_273 < x_276)) {
+ int x_281 = k;
+ k = (x_281 + 1);
+ int x_283 = i;
+ i = (x_283 + 1);
+ int x_286 = data[x_283];
+ temp[x_281] = x_286;
+ } else {
+ int x_288 = k;
+ k = (x_288 + 1);
+ int x_290 = j;
+ j = (x_290 + 1);
+ int x_293 = data[x_290];
+ temp[x_288] = x_293;
+ }
+ }
+ while (true) {
+ int x_299 = i;
+ int x_301 = i;
+ int x_302 = mid;
+ if (((x_299 < 10) & (x_301 <= x_302))) {
+ } else {
+ break;
+ }
+ int x_306 = k;
+ k = (x_306 + 1);
+ int x_308 = i;
+ i = (x_308 + 1);
+ int x_311 = data[x_308];
+ temp[x_306] = x_311;
+ }
+ int x_313 = from;
+ i_1 = x_313;
+ while (true) {
+ int x_318 = i_1;
+ int x_319 = to;
+ if ((x_318 <= x_319)) {
+ } else {
+ break;
+ }
+ int x_322 = i_1;
+ int x_325 = temp[i_1];
+ data[x_322] = x_325;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+void mergeSort_() {
+ int low = 0;
+ int high = 0;
+ int m = 0;
+ int i_2 = 0;
+ int from_1 = 0;
+ int mid_1 = 0;
+ int to_1 = 0;
+ int param = 0;
+ int param_1 = 0;
+ int param_2 = 0;
+ low = 0;
+ high = 9;
+ m = 1;
+ {
+ for(; (m <= high); m = (2 * m)) {
+ i_2 = low;
+ {
+ for(; (i_2 < high); i_2 = (i_2 + (2 * m))) {
+ from_1 = i_2;
+ mid_1 = ((i_2 + m) - 1);
+ to_1 = min(((i_2 + (2 * m)) - 1), high);
+ param = from_1;
+ param_1 = mid_1;
+ param_2 = to_1;
+ merge_i1_i1_i1_(param, param_1, param_2);
+ }
+ }
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ float x_88 = x_28.injectionSwitch.x;
+ i_3 = int(x_88);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ if (true) {
+ } else {
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ continue;
+ }
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ {
+ for(; (j_1 < 10); j_1 = (j_1 + 1)) {
+ int x_137 = j_1;
+ int x_140 = data[j_1];
+ temp[x_137] = x_140;
+ }
+ }
+ mergeSort_();
+ float x_146 = tint_symbol.y;
+ if ((int(x_146) < 30)) {
+ int x_153 = data[0];
+ grey = (0.5f + (float(x_153) / 10.0f));
+ } else {
+ float x_158 = tint_symbol.y;
+ if ((int(x_158) < 60)) {
+ int x_165 = data[1];
+ grey = (0.5f + (float(x_165) / 10.0f));
+ } else {
+ float x_170 = tint_symbol.y;
+ if ((int(x_170) < 90)) {
+ int x_177 = data[2];
+ grey = (0.5f + (float(x_177) / 10.0f));
+ } else {
+ float x_182 = tint_symbol.y;
+ if ((int(x_182) < 120)) {
+ int x_189 = data[3];
+ grey = (0.5f + (float(x_189) / 10.0f));
+ } else {
+ float x_194 = tint_symbol.y;
+ if ((int(x_194) < 150)) {
+ discard;
+ } else {
+ float x_201 = tint_symbol.y;
+ if ((int(x_201) < 180)) {
+ int x_208 = data[5];
+ grey = (0.5f + (float(x_208) / 10.0f));
+ } else {
+ float x_213 = tint_symbol.y;
+ if ((int(x_213) < 210)) {
+ int x_220 = data[6];
+ grey = (0.5f + (float(x_220) / 10.0f));
+ } else {
+ float x_225 = tint_symbol.y;
+ if ((int(x_225) < 240)) {
+ int x_232 = data[7];
+ grey = (0.5f + (float(x_232) / 10.0f));
+ } else {
+ float x_237 = tint_symbol.y;
+ if ((int(x_237) < 270)) {
+ int x_244 = data[8];
+ grey = (0.5f + (float(x_244) / 10.0f));
+ } else {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_248 = grey;
+ vec3 x_249 = vec3(x_248, x_248, x_248);
+ x_GLF_color = vec4(x_249.x, x_249.y, x_249.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:35: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:35: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-double-branch-to-same-block3/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-double-branch-to-same-block3/1.spvasm.expected.glsl
new file mode 100644
index 0000000..1bffc88
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-double-branch-to-same-block3/1.spvasm.expected.glsl
@@ -0,0 +1,298 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+struct buf1 {
+ vec2 resolution;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_28;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_256 = from;
+ k = x_256;
+ int x_257 = from;
+ i = x_257;
+ int x_258 = mid;
+ j = (x_258 + 1);
+ while (true) {
+ int x_264 = i;
+ int x_265 = mid;
+ int x_267 = j;
+ int x_268 = to;
+ if (((x_264 <= x_265) & (x_267 <= x_268))) {
+ } else {
+ break;
+ }
+ int x_274 = data[i];
+ int x_277 = data[j];
+ if ((x_274 < x_277)) {
+ int x_282 = k;
+ k = (x_282 + 1);
+ int x_284 = i;
+ i = (x_284 + 1);
+ int x_287 = data[x_284];
+ temp[x_282] = x_287;
+ } else {
+ int x_289 = k;
+ k = (x_289 + 1);
+ int x_291 = j;
+ j = (x_291 + 1);
+ int x_294 = data[x_291];
+ temp[x_289] = x_294;
+ }
+ }
+ while (true) {
+ if (!((256.0f < 1.0f))) {
+ } else {
+ continue;
+ }
+ int x_301 = i;
+ int x_303 = i;
+ int x_304 = mid;
+ if (((x_301 < 10) & (x_303 <= x_304))) {
+ } else {
+ break;
+ }
+ int x_309 = k;
+ k = (x_309 + 1);
+ int x_311 = i;
+ i = (x_311 + 1);
+ int x_314 = data[x_311];
+ temp[x_309] = x_314;
+ }
+ int x_316 = from;
+ i_1 = x_316;
+ while (true) {
+ int x_321 = i_1;
+ int x_322 = to;
+ if ((x_321 <= x_322)) {
+ } else {
+ break;
+ }
+ int x_325 = i_1;
+ int x_328 = temp[i_1];
+ data[x_325] = x_328;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+void mergeSort_() {
+ int low = 0;
+ int high = 0;
+ int m = 0;
+ int i_2 = 0;
+ int from_1 = 0;
+ int mid_1 = 0;
+ int to_1 = 0;
+ int param = 0;
+ int param_1 = 0;
+ int param_2 = 0;
+ low = 0;
+ high = 9;
+ m = 1;
+ {
+ for(; (m <= high); m = (2 * m)) {
+ i_2 = low;
+ {
+ for(; (i_2 < high); i_2 = (i_2 + (2 * m))) {
+ from_1 = i_2;
+ mid_1 = ((i_2 + m) - 1);
+ to_1 = min(((i_2 + (2 * m)) - 1), high);
+ param = from_1;
+ param_1 = mid_1;
+ param_2 = to_1;
+ merge_i1_i1_i1_(param, param_1, param_2);
+ }
+ }
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ float x_89 = x_28.injectionSwitch.x;
+ i_3 = int(x_89);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ {
+ for(; (j_1 < 10); j_1 = (j_1 + 1)) {
+ int x_138 = j_1;
+ int x_141 = data[j_1];
+ temp[x_138] = x_141;
+ }
+ }
+ mergeSort_();
+ float x_147 = tint_symbol.y;
+ if ((int(x_147) < 30)) {
+ int x_154 = data[0];
+ grey = (0.5f + (float(x_154) / 10.0f));
+ } else {
+ float x_159 = tint_symbol.y;
+ if ((int(x_159) < 60)) {
+ int x_166 = data[1];
+ grey = (0.5f + (float(x_166) / 10.0f));
+ } else {
+ float x_171 = tint_symbol.y;
+ if ((int(x_171) < 90)) {
+ int x_178 = data[2];
+ grey = (0.5f + (float(x_178) / 10.0f));
+ } else {
+ float x_183 = tint_symbol.y;
+ if ((int(x_183) < 120)) {
+ int x_190 = data[3];
+ grey = (0.5f + (float(x_190) / 10.0f));
+ } else {
+ float x_195 = tint_symbol.y;
+ if ((int(x_195) < 150)) {
+ discard;
+ } else {
+ float x_202 = tint_symbol.y;
+ if ((int(x_202) < 180)) {
+ int x_209 = data[5];
+ grey = (0.5f + (float(x_209) / 10.0f));
+ } else {
+ float x_214 = tint_symbol.y;
+ if ((int(x_214) < 210)) {
+ int x_221 = data[6];
+ grey = (0.5f + (float(x_221) / 10.0f));
+ } else {
+ float x_226 = tint_symbol.y;
+ if ((int(x_226) < 240)) {
+ int x_233 = data[7];
+ grey = (0.5f + (float(x_233) / 10.0f));
+ } else {
+ float x_238 = tint_symbol.y;
+ if ((int(x_238) < 270)) {
+ int x_245 = data[8];
+ grey = (0.5f + (float(x_245) / 10.0f));
+ } else {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_249 = grey;
+ vec3 x_250 = vec3(x_249, x_249, x_249);
+ x_GLF_color = vec4(x_250.x, x_250.y, x_250.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:35: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:35: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-O-prop-up-mutate-var/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-O-prop-up-mutate-var/1.spvasm.expected.glsl
new file mode 100644
index 0000000..0c4cf31
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-O-prop-up-mutate-var/1.spvasm.expected.glsl
@@ -0,0 +1,379 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_8;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+ int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+ float x_190 = 0.0f;
+ float x_262 = 0.0f;
+ int x_63_phi = 0;
+ int x_103_phi = 0;
+ int x_112_phi = 0;
+ float x_263_phi = 0.0f;
+ float x_60 = x_8.injectionSwitch.x;
+ int x_61 = int(x_60);
+ x_63_phi = x_61;
+ while (true) {
+ int x_100 = 0;
+ int x_98 = 0;
+ int x_96 = 0;
+ int x_94 = 0;
+ int x_92 = 0;
+ int x_90 = 0;
+ int x_88 = 0;
+ int x_86 = 0;
+ int x_84 = 0;
+ int x_82 = 0;
+ int x_64_phi = 0;
+ int x_63 = x_63_phi;
+ int x_68[10] = data;
+ int tint_symbol_6[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+ data = tint_symbol_6;
+ data = x_68;
+ int x_69 = (x_63 + 1);
+ x_64_phi = x_69;
+ switch(x_63) {
+ case 9: {
+ data[x_63] = -5;
+ x_100 = (x_63 + 1);
+ x_64_phi = x_100;
+ break;
+ }
+ case 8: {
+ data[x_63] = -4;
+ x_98 = (x_63 + 1);
+ x_64_phi = x_98;
+ break;
+ }
+ case 7: {
+ data[x_63] = -3;
+ x_96 = (x_63 + 1);
+ x_64_phi = x_96;
+ break;
+ }
+ case 6: {
+ data[x_63] = -2;
+ x_94 = (x_63 + 1);
+ x_64_phi = x_94;
+ break;
+ }
+ case 5: {
+ data[x_63] = -1;
+ x_92 = (x_63 + 1);
+ x_64_phi = x_92;
+ break;
+ }
+ case 4: {
+ data[x_63] = 0;
+ x_90 = (x_63 + 1);
+ x_64_phi = x_90;
+ break;
+ }
+ case 3: {
+ data[x_63] = 1;
+ x_88 = (x_63 + 1);
+ x_64_phi = x_88;
+ break;
+ }
+ case 2: {
+ data[x_63] = 2;
+ x_86 = (x_63 + 1);
+ x_64_phi = x_86;
+ break;
+ }
+ case 1: {
+ data[x_63] = 3;
+ x_84 = (x_63 + 1);
+ x_64_phi = x_84;
+ break;
+ }
+ case 0: {
+ data[x_63] = 4;
+ x_82 = (x_63 + 1);
+ x_64_phi = x_82;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ int x_64 = x_64_phi;
+ {
+ x_63_phi = x_64;
+ if ((x_64 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ x_103_phi = 0;
+ while (true) {
+ int x_104 = 0;
+ int x_103 = x_103_phi;
+ if ((x_103 < 10)) {
+ } else {
+ break;
+ }
+ {
+ int x_109 = data[x_103];
+ temp[x_103] = x_109;
+ x_104 = (x_103 + 1);
+ x_103_phi = x_104;
+ }
+ }
+ x_112_phi = 1;
+ while (true) {
+ int x_113 = 0;
+ int x_119_phi = 0;
+ int x_112 = x_112_phi;
+ if ((x_112 <= 9)) {
+ } else {
+ break;
+ }
+ x_119_phi = 0;
+ while (true) {
+ int x_131 = 0;
+ int x_136 = 0;
+ int x_131_phi = 0;
+ int x_134_phi = 0;
+ int x_136_phi = 0;
+ int x_158_phi = 0;
+ int x_161_phi = 0;
+ int x_171_phi = 0;
+ int x_119 = x_119_phi;
+ if ((x_119 < 9)) {
+ } else {
+ break;
+ }
+ int x_125 = (x_119 + x_112);
+ int x_126 = (x_125 - 1);
+ int x_120 = (x_119 + (2 * x_112));
+ int x_129 = min((x_120 - 1), 9);
+ x_131_phi = x_119;
+ x_134_phi = x_125;
+ x_136_phi = x_119;
+ while (true) {
+ int x_151 = 0;
+ int x_154 = 0;
+ int x_135_phi = 0;
+ int x_137_phi = 0;
+ x_131 = x_131_phi;
+ int x_134 = x_134_phi;
+ x_136 = x_136_phi;
+ if (((x_136 <= x_126) & (x_134 <= x_129))) {
+ } else {
+ break;
+ }
+ int x_143_save = x_136;
+ int x_144 = data[x_143_save];
+ int x_145_save = x_134;
+ int x_146 = data[x_145_save];
+ int x_132 = (x_131 + 1);
+ if ((x_144 < x_146)) {
+ x_151 = (x_136 + 1);
+ int x_152 = data[x_143_save];
+ temp[x_131] = x_152;
+ x_135_phi = x_134;
+ x_137_phi = x_151;
+ } else {
+ x_154 = (x_134 + 1);
+ int x_155 = data[x_145_save];
+ temp[x_131] = x_155;
+ x_135_phi = x_154;
+ x_137_phi = x_136;
+ }
+ int x_135 = x_135_phi;
+ int x_137 = x_137_phi;
+ {
+ x_131_phi = x_132;
+ x_134_phi = x_135;
+ x_136_phi = x_137;
+ }
+ }
+ x_158_phi = x_131;
+ x_161_phi = x_136;
+ while (true) {
+ int x_159 = 0;
+ int x_162 = 0;
+ int x_158 = x_158_phi;
+ int x_161 = x_161_phi;
+ if (((x_161 < 10) & (x_161 <= x_126))) {
+ } else {
+ break;
+ }
+ {
+ x_159 = (x_158 + 1);
+ x_162 = (x_161 + 1);
+ int x_168 = data[x_161];
+ temp[x_158] = x_168;
+ x_158_phi = x_159;
+ x_161_phi = x_162;
+ }
+ }
+ x_171_phi = x_119;
+ while (true) {
+ int x_172 = 0;
+ int x_171 = x_171_phi;
+ if ((x_171 <= x_129)) {
+ } else {
+ break;
+ }
+ {
+ int x_177 = temp[x_171];
+ data[x_171] = x_177;
+ x_172 = (x_171 + 1);
+ x_171_phi = x_172;
+ }
+ }
+ {
+ x_119_phi = x_120;
+ }
+ }
+ {
+ x_113 = (2 * x_112);
+ x_112_phi = x_113;
+ }
+ }
+ int x_181 = 0;
+ float x_199 = 0.0f;
+ float x_261 = 0.0f;
+ float x_262_phi = 0.0f;
+ float x_180 = tint_symbol.y;
+ x_181 = int(x_180);
+ if ((x_181 < 30)) {
+ int x_187 = data[0];
+ x_190 = (0.5f + (float(x_187) * 0.100000001f));
+ x_263_phi = x_190;
+ } else {
+ float x_208 = 0.0f;
+ float x_260 = 0.0f;
+ float x_261_phi = 0.0f;
+ if ((x_181 < 60)) {
+ int x_196 = data[1];
+ x_199 = (0.5f + (float(x_196) * 0.100000001f));
+ x_262_phi = x_199;
+ } else {
+ float x_217 = 0.0f;
+ float x_259 = 0.0f;
+ float x_260_phi = 0.0f;
+ if ((x_181 < 90)) {
+ int x_205 = data[2];
+ x_208 = (0.5f + (float(x_205) * 0.100000001f));
+ x_261_phi = x_208;
+ } else {
+ if ((x_181 < 120)) {
+ int x_214 = data[3];
+ x_217 = (0.5f + (float(x_214) * 0.100000001f));
+ x_260_phi = x_217;
+ } else {
+ float x_230 = 0.0f;
+ float x_258 = 0.0f;
+ float x_259_phi = 0.0f;
+ if ((x_181 < 150)) {
+ discard;
+ } else {
+ float x_239 = 0.0f;
+ float x_257 = 0.0f;
+ float x_258_phi = 0.0f;
+ if ((x_181 < 180)) {
+ int x_227 = data[5];
+ x_230 = (0.5f + (float(x_227) * 0.100000001f));
+ x_259_phi = x_230;
+ } else {
+ float x_248 = 0.0f;
+ float x_256 = 0.0f;
+ float x_257_phi = 0.0f;
+ if ((x_181 < 210)) {
+ int x_236 = data[6];
+ x_239 = (0.5f + (float(x_236) * 0.100000001f));
+ x_258_phi = x_239;
+ } else {
+ if ((x_181 < 240)) {
+ int x_245 = data[7];
+ x_248 = (0.5f + (float(x_245) * 0.100000001f));
+ x_257_phi = x_248;
+ } else {
+ if ((x_181 < 270)) {
+ } else {
+ discard;
+ }
+ int x_253 = data[8];
+ x_256 = (0.5f + (float(x_253) * 0.100000001f));
+ x_257_phi = x_256;
+ }
+ x_257 = x_257_phi;
+ x_258_phi = x_257;
+ }
+ x_258 = x_258_phi;
+ x_259_phi = x_258;
+ }
+ x_259 = x_259_phi;
+ }
+ x_260_phi = x_259;
+ }
+ x_260 = x_260_phi;
+ x_261_phi = x_260;
+ }
+ x_261 = x_261_phi;
+ x_262_phi = x_261;
+ }
+ x_262 = x_262_phi;
+ x_263_phi = x_262;
+ }
+ float x_263 = x_263_phi;
+ x_GLF_color = vec4(x_263, x_263, x_263, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_7 = main_out(x_GLF_color);
+ return tint_symbol_7;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:173: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:173: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-O-prop-up-mutate-var/2.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-O-prop-up-mutate-var/2.spvasm.expected.glsl
new file mode 100644
index 0000000..e10289b
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-O-prop-up-mutate-var/2.spvasm.expected.glsl
@@ -0,0 +1,375 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_8;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+ int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+ float x_189 = 0.0f;
+ float x_261 = 0.0f;
+ int x_63_phi = 0;
+ int x_102_phi = 0;
+ int x_111_phi = 0;
+ float x_262_phi = 0.0f;
+ float x_60 = x_8.injectionSwitch.x;
+ int x_61 = int(x_60);
+ x_63_phi = x_61;
+ while (true) {
+ int x_99 = 0;
+ int x_97 = 0;
+ int x_95 = 0;
+ int x_93 = 0;
+ int x_91 = 0;
+ int x_89 = 0;
+ int x_87 = 0;
+ int x_85 = 0;
+ int x_83 = 0;
+ int x_81 = 0;
+ int x_64_phi = 0;
+ int x_63 = x_63_phi;
+ int x_68 = (x_63 + 1);
+ x_64_phi = x_68;
+ switch(x_63) {
+ case 9: {
+ data[x_63] = -5;
+ x_99 = (x_63 + 1);
+ x_64_phi = x_99;
+ break;
+ }
+ case 8: {
+ data[x_63] = -4;
+ x_97 = (x_63 + 1);
+ x_64_phi = x_97;
+ break;
+ }
+ case 7: {
+ data[x_63] = -3;
+ x_95 = (x_63 + 1);
+ x_64_phi = x_95;
+ break;
+ }
+ case 6: {
+ data[x_63] = -2;
+ x_93 = (x_63 + 1);
+ x_64_phi = x_93;
+ break;
+ }
+ case 5: {
+ data[x_63] = -1;
+ x_91 = (x_63 + 1);
+ x_64_phi = x_91;
+ break;
+ }
+ case 4: {
+ data[x_63] = 0;
+ x_89 = (x_63 + 1);
+ x_64_phi = x_89;
+ break;
+ }
+ case 3: {
+ data[x_63] = 1;
+ x_87 = (x_63 + 1);
+ x_64_phi = x_87;
+ break;
+ }
+ case 2: {
+ data[x_63] = 2;
+ x_85 = (x_63 + 1);
+ x_64_phi = x_85;
+ break;
+ }
+ case 1: {
+ data[x_63] = 3;
+ x_83 = (x_63 + 1);
+ x_64_phi = x_83;
+ break;
+ }
+ case 0: {
+ data[x_63] = 4;
+ x_81 = (x_63 + 1);
+ x_64_phi = x_81;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ int x_64 = x_64_phi;
+ {
+ x_63_phi = x_64;
+ if ((x_64 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ x_102_phi = 0;
+ while (true) {
+ int x_103 = 0;
+ int x_102 = x_102_phi;
+ if ((x_102 < 10)) {
+ } else {
+ break;
+ }
+ {
+ int x_108 = data[x_102];
+ temp[x_102] = x_108;
+ x_103 = (x_102 + 1);
+ x_102_phi = x_103;
+ }
+ }
+ x_111_phi = 1;
+ while (true) {
+ int x_112 = 0;
+ int x_118_phi = 0;
+ int x_111 = x_111_phi;
+ if ((x_111 <= 9)) {
+ } else {
+ break;
+ }
+ x_118_phi = 0;
+ while (true) {
+ int x_130 = 0;
+ int x_135 = 0;
+ int x_130_phi = 0;
+ int x_133_phi = 0;
+ int x_135_phi = 0;
+ int x_157_phi = 0;
+ int x_160_phi = 0;
+ int x_170_phi = 0;
+ int x_118 = x_118_phi;
+ if ((x_118 < 9)) {
+ } else {
+ break;
+ }
+ int x_124 = (x_118 + x_111);
+ int x_125 = (x_124 - 1);
+ int x_119 = (x_118 + (2 * x_111));
+ int x_128 = min((x_119 - 1), 9);
+ x_130_phi = x_118;
+ x_133_phi = x_124;
+ x_135_phi = x_118;
+ while (true) {
+ int x_150 = 0;
+ int x_153 = 0;
+ int x_134_phi = 0;
+ int x_136_phi = 0;
+ x_130 = x_130_phi;
+ int x_133 = x_133_phi;
+ x_135 = x_135_phi;
+ if (((x_135 <= x_125) & (x_133 <= x_128))) {
+ } else {
+ break;
+ }
+ int x_142_save = x_135;
+ int x_143 = data[x_142_save];
+ int x_144_save = x_133;
+ int x_145 = data[x_144_save];
+ int x_131 = (x_130 + 1);
+ if ((x_143 < x_145)) {
+ x_150 = (x_135 + 1);
+ int x_151 = data[x_142_save];
+ temp[x_130] = x_151;
+ x_134_phi = x_133;
+ x_136_phi = x_150;
+ } else {
+ x_153 = (x_133 + 1);
+ int x_154 = data[x_144_save];
+ temp[x_130] = x_154;
+ x_134_phi = x_153;
+ x_136_phi = x_135;
+ }
+ int x_134 = x_134_phi;
+ int x_136 = x_136_phi;
+ {
+ x_130_phi = x_131;
+ x_133_phi = x_134;
+ x_135_phi = x_136;
+ }
+ }
+ x_157_phi = x_130;
+ x_160_phi = x_135;
+ while (true) {
+ int x_158 = 0;
+ int x_161 = 0;
+ int x_157 = x_157_phi;
+ int x_160 = x_160_phi;
+ if (((x_160 < 10) & (x_160 <= x_125))) {
+ } else {
+ break;
+ }
+ {
+ x_158 = (x_157 + 1);
+ x_161 = (x_160 + 1);
+ int x_167 = data[x_160];
+ temp[x_157] = x_167;
+ x_157_phi = x_158;
+ x_160_phi = x_161;
+ }
+ }
+ x_170_phi = x_118;
+ while (true) {
+ int x_171 = 0;
+ int x_170 = x_170_phi;
+ if ((x_170 <= x_128)) {
+ } else {
+ break;
+ }
+ {
+ int x_176 = temp[x_170];
+ data[x_170] = x_176;
+ x_171 = (x_170 + 1);
+ x_170_phi = x_171;
+ }
+ }
+ {
+ x_118_phi = x_119;
+ }
+ }
+ {
+ x_112 = (2 * x_111);
+ x_111_phi = x_112;
+ }
+ }
+ int x_180 = 0;
+ float x_198 = 0.0f;
+ float x_260 = 0.0f;
+ float x_261_phi = 0.0f;
+ float x_179 = tint_symbol.y;
+ x_180 = int(x_179);
+ if ((x_180 < 30)) {
+ int x_186 = data[0];
+ x_189 = (0.5f + (float(x_186) * 0.100000001f));
+ x_262_phi = x_189;
+ } else {
+ float x_207 = 0.0f;
+ float x_259 = 0.0f;
+ float x_260_phi = 0.0f;
+ if ((x_180 < 60)) {
+ int x_195 = data[1];
+ x_198 = (0.5f + (float(x_195) * 0.100000001f));
+ x_261_phi = x_198;
+ } else {
+ float x_216 = 0.0f;
+ float x_258 = 0.0f;
+ float x_259_phi = 0.0f;
+ if ((x_180 < 90)) {
+ int x_204 = data[2];
+ x_207 = (0.5f + (float(x_204) * 0.100000001f));
+ x_260_phi = x_207;
+ } else {
+ if ((x_180 < 120)) {
+ int x_213 = data[3];
+ x_216 = (0.5f + (float(x_213) * 0.100000001f));
+ x_259_phi = x_216;
+ } else {
+ float x_229 = 0.0f;
+ float x_257 = 0.0f;
+ float x_258_phi = 0.0f;
+ if ((x_180 < 150)) {
+ discard;
+ } else {
+ float x_238 = 0.0f;
+ float x_256 = 0.0f;
+ float x_257_phi = 0.0f;
+ if ((x_180 < 180)) {
+ int x_226 = data[5];
+ x_229 = (0.5f + (float(x_226) * 0.100000001f));
+ x_258_phi = x_229;
+ } else {
+ float x_247 = 0.0f;
+ float x_255 = 0.0f;
+ float x_256_phi = 0.0f;
+ if ((x_180 < 210)) {
+ int x_235 = data[6];
+ x_238 = (0.5f + (float(x_235) * 0.100000001f));
+ x_257_phi = x_238;
+ } else {
+ if ((x_180 < 240)) {
+ int x_244 = data[7];
+ x_247 = (0.5f + (float(x_244) * 0.100000001f));
+ x_256_phi = x_247;
+ } else {
+ if ((x_180 < 270)) {
+ } else {
+ discard;
+ }
+ int x_252 = data[8];
+ x_255 = (0.5f + (float(x_252) * 0.100000001f));
+ x_256_phi = x_255;
+ }
+ x_256 = x_256_phi;
+ x_257_phi = x_256;
+ }
+ x_257 = x_257_phi;
+ x_258_phi = x_257;
+ }
+ x_258 = x_258_phi;
+ }
+ x_259_phi = x_258;
+ }
+ x_259 = x_259_phi;
+ x_260_phi = x_259;
+ }
+ x_260 = x_260_phi;
+ x_261_phi = x_260;
+ }
+ x_261 = x_261_phi;
+ x_262_phi = x_261;
+ }
+ float x_262 = x_262_phi;
+ x_GLF_color = vec4(x_262, x_262, x_262, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:169: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:169: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-dead-code/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-dead-code/0.spvasm.expected.glsl
new file mode 100644
index 0000000..0fc7e67
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-dead-code/0.spvasm.expected.glsl
@@ -0,0 +1,291 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_28;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_251 = from;
+ k = x_251;
+ int x_252 = from;
+ i = x_252;
+ int x_253 = mid;
+ j = (x_253 + 1);
+ while (true) {
+ int x_259 = i;
+ int x_260 = mid;
+ int x_262 = j;
+ int x_263 = to;
+ if (((x_259 <= x_260) & (x_262 <= x_263))) {
+ } else {
+ break;
+ }
+ int x_269 = data[i];
+ int x_272 = data[j];
+ if ((x_269 < x_272)) {
+ int x_277 = k;
+ k = (x_277 + 1);
+ int x_279 = i;
+ i = (x_279 + 1);
+ int x_282 = data[x_279];
+ temp[x_277] = x_282;
+ } else {
+ int x_284 = k;
+ k = (x_284 + 1);
+ int x_286 = j;
+ j = (x_286 + 1);
+ int x_289 = data[x_286];
+ temp[x_284] = x_289;
+ }
+ }
+ while (true) {
+ int x_295 = i;
+ int x_297 = i;
+ int x_298 = mid;
+ if (((x_295 < 10) & (x_297 <= x_298))) {
+ } else {
+ break;
+ }
+ int x_302 = k;
+ k = (x_302 + 1);
+ int x_304 = i;
+ i = (x_304 + 1);
+ int x_307 = data[x_304];
+ temp[x_302] = x_307;
+ }
+ int x_309 = from;
+ i_1 = x_309;
+ while (true) {
+ int x_314 = i_1;
+ int x_315 = to;
+ if ((x_314 <= x_315)) {
+ } else {
+ break;
+ }
+ int x_318 = i_1;
+ int x_321 = temp[i_1];
+ data[x_318] = x_321;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+void mergeSort_() {
+ int low = 0;
+ int high = 0;
+ int m = 0;
+ int i_2 = 0;
+ int from_1 = 0;
+ int mid_1 = 0;
+ int to_1 = 0;
+ int param = 0;
+ int param_1 = 0;
+ int param_2 = 0;
+ low = 0;
+ high = 9;
+ m = 1;
+ {
+ for(; (m <= high); m = (2 * m)) {
+ i_2 = low;
+ {
+ for(; (i_2 < high); i_2 = (i_2 + (2 * m))) {
+ from_1 = i_2;
+ mid_1 = ((i_2 + m) - 1);
+ to_1 = min(((i_2 + (2 * m)) - 1), high);
+ param = from_1;
+ param_1 = mid_1;
+ param_2 = to_1;
+ merge_i1_i1_i1_(param, param_1, param_2);
+ }
+ }
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ float x_84 = x_28.injectionSwitch.x;
+ i_3 = int(x_84);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ {
+ for(; (j_1 < 10); j_1 = (j_1 + 1)) {
+ int x_133 = j_1;
+ int x_136 = data[j_1];
+ temp[x_133] = x_136;
+ }
+ }
+ mergeSort_();
+ float x_142 = tint_symbol.y;
+ if ((int(x_142) < 30)) {
+ int x_149 = data[0];
+ grey = (0.5f + (float(x_149) / 10.0f));
+ } else {
+ float x_154 = tint_symbol.y;
+ if ((int(x_154) < 60)) {
+ int x_161 = data[1];
+ grey = (0.5f + (float(x_161) / 10.0f));
+ } else {
+ float x_166 = tint_symbol.y;
+ if ((int(x_166) < 90)) {
+ int x_173 = data[2];
+ grey = (0.5f + (float(x_173) / 10.0f));
+ } else {
+ float x_178 = tint_symbol.y;
+ if ((int(x_178) < 120)) {
+ int x_185 = data[3];
+ grey = (0.5f + (float(x_185) / 10.0f));
+ } else {
+ float x_190 = tint_symbol.y;
+ if ((int(x_190) < 150)) {
+ discard;
+ } else {
+ float x_197 = tint_symbol.y;
+ if ((int(x_197) < 180)) {
+ int x_204 = data[5];
+ grey = (0.5f + (float(x_204) / 10.0f));
+ } else {
+ float x_209 = tint_symbol.y;
+ if ((int(x_209) < 210)) {
+ int x_216 = data[6];
+ grey = (0.5f + (float(x_216) / 10.0f));
+ } else {
+ float x_221 = tint_symbol.y;
+ if ((int(x_221) < 240)) {
+ int x_228 = data[7];
+ grey = (0.5f + (float(x_228) / 10.0f));
+ } else {
+ float x_233 = tint_symbol.y;
+ if ((int(x_233) < 270)) {
+ int x_240 = data[8];
+ grey = (0.5f + (float(x_240) / 10.0f));
+ } else {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_244 = grey;
+ vec3 x_245 = vec3(x_244, x_244, x_244);
+ x_GLF_color = vec4(x_245.x, x_245.y, x_245.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-dead-code/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-dead-code/1.spvasm.expected.glsl
new file mode 100644
index 0000000..4352d15
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-dead-code/1.spvasm.expected.glsl
@@ -0,0 +1,311 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_28;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_262 = from;
+ k = x_262;
+ int x_263 = from;
+ i = x_263;
+ int x_264 = mid;
+ j = (x_264 + 1);
+ while (true) {
+ int x_270 = i;
+ int x_271 = mid;
+ int x_273 = j;
+ int x_274 = to;
+ if (((x_270 <= x_271) & (x_273 <= x_274))) {
+ } else {
+ break;
+ }
+ int x_280 = data[i];
+ int x_283 = data[j];
+ if ((x_280 < x_283)) {
+ int x_288 = k;
+ k = (x_288 + 1);
+ int x_290 = i;
+ i = (x_290 + 1);
+ int x_293 = data[x_290];
+ temp[x_288] = x_293;
+ } else {
+ int x_295 = k;
+ k = (x_295 + 1);
+ int x_297 = j;
+ j = (x_297 + 1);
+ int x_300 = data[x_297];
+ temp[x_295] = x_300;
+ }
+ }
+ while (true) {
+ int x_306 = i;
+ int x_308 = i;
+ int x_309 = mid;
+ if (((x_306 < 10) & (x_308 <= x_309))) {
+ } else {
+ break;
+ }
+ int x_313 = k;
+ k = (x_313 + 1);
+ int x_315 = i;
+ i = (x_315 + 1);
+ int x_318 = data[x_315];
+ temp[x_313] = x_318;
+ }
+ int x_320 = from;
+ i_1 = x_320;
+ while (true) {
+ int x_325 = i_1;
+ int x_326 = to;
+ if ((x_325 <= x_326)) {
+ } else {
+ break;
+ }
+ int x_329 = i_1;
+ int x_332 = temp[i_1];
+ data[x_329] = x_332;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+void mergeSort_() {
+ int low = 0;
+ int high = 0;
+ int m = 0;
+ int i_2 = 0;
+ int from_1 = 0;
+ int mid_1 = 0;
+ int to_1 = 0;
+ int param = 0;
+ int param_1 = 0;
+ int param_2 = 0;
+ low = 0;
+ high = 9;
+ m = 1;
+ {
+ for(; (m <= high); m = (2 * m)) {
+ i_2 = low;
+ {
+ for(; (i_2 < high); i_2 = (i_2 + (2 * m))) {
+ from_1 = i_2;
+ mid_1 = ((i_2 + m) - 1);
+ to_1 = min(((i_2 + (2 * m)) - 1), high);
+ param = from_1;
+ param_1 = mid_1;
+ param_2 = to_1;
+ merge_i1_i1_i1_(param, param_1, param_2);
+ }
+ }
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ float x_86 = x_28.injectionSwitch.x;
+ i_3 = int(x_86);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ while (true) {
+ bool x_133 = (j_1 < 10);
+ float x_135 = x_28.injectionSwitch.x;
+ if (!((x_135 <= 1.0f))) {
+ grey = 1.0f;
+ }
+ if (x_133) {
+ } else {
+ break;
+ }
+ int x_140 = j_1;
+ int x_143 = data[j_1];
+ temp[x_140] = x_143;
+ {
+ j_1 = (j_1 + 1);
+ }
+ }
+ mergeSort_();
+ float x_149 = tint_symbol.y;
+ if ((int(x_149) < 30)) {
+ int x_156 = data[0];
+ grey = (0.5f + (float(x_156) / 10.0f));
+ } else {
+ float x_161 = tint_symbol.y;
+ if ((int(x_161) < 60)) {
+ int x_168 = data[1];
+ grey = (0.5f + (float(x_168) / 10.0f));
+ } else {
+ float x_173 = tint_symbol.y;
+ if ((int(x_173) < 90)) {
+ int x_180 = data[2];
+ grey = (0.5f + (float(x_180) / 10.0f));
+ } else {
+ float x_185 = tint_symbol.y;
+ if ((int(x_185) < 120)) {
+ int x_192 = data[3];
+ grey = (0.5f + (float(x_192) / 10.0f));
+ } else {
+ float x_197 = tint_symbol.y;
+ if ((int(x_197) < 150)) {
+ discard;
+ } else {
+ float x_204 = tint_symbol.y;
+ if ((int(x_204) < 180)) {
+ int x_211 = data[5];
+ grey = (0.5f + (float(x_211) / 10.0f));
+ } else {
+ float x_216 = tint_symbol.y;
+ if ((int(x_216) < 210)) {
+ int x_223 = data[6];
+ grey = (0.5f + (float(x_223) / 10.0f));
+ } else {
+ float x_228 = tint_symbol.y;
+ if ((int(x_228) < 240)) {
+ int x_235 = data[7];
+ grey = (0.5f + (float(x_235) / 10.0f));
+ } else {
+ float x_240 = tint_symbol.y;
+ bool guard233 = true;
+ if ((int(x_240) < 270)) {
+ int x_247 = data[8];
+ grey = (0.5f + (float(x_247) / 10.0f));
+ guard233 = false;
+ } else {
+ if (guard233) {
+ float x_252 = x_28.injectionSwitch.y;
+ if (!((0.0f < x_252))) {
+ guard233 = false;
+ }
+ if (guard233) {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_255 = grey;
+ vec3 x_256 = vec3(x_255, x_255, x_255);
+ x_GLF_color = vec4(x_256.x, x_256.y, x_256.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-flatten-selection-dead-continues/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-flatten-selection-dead-continues/1.spvasm.expected.glsl
new file mode 100644
index 0000000..824bd13
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-flatten-selection-dead-continues/1.spvasm.expected.glsl
@@ -0,0 +1,396 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_28;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_255 = from;
+ k = x_255;
+ int x_256 = from;
+ i = x_256;
+ int x_257 = mid;
+ j = (x_257 + 1);
+ while (true) {
+ int x_285 = 0;
+ int x_286 = 0;
+ int x_305 = 0;
+ int x_306 = 0;
+ int x_320 = 0;
+ int x_324 = 0;
+ int x_339 = 0;
+ int x_338 = 0;
+ int x_352 = 0;
+ int x_351 = 0;
+ int x_366 = 0;
+ int x_365 = 0;
+ int x_287_phi = 0;
+ int x_307_phi = 0;
+ int x_328_phi = 0;
+ int x_340_phi = 0;
+ int x_353_phi = 0;
+ int x_367_phi = 0;
+ float x_261 = x_28.injectionSwitch.x;
+ if ((1.0f >= x_261)) {
+ } else {
+ continue;
+ }
+ int x_266 = i;
+ int x_267 = mid;
+ int x_269 = j;
+ int x_270 = to;
+ if (((x_266 <= x_267) & (x_269 <= x_270))) {
+ } else {
+ break;
+ }
+ int x_276 = data[i];
+ int x_279 = data[j];
+ bool x_280 = (x_276 < x_279);
+ if (x_280) {
+ x_285 = k;
+ x_287_phi = x_285;
+ } else {
+ x_286 = 0;
+ x_287_phi = x_286;
+ }
+ int x_287 = x_287_phi;
+ int x_288 = (x_287 + 1);
+ if (x_280) {
+ k = x_288;
+ float x_293 = x_28.injectionSwitch.x;
+ if (!((1.0f <= x_293))) {
+ } else {
+ continue;
+ }
+ }
+ float x_297 = x_28.injectionSwitch.y;
+ if ((x_297 >= 0.0f)) {
+ } else {
+ continue;
+ }
+ int x_300 = 0;
+ if (x_280) {
+ x_305 = i;
+ x_307_phi = x_305;
+ } else {
+ x_306 = 0;
+ x_307_phi = x_306;
+ }
+ int x_309 = (x_280 ? x_307_phi : x_300);
+ if (x_280) {
+ i = (x_309 + 1);
+ }
+ int x_315 = 0;
+ if (x_280) {
+ x_320 = data[x_309];
+ float x_322 = x_28.injectionSwitch.y;
+ x_328_phi = x_320;
+ if (!((0.0f <= x_322))) {
+ continue;
+ }
+ } else {
+ x_324 = 0;
+ float x_326 = x_28.injectionSwitch.y;
+ x_328_phi = x_324;
+ if (!((x_326 < 0.0f))) {
+ } else {
+ continue;
+ }
+ }
+ int x_328 = x_328_phi;
+ if (x_280) {
+ temp[x_287] = (x_280 ? x_328 : x_315);
+ }
+ if (x_280) {
+ x_339 = 0;
+ x_340_phi = x_339;
+ } else {
+ x_338 = k;
+ x_340_phi = x_338;
+ }
+ int x_340 = x_340_phi;
+ if (x_280) {
+ } else {
+ k = (x_340 + 1);
+ }
+ float x_345 = x_28.injectionSwitch.x;
+ if (!((1.0f <= x_345))) {
+ } else {
+ continue;
+ }
+ if (x_280) {
+ x_352 = 0;
+ x_353_phi = x_352;
+ } else {
+ x_351 = j;
+ x_353_phi = x_351;
+ }
+ int x_357 = (x_280 ? 0 : x_353_phi);
+ if (x_280) {
+ } else {
+ j = (x_357 + 1);
+ }
+ if (x_280) {
+ x_366 = 0;
+ x_367_phi = x_366;
+ } else {
+ x_365 = data[x_357];
+ x_367_phi = x_365;
+ }
+ int x_367 = x_367_phi;
+ if (x_280) {
+ } else {
+ temp[x_340] = x_367;
+ }
+ }
+ while (true) {
+ int x_376 = i;
+ int x_378 = i;
+ int x_379 = mid;
+ if (((x_376 < 10) & (x_378 <= x_379))) {
+ } else {
+ break;
+ }
+ int x_383 = k;
+ k = (x_383 + 1);
+ int x_385 = i;
+ i = (x_385 + 1);
+ int x_388 = data[x_385];
+ temp[x_383] = x_388;
+ }
+ int x_390 = from;
+ i_1 = x_390;
+ while (true) {
+ int x_395 = i_1;
+ int x_396 = to;
+ if ((x_395 <= x_396)) {
+ } else {
+ break;
+ }
+ int x_399 = i_1;
+ int x_402 = temp[i_1];
+ data[x_399] = x_402;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+void mergeSort_() {
+ int low = 0;
+ int high = 0;
+ int m = 0;
+ int i_2 = 0;
+ int from_1 = 0;
+ int mid_1 = 0;
+ int to_1 = 0;
+ int param = 0;
+ int param_1 = 0;
+ int param_2 = 0;
+ low = 0;
+ high = 9;
+ m = 1;
+ {
+ for(; (m <= high); m = (2 * m)) {
+ i_2 = low;
+ {
+ for(; (i_2 < high); i_2 = (i_2 + (2 * m))) {
+ from_1 = i_2;
+ mid_1 = ((i_2 + m) - 1);
+ to_1 = min(((i_2 + (2 * m)) - 1), high);
+ param = from_1;
+ param_1 = mid_1;
+ param_2 = to_1;
+ merge_i1_i1_i1_(param, param_1, param_2);
+ }
+ }
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ float x_88 = x_28.injectionSwitch.x;
+ i_3 = int(x_88);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ {
+ for(; (j_1 < 10); j_1 = (j_1 + 1)) {
+ int x_137 = j_1;
+ int x_140 = data[j_1];
+ temp[x_137] = x_140;
+ }
+ }
+ mergeSort_();
+ float x_146 = tint_symbol.y;
+ if ((int(x_146) < 30)) {
+ int x_153 = data[0];
+ grey = (0.5f + (float(x_153) / 10.0f));
+ } else {
+ float x_158 = tint_symbol.y;
+ if ((int(x_158) < 60)) {
+ int x_165 = data[1];
+ grey = (0.5f + (float(x_165) / 10.0f));
+ } else {
+ float x_170 = tint_symbol.y;
+ if ((int(x_170) < 90)) {
+ int x_177 = data[2];
+ grey = (0.5f + (float(x_177) / 10.0f));
+ } else {
+ float x_182 = tint_symbol.y;
+ if ((int(x_182) < 120)) {
+ int x_189 = data[3];
+ grey = (0.5f + (float(x_189) / 10.0f));
+ } else {
+ float x_194 = tint_symbol.y;
+ if ((int(x_194) < 150)) {
+ discard;
+ } else {
+ float x_201 = tint_symbol.y;
+ if ((int(x_201) < 180)) {
+ int x_208 = data[5];
+ grey = (0.5f + (float(x_208) / 10.0f));
+ } else {
+ float x_213 = tint_symbol.y;
+ if ((int(x_213) < 210)) {
+ int x_220 = data[6];
+ grey = (0.5f + (float(x_220) / 10.0f));
+ } else {
+ float x_225 = tint_symbol.y;
+ if ((int(x_225) < 240)) {
+ int x_232 = data[7];
+ grey = (0.5f + (float(x_232) / 10.0f));
+ } else {
+ float x_237 = tint_symbol.y;
+ if ((int(x_237) < 270)) {
+ int x_244 = data[8];
+ grey = (0.5f + (float(x_244) / 10.0f));
+ } else {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_248 = grey;
+ vec3 x_249 = vec3(x_248, x_248, x_248);
+ x_GLF_color = vec4(x_249.x, x_249.y, x_249.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:55: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:55: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-flatten-selection-dead-continues/2-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-flatten-selection-dead-continues/2-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..a2c4833
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-flatten-selection-dead-continues/2-opt.spvasm.expected.glsl
@@ -0,0 +1,395 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_28;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_255 = from;
+ k = x_255;
+ int x_256 = from;
+ i = x_256;
+ int x_257 = mid;
+ j = (x_257 + 1);
+ while (true) {
+ int x_283 = 0;
+ int x_284 = 0;
+ int x_303 = 0;
+ int x_304 = 0;
+ int x_318 = 0;
+ int x_322 = 0;
+ int x_337 = 0;
+ int x_336 = 0;
+ int x_350 = 0;
+ int x_349 = 0;
+ int x_364 = 0;
+ int x_363 = 0;
+ int x_285_phi = 0;
+ int x_305_phi = 0;
+ int x_326_phi = 0;
+ int x_338_phi = 0;
+ int x_351_phi = 0;
+ int x_365_phi = 0;
+ if ((1.0f >= 0.0f)) {
+ } else {
+ continue;
+ }
+ int x_264 = i;
+ int x_265 = mid;
+ int x_267 = j;
+ int x_268 = to;
+ if (((x_264 <= x_265) & (x_267 <= x_268))) {
+ } else {
+ break;
+ }
+ int x_274 = data[i];
+ int x_277 = data[j];
+ bool x_278 = (x_274 < x_277);
+ if (x_278) {
+ x_283 = k;
+ x_285_phi = x_283;
+ } else {
+ x_284 = 0;
+ x_285_phi = x_284;
+ }
+ int x_285 = x_285_phi;
+ int x_286 = (x_285 + 1);
+ if (x_278) {
+ k = x_286;
+ float x_291 = x_28.injectionSwitch.x;
+ if (!((1.0f <= x_291))) {
+ } else {
+ continue;
+ }
+ }
+ float x_295 = x_28.injectionSwitch.y;
+ if ((x_295 >= 0.0f)) {
+ } else {
+ continue;
+ }
+ int x_298 = 0;
+ if (x_278) {
+ x_303 = i;
+ x_305_phi = x_303;
+ } else {
+ x_304 = 0;
+ x_305_phi = x_304;
+ }
+ int x_307 = (x_278 ? x_305_phi : x_298);
+ if (x_278) {
+ i = (x_307 + 1);
+ }
+ int x_313 = 0;
+ if (x_278) {
+ x_318 = data[x_307];
+ float x_320 = x_28.injectionSwitch.y;
+ x_326_phi = x_318;
+ if (!((0.0f <= x_320))) {
+ continue;
+ }
+ } else {
+ x_322 = 0;
+ float x_324 = x_28.injectionSwitch.y;
+ x_326_phi = x_322;
+ if (!((x_324 < 0.0f))) {
+ } else {
+ continue;
+ }
+ }
+ int x_326 = x_326_phi;
+ if (x_278) {
+ temp[x_285] = (x_278 ? x_326 : x_313);
+ }
+ if (x_278) {
+ x_337 = 0;
+ x_338_phi = x_337;
+ } else {
+ x_336 = k;
+ x_338_phi = x_336;
+ }
+ int x_338 = x_338_phi;
+ if (x_278) {
+ } else {
+ k = (x_338 + 1);
+ }
+ float x_343 = x_28.injectionSwitch.x;
+ if (!((1.0f <= x_343))) {
+ } else {
+ continue;
+ }
+ if (x_278) {
+ x_350 = 0;
+ x_351_phi = x_350;
+ } else {
+ x_349 = j;
+ x_351_phi = x_349;
+ }
+ int x_355 = (x_278 ? 0 : x_351_phi);
+ if (x_278) {
+ } else {
+ j = (x_355 + 1);
+ }
+ if (x_278) {
+ x_364 = 0;
+ x_365_phi = x_364;
+ } else {
+ x_363 = data[x_355];
+ x_365_phi = x_363;
+ }
+ int x_365 = x_365_phi;
+ if (x_278) {
+ } else {
+ temp[x_338] = x_365;
+ }
+ }
+ while (true) {
+ int x_374 = i;
+ int x_376 = i;
+ int x_377 = mid;
+ if (((x_374 < 10) & (x_376 <= x_377))) {
+ } else {
+ break;
+ }
+ int x_381 = k;
+ k = (x_381 + 1);
+ int x_383 = i;
+ i = (x_383 + 1);
+ int x_386 = data[x_383];
+ temp[x_381] = x_386;
+ }
+ int x_388 = from;
+ i_1 = x_388;
+ while (true) {
+ int x_393 = i_1;
+ int x_394 = to;
+ if ((x_393 <= x_394)) {
+ } else {
+ break;
+ }
+ int x_397 = i_1;
+ int x_400 = temp[i_1];
+ data[x_397] = x_400;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+void mergeSort_() {
+ int low = 0;
+ int high = 0;
+ int m = 0;
+ int i_2 = 0;
+ int from_1 = 0;
+ int mid_1 = 0;
+ int to_1 = 0;
+ int param = 0;
+ int param_1 = 0;
+ int param_2 = 0;
+ low = 0;
+ high = 9;
+ m = 1;
+ {
+ for(; (m <= high); m = (2 * m)) {
+ i_2 = low;
+ {
+ for(; (i_2 < high); i_2 = (i_2 + (2 * m))) {
+ from_1 = i_2;
+ mid_1 = ((i_2 + m) - 1);
+ to_1 = min(((i_2 + (2 * m)) - 1), high);
+ param = from_1;
+ param_1 = mid_1;
+ param_2 = to_1;
+ merge_i1_i1_i1_(param, param_1, param_2);
+ }
+ }
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ float x_88 = x_28.injectionSwitch.x;
+ i_3 = int(x_88);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ {
+ for(; (j_1 < 10); j_1 = (j_1 + 1)) {
+ int x_137 = j_1;
+ int x_140 = data[j_1];
+ temp[x_137] = x_140;
+ }
+ }
+ mergeSort_();
+ float x_146 = tint_symbol.y;
+ if ((int(x_146) < 30)) {
+ int x_153 = data[0];
+ grey = (0.5f + (float(x_153) / 10.0f));
+ } else {
+ float x_158 = tint_symbol.y;
+ if ((int(x_158) < 60)) {
+ int x_165 = data[1];
+ grey = (0.5f + (float(x_165) / 10.0f));
+ } else {
+ float x_170 = tint_symbol.y;
+ if ((int(x_170) < 90)) {
+ int x_177 = data[2];
+ grey = (0.5f + (float(x_177) / 10.0f));
+ } else {
+ float x_182 = tint_symbol.y;
+ if ((int(x_182) < 120)) {
+ int x_189 = data[3];
+ grey = (0.5f + (float(x_189) / 10.0f));
+ } else {
+ float x_194 = tint_symbol.y;
+ if ((int(x_194) < 150)) {
+ discard;
+ } else {
+ float x_201 = tint_symbol.y;
+ if ((int(x_201) < 180)) {
+ int x_208 = data[5];
+ grey = (0.5f + (float(x_208) / 10.0f));
+ } else {
+ float x_213 = tint_symbol.y;
+ if ((int(x_213) < 210)) {
+ int x_220 = data[6];
+ grey = (0.5f + (float(x_220) / 10.0f));
+ } else {
+ float x_225 = tint_symbol.y;
+ if ((int(x_225) < 240)) {
+ int x_232 = data[7];
+ grey = (0.5f + (float(x_232) / 10.0f));
+ } else {
+ float x_237 = tint_symbol.y;
+ if ((int(x_237) < 270)) {
+ int x_244 = data[8];
+ grey = (0.5f + (float(x_244) / 10.0f));
+ } else {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_248 = grey;
+ vec3 x_249 = vec3(x_248, x_248, x_248);
+ x_GLF_color = vec4(x_249.x, x_249.y, x_249.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:54: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:54: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-func-inline-mutate-var/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-func-inline-mutate-var/1.spvasm.expected.glsl
new file mode 100644
index 0000000..b897f35
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-func-inline-mutate-var/1.spvasm.expected.glsl
@@ -0,0 +1,292 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_28;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_303 = from;
+ k = x_303;
+ int x_304 = from;
+ i = x_304;
+ int x_305 = mid;
+ j = (x_305 + 1);
+ while (true) {
+ int x_311 = i;
+ int x_312 = mid;
+ int x_314 = j;
+ int x_315 = to;
+ if (((x_311 <= x_312) & (x_314 <= x_315))) {
+ } else {
+ break;
+ }
+ int x_321 = data[i];
+ int x_324 = data[j];
+ if ((x_321 < x_324)) {
+ int x_329 = k;
+ k = (x_329 + 1);
+ int x_331 = i;
+ i = (x_331 + 1);
+ int x_334 = data[x_331];
+ temp[x_329] = x_334;
+ } else {
+ int x_336 = k;
+ k = (x_336 + 1);
+ int x_338 = j;
+ j = (x_338 + 1);
+ int x_341 = data[x_338];
+ temp[x_336] = x_341;
+ }
+ }
+ while (true) {
+ int x_347 = i;
+ int x_349 = i;
+ int x_350 = mid;
+ if (((x_347 < 10) & (x_349 <= x_350))) {
+ } else {
+ break;
+ }
+ int x_354 = k;
+ k = (x_354 + 1);
+ int x_356 = i;
+ i = (x_356 + 1);
+ int x_359 = data[x_356];
+ temp[x_354] = x_359;
+ }
+ int x_361 = from;
+ i_1 = x_361;
+ while (true) {
+ int x_366 = i_1;
+ int x_367 = to;
+ if ((x_366 <= x_367)) {
+ } else {
+ break;
+ }
+ int x_370 = i_1;
+ int x_373 = temp[i_1];
+ data[x_370] = x_373;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int x_85 = 0;
+ int x_86 = 0;
+ int x_87 = 0;
+ int x_88 = 0;
+ int x_89 = 0;
+ int x_90 = 0;
+ int x_91 = 0;
+ int x_92 = 0;
+ int x_93 = 0;
+ int x_94 = 0;
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ float x_96 = x_28.injectionSwitch.x;
+ i_3 = int(x_96);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ {
+ for(; (j_1 < 10); j_1 = (j_1 + 1)) {
+ int x_145 = j_1;
+ int x_148 = data[j_1];
+ temp[x_145] = x_148;
+ }
+ }
+ x_94 = 0;
+ x_93 = 9;
+ x_92 = 1;
+ {
+ for(; (x_92 <= x_93); x_92 = (2 * x_92)) {
+ x_91 = x_94;
+ {
+ for(; (x_91 < x_93); x_91 = (x_91 + (2 * x_92))) {
+ x_90 = x_91;
+ int x_170 = x_91;
+ int x_171 = x_92;
+ int x_173[10] = data;
+ int tint_symbol_6[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+ data = tint_symbol_6;
+ data = x_173;
+ x_89 = ((x_170 + x_171) - 1);
+ x_88 = min(((x_91 + (2 * x_92)) - 1), x_93);
+ x_87 = x_90;
+ x_86 = x_89;
+ x_85 = x_88;
+ merge_i1_i1_i1_(x_87, x_86, x_85);
+ }
+ }
+ }
+ }
+ float x_194 = tint_symbol.y;
+ if ((int(x_194) < 30)) {
+ int x_201 = data[0];
+ grey = (0.5f + (float(x_201) / 10.0f));
+ } else {
+ float x_206 = tint_symbol.y;
+ if ((int(x_206) < 60)) {
+ int x_213 = data[1];
+ grey = (0.5f + (float(x_213) / 10.0f));
+ } else {
+ float x_218 = tint_symbol.y;
+ if ((int(x_218) < 90)) {
+ int x_225 = data[2];
+ grey = (0.5f + (float(x_225) / 10.0f));
+ } else {
+ float x_230 = tint_symbol.y;
+ if ((int(x_230) < 120)) {
+ int x_237 = data[3];
+ grey = (0.5f + (float(x_237) / 10.0f));
+ } else {
+ float x_242 = tint_symbol.y;
+ if ((int(x_242) < 150)) {
+ discard;
+ } else {
+ float x_249 = tint_symbol.y;
+ if ((int(x_249) < 180)) {
+ int x_256 = data[5];
+ grey = (0.5f + (float(x_256) / 10.0f));
+ } else {
+ float x_261 = tint_symbol.y;
+ if ((int(x_261) < 210)) {
+ int x_268 = data[6];
+ grey = (0.5f + (float(x_268) / 10.0f));
+ } else {
+ float x_273 = tint_symbol.y;
+ if ((int(x_273) < 240)) {
+ int x_280 = data[7];
+ grey = (0.5f + (float(x_280) / 10.0f));
+ } else {
+ float x_285 = tint_symbol.y;
+ if ((int(x_285) < 270)) {
+ int x_292 = data[8];
+ grey = (0.5f + (float(x_292) / 10.0f));
+ } else {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_296 = grey;
+ vec3 x_297 = vec3(x_296, x_296, x_296);
+ x_GLF_color = vec4(x_297.x, x_297.y, x_297.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_7 = main_out(x_GLF_color);
+ return tint_symbol_7;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-func-inline-mutate-var/2.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-func-inline-mutate-var/2.spvasm.expected.glsl
new file mode 100644
index 0000000..6aabbce
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/spv-stable-mergesort-func-inline-mutate-var/2.spvasm.expected.glsl
@@ -0,0 +1,286 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_28;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_302 = from;
+ k = x_302;
+ int x_303 = from;
+ i = x_303;
+ int x_304 = mid;
+ j = (x_304 + 1);
+ while (true) {
+ int x_310 = i;
+ int x_311 = mid;
+ int x_313 = j;
+ int x_314 = to;
+ if (((x_310 <= x_311) & (x_313 <= x_314))) {
+ } else {
+ break;
+ }
+ int x_320 = data[i];
+ int x_323 = data[j];
+ if ((x_320 < x_323)) {
+ int x_328 = k;
+ k = (x_328 + 1);
+ int x_330 = i;
+ i = (x_330 + 1);
+ int x_333 = data[x_330];
+ temp[x_328] = x_333;
+ } else {
+ int x_335 = k;
+ k = (x_335 + 1);
+ int x_337 = j;
+ j = (x_337 + 1);
+ int x_340 = data[x_337];
+ temp[x_335] = x_340;
+ }
+ }
+ while (true) {
+ int x_346 = i;
+ int x_348 = i;
+ int x_349 = mid;
+ if (((x_346 < 10) & (x_348 <= x_349))) {
+ } else {
+ break;
+ }
+ int x_353 = k;
+ k = (x_353 + 1);
+ int x_355 = i;
+ i = (x_355 + 1);
+ int x_358 = data[x_355];
+ temp[x_353] = x_358;
+ }
+ int x_360 = from;
+ i_1 = x_360;
+ while (true) {
+ int x_365 = i_1;
+ int x_366 = to;
+ if ((x_365 <= x_366)) {
+ } else {
+ break;
+ }
+ int x_369 = i_1;
+ int x_372 = temp[i_1];
+ data[x_369] = x_372;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int x_85 = 0;
+ int x_86 = 0;
+ int x_87 = 0;
+ int x_88 = 0;
+ int x_89 = 0;
+ int x_90 = 0;
+ int x_91 = 0;
+ int x_92 = 0;
+ int x_93 = 0;
+ int x_94 = 0;
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ float x_96 = x_28.injectionSwitch.x;
+ i_3 = int(x_96);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ {
+ for(; (j_1 < 10); j_1 = (j_1 + 1)) {
+ int x_145 = j_1;
+ int x_148 = data[j_1];
+ temp[x_145] = x_148;
+ }
+ }
+ x_94 = 0;
+ x_93 = 9;
+ x_92 = 1;
+ {
+ for(; (x_92 <= x_93); x_92 = (2 * x_92)) {
+ x_91 = x_94;
+ {
+ for(; (x_91 < x_93); x_91 = (x_91 + (2 * x_92))) {
+ x_90 = x_91;
+ x_89 = ((x_91 + x_92) - 1);
+ x_88 = min(((x_91 + (2 * x_92)) - 1), x_93);
+ x_87 = x_90;
+ x_86 = x_89;
+ x_85 = x_88;
+ merge_i1_i1_i1_(x_87, x_86, x_85);
+ }
+ }
+ }
+ }
+ float x_193 = tint_symbol.y;
+ if ((int(x_193) < 30)) {
+ int x_200 = data[0];
+ grey = (0.5f + (float(x_200) / 10.0f));
+ } else {
+ float x_205 = tint_symbol.y;
+ if ((int(x_205) < 60)) {
+ int x_212 = data[1];
+ grey = (0.5f + (float(x_212) / 10.0f));
+ } else {
+ float x_217 = tint_symbol.y;
+ if ((int(x_217) < 90)) {
+ int x_224 = data[2];
+ grey = (0.5f + (float(x_224) / 10.0f));
+ } else {
+ float x_229 = tint_symbol.y;
+ if ((int(x_229) < 120)) {
+ int x_236 = data[3];
+ grey = (0.5f + (float(x_236) / 10.0f));
+ } else {
+ float x_241 = tint_symbol.y;
+ if ((int(x_241) < 150)) {
+ discard;
+ } else {
+ float x_248 = tint_symbol.y;
+ if ((int(x_248) < 180)) {
+ int x_255 = data[5];
+ grey = (0.5f + (float(x_255) / 10.0f));
+ } else {
+ float x_260 = tint_symbol.y;
+ if ((int(x_260) < 210)) {
+ int x_267 = data[6];
+ grey = (0.5f + (float(x_267) / 10.0f));
+ } else {
+ float x_272 = tint_symbol.y;
+ if ((int(x_272) < 240)) {
+ int x_279 = data[7];
+ grey = (0.5f + (float(x_279) / 10.0f));
+ } else {
+ float x_284 = tint_symbol.y;
+ if ((int(x_284) < 270)) {
+ int x_291 = data[8];
+ grey = (0.5f + (float(x_291) / 10.0f));
+ } else {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_295 = grey;
+ vec3 x_296 = vec3(x_295, x_295, x_295);
+ x_GLF_color = vec4(x_296.x, x_296.y, x_296.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-float-mat-determinant-clamp/0.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-float-mat-determinant-clamp/0.wgsl.expected.glsl
new file mode 100644
index 0000000..c4b5778
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-float-mat-determinant-clamp/0.wgsl.expected.glsl
@@ -0,0 +1,122 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_13;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+float compute_value_f1_f1_(inout float limit, inout float thirty_two) {
+ float result = 0.0f;
+ int i = 0;
+ result = -0.5f;
+ i = 1;
+ {
+ for(; (i < 800); i = (i + 1)) {
+ if (((i % 32) == 0)) {
+ result = (result + 0.400000006f);
+ } else {
+ int x_122 = i;
+ float x_124 = thirty_two;
+ if (((float(x_122) % round(x_124)) <= 0.01f)) {
+ result = (result + 100.0f);
+ }
+ }
+ int x_132 = i;
+ float x_134 = limit;
+ if ((float(x_132) >= x_134)) {
+ return result;
+ }
+ }
+ }
+ return result;
+}
+
+void main_1() {
+ vec3 c = vec3(0.0f, 0.0f, 0.0f);
+ float thirty_two_1 = 0.0f;
+ float param = 0.0f;
+ float param_1 = 0.0f;
+ float param_2 = 0.0f;
+ float param_3 = 0.0f;
+ int i_1 = 0;
+ c = vec3(7.0f, 8.0f, 9.0f);
+ float x_56 = x_13.resolution.x;
+ thirty_two_1 = round((x_56 / 8.0f));
+ float x_60 = tint_symbol.x;
+ param = x_60;
+ param_1 = thirty_two_1;
+ float x_62 = compute_value_f1_f1_(param, param_1);
+ c.x = x_62;
+ float x_65 = tint_symbol.y;
+ param_2 = x_65;
+ param_3 = thirty_two_1;
+ float x_67 = compute_value_f1_f1_(param_2, param_3);
+ c.y = x_67;
+ float x_70 = c.x;
+ float x_72 = c.y;
+ c.z = (x_70 + x_72);
+ i_1 = 0;
+ {
+ for(; (i_1 < 3); i_1 = (i_1 + 1)) {
+ float x_84 = c[i_1];
+ if ((x_84 >= 1.0f)) {
+ int x_88 = i_1;
+ float x_91 = c[i_1];
+ float x_94 = c[i_1];
+ c[x_88] = (x_91 * x_94);
+ }
+ }
+ }
+ vec3 x_101 = normalize(abs(c));
+ x_GLF_color = vec4(x_101.x, x_101.y, x_101.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp float' and a right operand of type ' global mediump float' (or there is no acceptable conversion)
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-injected-conditional-true/1.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-injected-conditional-true/1.wgsl.expected.glsl
new file mode 100644
index 0000000..c4bb170
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-injected-conditional-true/1.wgsl.expected.glsl
@@ -0,0 +1,136 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+struct buf1 {
+ vec2 injectionSwitch;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_13;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ vec2 injectionSwitch;
+} x_20;
+
+float compute_value_f1_f1_(inout float limit, inout float thirty_two) {
+ float result = 0.0f;
+ int i = 0;
+ result = -0.5f;
+ i = 1;
+ {
+ for(; (i < 800); i = (i + 1)) {
+ if (((i % 32) == 0)) {
+ result = (result + 0.400000006f);
+ } else {
+ int x_136 = i;
+ float x_138 = thirty_two;
+ if (((float(x_136) % round(x_138)) <= 0.01f)) {
+ result = (result + 100.0f);
+ }
+ }
+ int x_146 = i;
+ float x_148 = limit;
+ if ((float(x_146) >= x_148)) {
+ return result;
+ }
+ }
+ }
+ return result;
+}
+
+void main_1() {
+ vec3 c = vec3(0.0f, 0.0f, 0.0f);
+ float thirty_two_1 = 0.0f;
+ float param = 0.0f;
+ float param_1 = 0.0f;
+ float param_2 = 0.0f;
+ float param_3 = 0.0f;
+ int i_1 = 0;
+ vec3 x_58 = vec3(0.0f, 0.0f, 0.0f);
+ c = vec3(7.0f, 8.0f, 9.0f);
+ float x_60 = x_13.resolution.x;
+ thirty_two_1 = round((x_60 / 8.0f));
+ float x_64 = tint_symbol.x;
+ param = x_64;
+ param_1 = thirty_two_1;
+ float x_66 = compute_value_f1_f1_(param, param_1);
+ c.x = x_66;
+ float x_69 = tint_symbol.y;
+ param_2 = x_69;
+ param_3 = thirty_two_1;
+ float x_71 = compute_value_f1_f1_(param_2, param_3);
+ c.y = x_71;
+ float x_74 = c.x;
+ float x_76 = c.y;
+ c.z = (x_74 + x_76);
+ i_1 = 0;
+ {
+ for(; (i_1 < 3); i_1 = (i_1 + 1)) {
+ float x_88 = c[i_1];
+ if ((x_88 >= 1.0f)) {
+ int x_92 = i_1;
+ float x_95 = c[i_1];
+ float x_98 = c[i_1];
+ c[x_92] = (x_95 * x_98);
+ }
+ }
+ }
+ float x_104 = x_20.injectionSwitch.x;
+ float x_106 = x_20.injectionSwitch.y;
+ if ((x_104 < x_106)) {
+ x_58 = abs(c);
+ } else {
+ x_58 = c;
+ }
+ vec3 x_115 = normalize(x_58);
+ x_GLF_color = vec4(x_115.x, x_115.y, x_115.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp float' and a right operand of type ' global mediump float' (or there is no acceptable conversion)
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-true-conditional-simple-loop/1.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-true-conditional-simple-loop/1.wgsl.expected.glsl
new file mode 100644
index 0000000..b732d6e
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-true-conditional-simple-loop/1.wgsl.expected.glsl
@@ -0,0 +1,152 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+struct buf1 {
+ vec2 injectionSwitch;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_13;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf1_1 {
+ vec2 injectionSwitch;
+} x_19;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+float compute_value_f1_f1_(inout float limit, inout float thirty_two) {
+ float result = 0.0f;
+ int i = 0;
+ result = -0.5f;
+ i = 1;
+ {
+ for(; (i < 800); i = (i + 1)) {
+ if (((i % 32) == 0)) {
+ result = (result + 0.400000006f);
+ } else {
+ int x_155 = i;
+ float x_157 = thirty_two;
+ if (((float(x_155) % round(x_157)) <= 0.01f)) {
+ result = (result + 100.0f);
+ }
+ }
+ int x_165 = i;
+ float x_167 = limit;
+ if ((float(x_165) >= x_167)) {
+ return result;
+ }
+ }
+ }
+ return result;
+}
+
+void main_1() {
+ vec3 c = vec3(0.0f, 0.0f, 0.0f);
+ float thirty_two_1 = 0.0f;
+ float param = 0.0f;
+ float param_1 = 0.0f;
+ float param_2 = 0.0f;
+ float param_3 = 0.0f;
+ vec3 x_61 = vec3(0.0f, 0.0f, 0.0f);
+ int i_1 = 0;
+ float j = 0.0f;
+ c = vec3(7.0f, 8.0f, 9.0f);
+ float x_63 = x_13.resolution.x;
+ thirty_two_1 = round((x_63 / 8.0f));
+ float x_67 = tint_symbol.x;
+ param = x_67;
+ param_1 = thirty_two_1;
+ float x_69 = compute_value_f1_f1_(param, param_1);
+ c.x = x_69;
+ float x_72 = tint_symbol.y;
+ param_2 = x_72;
+ param_3 = thirty_two_1;
+ float x_74 = compute_value_f1_f1_(param_2, param_3);
+ c.y = x_74;
+ float x_77 = c.x;
+ if (true) {
+ x_61 = c;
+ } else {
+ vec3 x_82 = c;
+ float x_84 = x_19.injectionSwitch.x;
+ x_61 = (x_82 * x_84);
+ }
+ float x_87 = x_61.y;
+ c.z = (x_77 + x_87);
+ i_1 = 0;
+ {
+ for(; (i_1 < 3); i_1 = (i_1 + 1)) {
+ float x_99 = c[i_1];
+ if ((x_99 >= 1.0f)) {
+ int x_103 = i_1;
+ float x_106 = c[i_1];
+ float x_109 = c[i_1];
+ c[x_103] = (x_106 * x_109);
+ }
+ j = 0.0f;
+ while (true) {
+ float x_117 = x_19.injectionSwitch.x;
+ float x_119 = x_19.injectionSwitch.y;
+ if ((x_117 > x_119)) {
+ } else {
+ break;
+ }
+ float x_122 = j;
+ float x_124 = x_19.injectionSwitch.x;
+ if ((x_122 >= x_124)) {
+ break;
+ }
+ j = (j + 1.0f);
+ }
+ }
+ }
+ vec3 x_134 = normalize(abs(c));
+ x_GLF_color = vec4(x_134.x, x_134.y, x_134.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp float' and a right operand of type ' global mediump float' (or there is no acceptable conversion)
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-vec3-values-from-matrix/1.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-vec3-values-from-matrix/1.wgsl.expected.glsl
new file mode 100644
index 0000000..9faf652
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-colorgrid-modulo-vec3-values-from-matrix/1.wgsl.expected.glsl
@@ -0,0 +1,127 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_13;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+float compute_value_f1_f1_(inout float limit, inout float thirty_two) {
+ float result = 0.0f;
+ int i = 0;
+ result = -0.5f;
+ i = 1;
+ {
+ for(; (i < 800); i = (i + 1)) {
+ if (((i % 32) == 0)) {
+ result = (result + 0.400000006f);
+ } else {
+ int x_147 = i;
+ float x_149 = thirty_two;
+ if (((float(x_147) % round(x_149)) <= 0.01f)) {
+ result = (result + 100.0f);
+ }
+ }
+ int x_157 = i;
+ float x_159 = limit;
+ if ((float(x_157) >= x_159)) {
+ return result;
+ }
+ }
+ }
+ return result;
+}
+
+void main_1() {
+ vec3 c = vec3(0.0f, 0.0f, 0.0f);
+ float thirty_two_1 = 0.0f;
+ float param = 0.0f;
+ float param_1 = 0.0f;
+ float param_2 = 0.0f;
+ float param_3 = 0.0f;
+ int i_1 = 0;
+ c = vec3(7.0f, 8.0f, 9.0f);
+ float x_63 = x_13.resolution.x;
+ thirty_two_1 = round((x_63 / 8.0f));
+ float x_67 = tint_symbol.x;
+ param = x_67;
+ param_1 = thirty_two_1;
+ float x_69 = compute_value_f1_f1_(param, param_1);
+ c.x = x_69;
+ float x_72 = tint_symbol.y;
+ param_2 = x_72;
+ param_3 = thirty_two_1;
+ float x_74 = compute_value_f1_f1_(param_2, param_3);
+ c.y = x_74;
+ vec3 x_76 = c;
+ vec3 x_79 = c;
+ mat4x2 x_87 = mat4x2(vec2(x_79.x, x_79.y), vec2(x_79.z, 1.0f), vec2(1.0f, 0.0f), vec2(1.0f, 0.0f));
+ c.z = ((x_76 * mat3(vec3(1.0f, 0.0f, 0.0f), vec3(0.0f, 1.0f, 0.0f), vec3(0.0f, 0.0f, 1.0f))).x + vec3(x_87[0u].x, x_87[0u].y, x_87[1u].x).y);
+ i_1 = 0;
+ {
+ for(; (i_1 < 3); i_1 = (i_1 + 1)) {
+ float x_104 = c[i_1];
+ if ((x_104 >= 1.0f)) {
+ int x_108 = i_1;
+ float x_111 = c[i_1];
+ float x_114 = c[i_1];
+ c[x_108] = (x_111 * x_114);
+ float x_118 = tint_symbol.y;
+ if ((x_118 < 0.0f)) {
+ break;
+ }
+ }
+ }
+ }
+ vec3 x_126 = normalize(abs(c));
+ x_GLF_color = vec4(x_126.x, x_126.y, x_126.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:26: '%' : wrong operand types: no operation '%' exists that takes a left-hand operand of type ' temp float' and a right operand of type ' global mediump float' (or there is no acceptable conversion)
+ERROR: 0:26: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-mergesort-clamped-conditional-bit-shift/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-mergesort-clamped-conditional-bit-shift/1.spvasm.expected.glsl
new file mode 100644
index 0000000..5515ee8
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-mergesort-clamped-conditional-bit-shift/1.spvasm.expected.glsl
@@ -0,0 +1,325 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_34;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_260 = from;
+ k = x_260;
+ int x_261 = from;
+ i = x_261;
+ int x_262 = mid;
+ j = (x_262 + 1);
+ while (true) {
+ int x_268 = i;
+ int x_269 = mid;
+ int x_271 = j;
+ int x_272 = to;
+ if (((x_268 <= x_269) & (x_271 <= x_272))) {
+ } else {
+ break;
+ }
+ int x_278 = data[i];
+ int x_281 = data[j];
+ if ((x_278 < x_281)) {
+ int x_286 = k;
+ k = (x_286 + 1);
+ int x_288 = i;
+ i = (x_288 + 1);
+ int x_291 = data[x_288];
+ temp[x_286] = x_291;
+ } else {
+ int x_293 = k;
+ k = (x_293 + 1);
+ int x_295 = j;
+ j = (x_295 + 1);
+ int x_298 = data[x_295];
+ temp[x_293] = x_298;
+ }
+ }
+ while (true) {
+ int x_304 = i;
+ int x_306 = i;
+ int x_307 = mid;
+ if (((x_304 < 10) & (x_306 <= x_307))) {
+ } else {
+ break;
+ }
+ int x_311 = k;
+ k = (x_311 + 1);
+ int x_313 = i;
+ i = (x_313 + 1);
+ int x_316 = data[x_313];
+ temp[x_311] = x_316;
+ }
+ int x_318 = from;
+ i_1 = x_318;
+ while (true) {
+ int x_323 = i_1;
+ int x_324 = to;
+ if ((x_323 <= x_324)) {
+ } else {
+ break;
+ }
+ int x_327 = i_1;
+ int x_330 = temp[i_1];
+ data[x_327] = x_330;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+int func_i1_i1_(inout int m, inout int high) {
+ int x = 0;
+ int x_335 = 0;
+ int x_336 = 0;
+ float x_338 = tint_symbol.x;
+ if ((x_338 >= 0.0f)) {
+ if (false) {
+ int x_346 = high;
+ x_336 = (x_346 << uint(0));
+ } else {
+ x_336 = 4;
+ }
+ x_335 = (1 << uint(x_336));
+ } else {
+ x_335 = 1;
+ }
+ x = x_335;
+ x = (x >> uint(4));
+ int x_353 = m;
+ int x_355 = m;
+ int x_357 = m;
+ return clamp((2 * x_353), (2 * x_355), ((2 * x_357) / x));
+}
+
+void mergeSort_() {
+ int low = 0;
+ int high_1 = 0;
+ int m_1 = 0;
+ int i_2 = 0;
+ int from_1 = 0;
+ int mid_1 = 0;
+ int to_1 = 0;
+ int param = 0;
+ int param_1 = 0;
+ int param_2 = 0;
+ int param_3 = 0;
+ int param_4 = 0;
+ low = 0;
+ high_1 = 9;
+ m_1 = 1;
+ {
+ for(; (m_1 <= high_1); m_1 = (2 * m_1)) {
+ i_2 = low;
+ while (true) {
+ if ((i_2 < high_1)) {
+ } else {
+ break;
+ }
+ from_1 = i_2;
+ mid_1 = ((i_2 + m_1) - 1);
+ to_1 = min(((i_2 + (2 * m_1)) - 1), high_1);
+ param = from_1;
+ param_1 = mid_1;
+ param_2 = to_1;
+ merge_i1_i1_i1_(param, param_1, param_2);
+ {
+ param_3 = m_1;
+ param_4 = high_1;
+ int x_398 = func_i1_i1_(param_3, param_4);
+ i_2 = (i_2 + x_398);
+ }
+ }
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ float x_93 = x_34.injectionSwitch.x;
+ i_3 = int(x_93);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ {
+ for(; (j_1 < 10); j_1 = (j_1 + 1)) {
+ int x_142 = j_1;
+ int x_145 = data[j_1];
+ temp[x_142] = x_145;
+ }
+ }
+ mergeSort_();
+ float x_151 = tint_symbol.y;
+ if ((int(x_151) < 30)) {
+ int x_158 = data[0];
+ grey = (0.5f + (float(x_158) / 10.0f));
+ } else {
+ float x_163 = tint_symbol.y;
+ if ((int(x_163) < 60)) {
+ int x_170 = data[1];
+ grey = (0.5f + (float(x_170) / 10.0f));
+ } else {
+ float x_175 = tint_symbol.y;
+ if ((int(x_175) < 90)) {
+ int x_182 = data[2];
+ grey = (0.5f + (float(x_182) / 10.0f));
+ } else {
+ float x_187 = tint_symbol.y;
+ if ((int(x_187) < 120)) {
+ int x_194 = data[3];
+ grey = (0.5f + (float(x_194) / 10.0f));
+ } else {
+ float x_199 = tint_symbol.y;
+ if ((int(x_199) < 150)) {
+ discard;
+ } else {
+ float x_206 = tint_symbol.y;
+ if ((int(x_206) < 180)) {
+ int x_213 = data[5];
+ grey = (0.5f + (float(x_213) / 10.0f));
+ } else {
+ float x_218 = tint_symbol.y;
+ if ((int(x_218) < 210)) {
+ int x_225 = data[6];
+ grey = (0.5f + (float(x_225) / 10.0f));
+ } else {
+ float x_230 = tint_symbol.y;
+ if ((int(x_230) < 240)) {
+ int x_237 = data[7];
+ grey = (0.5f + (float(x_237) / 10.0f));
+ } else {
+ float x_242 = tint_symbol.y;
+ if ((int(x_242) < 270)) {
+ int x_249 = data[8];
+ grey = (0.5f + (float(x_249) / 10.0f));
+ } else {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_253 = grey;
+ vec3 x_254 = vec3(x_253, x_253, x_253);
+ x_GLF_color = vec4(x_254.x, x_254.y, x_254.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-mergesort-for-always-false-if-discard/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-mergesort-for-always-false-if-discard/1.spvasm.expected.glsl
new file mode 100644
index 0000000..668db46
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-mergesort-for-always-false-if-discard/1.spvasm.expected.glsl
@@ -0,0 +1,380 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_8;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+ int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+ float x_180 = 0.0f;
+ float x_279 = 0.0f;
+ int x_65_phi = 0;
+ int x_93_phi = 0;
+ int x_102_phi = 0;
+ float x_280_phi = 0.0f;
+ float x_62 = x_8.injectionSwitch.x;
+ int x_63 = int(x_62);
+ x_65_phi = x_63;
+ while (true) {
+ int x_65 = x_65_phi;
+ switch(x_65) {
+ case 9: {
+ data[x_65] = -5;
+ break;
+ }
+ case 8: {
+ data[x_65] = -4;
+ break;
+ }
+ case 7: {
+ data[x_65] = -3;
+ break;
+ }
+ case 6: {
+ data[x_65] = -2;
+ break;
+ }
+ case 5: {
+ data[x_65] = -1;
+ break;
+ }
+ case 4: {
+ data[x_65] = 0;
+ break;
+ }
+ case 3: {
+ data[x_65] = 1;
+ break;
+ }
+ case 2: {
+ data[x_65] = 2;
+ break;
+ }
+ case 1: {
+ data[x_65] = 3;
+ break;
+ }
+ case 0: {
+ data[x_65] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ int x_66 = (x_65 + 1);
+ {
+ x_65_phi = x_66;
+ if ((x_66 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ x_93_phi = 0;
+ while (true) {
+ int x_94 = 0;
+ int x_93 = x_93_phi;
+ if ((x_93 < 10)) {
+ } else {
+ break;
+ }
+ {
+ int x_99 = data[x_93];
+ temp[x_93] = x_99;
+ x_94 = (x_93 + 1);
+ x_93_phi = x_94;
+ }
+ }
+ x_102_phi = 1;
+ while (true) {
+ int x_103 = 0;
+ int x_109_phi = 0;
+ int x_102 = x_102_phi;
+ if ((x_102 <= 9)) {
+ } else {
+ break;
+ }
+ x_109_phi = 0;
+ while (true) {
+ int x_121 = 0;
+ int x_126 = 0;
+ int x_121_phi = 0;
+ int x_124_phi = 0;
+ int x_126_phi = 0;
+ int x_148_phi = 0;
+ int x_151_phi = 0;
+ int x_161_phi = 0;
+ int x_109 = x_109_phi;
+ if ((x_109 < 9)) {
+ } else {
+ break;
+ }
+ int x_115 = (x_109 + x_102);
+ int x_116 = (x_115 - 1);
+ int x_110 = (x_109 + (2 * x_102));
+ int x_119 = min((x_110 - 1), 9);
+ x_121_phi = x_109;
+ x_124_phi = x_115;
+ x_126_phi = x_109;
+ while (true) {
+ int x_141 = 0;
+ int x_144 = 0;
+ int x_125_phi = 0;
+ int x_127_phi = 0;
+ x_121 = x_121_phi;
+ int x_124 = x_124_phi;
+ x_126 = x_126_phi;
+ if (((x_126 <= x_116) & (x_124 <= x_119))) {
+ } else {
+ break;
+ }
+ int x_133_save = x_126;
+ int x_134 = data[x_133_save];
+ int x_135_save = x_124;
+ int x_136 = data[x_135_save];
+ int x_122 = (x_121 + 1);
+ if ((x_134 < x_136)) {
+ x_141 = (x_126 + 1);
+ int x_142 = data[x_133_save];
+ temp[x_121] = x_142;
+ x_125_phi = x_124;
+ x_127_phi = x_141;
+ } else {
+ x_144 = (x_124 + 1);
+ int x_145 = data[x_135_save];
+ temp[x_121] = x_145;
+ x_125_phi = x_144;
+ x_127_phi = x_126;
+ }
+ int x_125 = x_125_phi;
+ int x_127 = x_127_phi;
+ {
+ x_121_phi = x_122;
+ x_124_phi = x_125;
+ x_126_phi = x_127;
+ }
+ }
+ x_148_phi = x_121;
+ x_151_phi = x_126;
+ while (true) {
+ int x_149 = 0;
+ int x_152 = 0;
+ int x_148 = x_148_phi;
+ int x_151 = x_151_phi;
+ if (((x_151 < 10) & (x_151 <= x_116))) {
+ } else {
+ break;
+ }
+ {
+ x_149 = (x_148 + 1);
+ x_152 = (x_151 + 1);
+ int x_158 = data[x_151];
+ temp[x_148] = x_158;
+ x_148_phi = x_149;
+ x_151_phi = x_152;
+ }
+ }
+ x_161_phi = x_109;
+ while (true) {
+ int x_162 = 0;
+ int x_161 = x_161_phi;
+ if ((x_161 <= x_119)) {
+ } else {
+ break;
+ }
+ {
+ int x_167 = temp[x_161];
+ data[x_161] = x_167;
+ x_162 = (x_161 + 1);
+ x_161_phi = x_162;
+ }
+ }
+ {
+ x_109_phi = x_110;
+ }
+ }
+ {
+ x_103 = (2 * x_102);
+ x_102_phi = x_103;
+ }
+ }
+ int x_171 = 0;
+ float x_189 = 0.0f;
+ float x_278 = 0.0f;
+ float x_279_phi = 0.0f;
+ float x_170 = tint_symbol.y;
+ x_171 = int(x_170);
+ if ((x_171 < 30)) {
+ int x_177 = data[0];
+ x_180 = (0.5f + (float(x_177) * 0.100000001f));
+ x_280_phi = x_180;
+ } else {
+ float x_198 = 0.0f;
+ float x_277 = 0.0f;
+ float x_278_phi = 0.0f;
+ if ((x_171 < 60)) {
+ int x_186 = data[1];
+ x_189 = (0.5f + (float(x_186) * 0.100000001f));
+ x_279_phi = x_189;
+ } else {
+ float x_207 = 0.0f;
+ float x_249 = 0.0f;
+ float x_277_phi = 0.0f;
+ if ((x_171 < 90)) {
+ int x_195 = data[2];
+ x_198 = (0.5f + (float(x_195) * 0.100000001f));
+ x_278_phi = x_198;
+ } else {
+ if ((x_171 < 120)) {
+ int x_204 = data[3];
+ x_207 = (0.5f + (float(x_204) * 0.100000001f));
+ x_277_phi = x_207;
+ } else {
+ float x_220 = 0.0f;
+ float x_248 = 0.0f;
+ float x_249_phi = 0.0f;
+ vec2 x_256_phi = vec2(0.0f, 0.0f);
+ int x_259_phi = 0;
+ if ((x_171 < 150)) {
+ discard;
+ } else {
+ float x_229 = 0.0f;
+ float x_247 = 0.0f;
+ float x_248_phi = 0.0f;
+ if ((x_171 < 180)) {
+ int x_217 = data[5];
+ x_220 = (0.5f + (float(x_217) * 0.100000001f));
+ x_249_phi = x_220;
+ } else {
+ float x_238 = 0.0f;
+ float x_246 = 0.0f;
+ float x_247_phi = 0.0f;
+ if ((x_171 < 210)) {
+ int x_226 = data[6];
+ x_229 = (0.5f + (float(x_226) * 0.100000001f));
+ x_248_phi = x_229;
+ } else {
+ if ((x_171 < 240)) {
+ int x_235 = data[7];
+ x_238 = (0.5f + (float(x_235) * 0.100000001f));
+ x_247_phi = x_238;
+ } else {
+ if ((x_171 < 270)) {
+ } else {
+ discard;
+ }
+ int x_243 = data[8];
+ x_246 = (0.5f + (float(x_243) * 0.100000001f));
+ x_247_phi = x_246;
+ }
+ x_247 = x_247_phi;
+ x_248_phi = x_247;
+ }
+ x_248 = x_248_phi;
+ x_249_phi = x_248;
+ }
+ x_249 = x_249_phi;
+ float x_251 = x_8.injectionSwitch.y;
+ bool x_252 = (x_62 > x_251);
+ if (x_252) {
+ x_GLF_color = vec4(1.0f, 1.0f, 1.0f, 1.0f);
+ }
+ x_256_phi = vec2(1.0f, 1.0f);
+ x_259_phi = 0;
+ while (true) {
+ vec2 x_272 = vec2(0.0f, 0.0f);
+ int x_260 = 0;
+ vec2 x_273_phi = vec2(0.0f, 0.0f);
+ vec2 x_256 = x_256_phi;
+ int x_259 = x_259_phi;
+ if ((x_259 <= 32)) {
+ } else {
+ break;
+ }
+ x_273_phi = x_256;
+ if ((x_256.x < 0.0f)) {
+ if (x_252) {
+ discard;
+ }
+ x_272 = x_256;
+ x_272.y = (x_256.y + 1.0f);
+ x_273_phi = x_272;
+ }
+ vec2 x_273 = x_273_phi;
+ vec2 x_257_1 = x_273;
+ x_257_1.x = (x_273.x + x_273.y);
+ vec2 x_257 = x_257_1;
+ {
+ x_260 = (x_259 + 1);
+ x_256_phi = x_257;
+ x_259_phi = x_260;
+ }
+ }
+ }
+ x_277_phi = x_249;
+ }
+ x_277 = x_277_phi;
+ x_278_phi = x_277;
+ }
+ x_278 = x_278_phi;
+ x_279_phi = x_278;
+ }
+ x_279 = x_279_phi;
+ x_280_phi = x_279;
+ }
+ float x_280 = x_280_phi;
+ x_GLF_color = vec4(x_280, x_280, x_280, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:136: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:136: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-mergesort-reversed-for-loop/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-mergesort-reversed-for-loop/1.spvasm.expected.glsl
new file mode 100644
index 0000000..b951f6d
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-mergesort-reversed-for-loop/1.spvasm.expected.glsl
@@ -0,0 +1,301 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+
+int data[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+int temp[10] = int[10](0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_28;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void merge_i1_i1_i1_(inout int from, inout int mid, inout int to) {
+ int k = 0;
+ int i = 0;
+ int j = 0;
+ int i_1 = 0;
+ int x_262 = from;
+ k = x_262;
+ int x_263 = from;
+ i = x_263;
+ int x_264 = mid;
+ j = (x_264 + 1);
+ while (true) {
+ int x_270 = i;
+ int x_271 = mid;
+ int x_273 = j;
+ int x_274 = to;
+ if (((x_270 <= x_271) & (x_273 <= x_274))) {
+ } else {
+ break;
+ }
+ int x_280 = data[i];
+ int x_283 = data[j];
+ if ((x_280 < x_283)) {
+ int x_288 = k;
+ k = (x_288 + 1);
+ int x_290 = i;
+ i = (x_290 + 1);
+ int x_293 = data[x_290];
+ temp[x_288] = x_293;
+ } else {
+ int x_295 = k;
+ k = (x_295 + 1);
+ int x_297 = j;
+ j = (x_297 + 1);
+ int x_300 = data[x_297];
+ temp[x_295] = x_300;
+ }
+ }
+ while (true) {
+ int x_306 = i;
+ int x_308 = i;
+ int x_309 = mid;
+ if (((x_306 < 10) & (x_308 <= x_309))) {
+ } else {
+ break;
+ }
+ int x_313 = k;
+ k = (x_313 + 1);
+ int x_315 = i;
+ i = (x_315 + 1);
+ int x_318 = data[x_315];
+ temp[x_313] = x_318;
+ }
+ int x_320 = from;
+ i_1 = x_320;
+ while (true) {
+ int x_325 = i_1;
+ int x_326 = to;
+ if ((x_325 <= x_326)) {
+ } else {
+ break;
+ }
+ int x_329 = i_1;
+ int x_332 = temp[i_1];
+ data[x_329] = x_332;
+ {
+ i_1 = (i_1 + 1);
+ }
+ }
+ return;
+}
+
+void mergeSort_() {
+ int low = 0;
+ int high = 0;
+ int m = 0;
+ int i_2 = 0;
+ int from_1 = 0;
+ int mid_1 = 0;
+ int to_1 = 0;
+ int param = 0;
+ int param_1 = 0;
+ int param_2 = 0;
+ low = 0;
+ high = 9;
+ m = 1;
+ {
+ for(; (m <= high); m = (2 * m)) {
+ i_2 = low;
+ {
+ for(; (i_2 < high); i_2 = (i_2 + (2 * m))) {
+ from_1 = i_2;
+ mid_1 = ((i_2 + m) - 1);
+ to_1 = min(((i_2 + (2 * m)) - 1), high);
+ param = from_1;
+ param_1 = mid_1;
+ param_2 = to_1;
+ merge_i1_i1_i1_(param, param_1, param_2);
+ }
+ }
+ }
+ }
+ return;
+}
+
+void main_1() {
+ int i_3 = 0;
+ int j_1 = 0;
+ float grey = 0.0f;
+ int int_i = 0;
+ float x_85 = x_28.injectionSwitch.x;
+ i_3 = int(x_85);
+ while (true) {
+ switch(i_3) {
+ case 9: {
+ data[i_3] = -5;
+ break;
+ }
+ case 8: {
+ data[i_3] = -4;
+ break;
+ }
+ case 7: {
+ data[i_3] = -3;
+ break;
+ }
+ case 6: {
+ data[i_3] = -2;
+ break;
+ }
+ case 5: {
+ data[i_3] = -1;
+ break;
+ }
+ case 4: {
+ data[i_3] = 0;
+ break;
+ }
+ case 3: {
+ data[i_3] = 1;
+ break;
+ }
+ case 2: {
+ data[i_3] = 2;
+ break;
+ }
+ case 1: {
+ data[i_3] = 3;
+ break;
+ }
+ case 0: {
+ data[i_3] = 4;
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ i_3 = (i_3 + 1);
+ {
+ if ((i_3 < 10)) {
+ } else {
+ break;
+ }
+ }
+ }
+ j_1 = 0;
+ {
+ for(; (j_1 < 10); j_1 = (j_1 + 1)) {
+ int x_134 = j_1;
+ int x_137 = data[j_1];
+ temp[x_134] = x_137;
+ }
+ }
+ mergeSort_();
+ float x_143 = tint_symbol.y;
+ if ((int(x_143) < 30)) {
+ int x_150 = data[0];
+ grey = (0.5f + (float(x_150) / 10.0f));
+ } else {
+ float x_155 = tint_symbol.y;
+ if ((int(x_155) < 60)) {
+ int x_162 = data[1];
+ grey = (0.5f + (float(x_162) / 10.0f));
+ } else {
+ float x_167 = tint_symbol.y;
+ if ((int(x_167) < 90)) {
+ int x_174 = data[2];
+ grey = (0.5f + (float(x_174) / 10.0f));
+ } else {
+ float x_179 = tint_symbol.y;
+ if ((int(x_179) < 120)) {
+ int x_186 = data[3];
+ grey = (0.5f + (float(x_186) / 10.0f));
+ } else {
+ float x_191 = tint_symbol.y;
+ if ((int(x_191) < 150)) {
+ int_i = 1;
+ while (true) {
+ int x_201 = int_i;
+ float x_203 = x_28.injectionSwitch.x;
+ if ((x_201 > int(x_203))) {
+ } else {
+ break;
+ }
+ discard;
+ }
+ } else {
+ float x_208 = tint_symbol.y;
+ if ((int(x_208) < 180)) {
+ int x_215 = data[5];
+ grey = (0.5f + (float(x_215) / 10.0f));
+ } else {
+ float x_220 = tint_symbol.y;
+ if ((int(x_220) < 210)) {
+ int x_227 = data[6];
+ grey = (0.5f + (float(x_227) / 10.0f));
+ } else {
+ float x_232 = tint_symbol.y;
+ if ((int(x_232) < 240)) {
+ int x_239 = data[7];
+ grey = (0.5f + (float(x_239) / 10.0f));
+ } else {
+ float x_244 = tint_symbol.y;
+ if ((int(x_244) < 270)) {
+ int x_251 = data[8];
+ grey = (0.5f + (float(x_251) / 10.0f));
+ } else {
+ discard;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ float x_255 = grey;
+ vec3 x_256 = vec3(x_255, x_255, x_255);
+ x_GLF_color = vec4(x_256.x, x_256.y, x_256.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:32: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:32: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-array-nested-loop/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-array-nested-loop/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..1023ec7
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-array-nested-loop/0-opt.spvasm.expected.glsl
@@ -0,0 +1,174 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_24;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+float cross2d_vf2_vf2_(inout vec2 a, inout vec2 b) {
+ float x_79 = a.x;
+ float x_81 = b.y;
+ float x_84 = b.x;
+ float x_86 = a.y;
+ return ((x_79 * x_81) - (x_84 * x_86));
+}
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a_1, inout vec2 b_1, inout vec2 c) {
+ bool x_90 = false;
+ int x_91 = 0;
+ float pab = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ float pbc = 0.0f;
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ float pca = 0.0f;
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_140 = false;
+ bool x_168 = false;
+ bool x_141_phi = false;
+ bool x_169_phi = false;
+ int x_173_phi = 0;
+ switch(0u) {
+ default: {
+ float x_95 = p.x;
+ float x_97 = a_1.x;
+ float x_100 = p.y;
+ float x_102 = a_1.y;
+ float x_106 = b_1.x;
+ float x_107 = a_1.x;
+ float x_110 = b_1.y;
+ float x_111 = a_1.y;
+ param = vec2((x_95 - x_97), (x_100 - x_102));
+ param_1 = vec2((x_106 - x_107), (x_110 - x_111));
+ float x_114 = cross2d_vf2_vf2_(param, param_1);
+ pab = x_114;
+ float x_115 = p.x;
+ float x_116 = b_1.x;
+ float x_118 = p.y;
+ float x_119 = b_1.y;
+ float x_123 = c.x;
+ float x_124 = b_1.x;
+ float x_127 = c.y;
+ float x_128 = b_1.y;
+ param_2 = vec2((x_115 - x_116), (x_118 - x_119));
+ param_3 = vec2((x_123 - x_124), (x_127 - x_128));
+ float x_131 = cross2d_vf2_vf2_(param_2, param_3);
+ pbc = x_131;
+ bool x_134 = ((x_114 < 0.0f) & (x_131 < 0.0f));
+ x_141_phi = x_134;
+ if (!(x_134)) {
+ x_140 = ((x_114 >= 0.0f) & (x_131 >= 0.0f));
+ x_141_phi = x_140;
+ }
+ if (!(x_141_phi)) {
+ x_90 = true;
+ x_91 = 0;
+ x_173_phi = 0;
+ break;
+ }
+ float x_145 = p.x;
+ float x_146 = c.x;
+ float x_148 = p.y;
+ float x_149 = c.y;
+ float x_152 = a_1.x;
+ float x_153 = c.x;
+ float x_155 = a_1.y;
+ float x_156 = c.y;
+ param_4 = vec2((x_145 - x_146), (x_148 - x_149));
+ param_5 = vec2((x_152 - x_153), (x_155 - x_156));
+ float x_159 = cross2d_vf2_vf2_(param_4, param_5);
+ pca = x_159;
+ bool x_162 = ((x_114 < 0.0f) & (x_159 < 0.0f));
+ x_169_phi = x_162;
+ if (!(x_162)) {
+ x_168 = ((x_114 >= 0.0f) & (x_159 >= 0.0f));
+ x_169_phi = x_168;
+ }
+ if (!(x_169_phi)) {
+ x_90 = true;
+ x_91 = 0;
+ x_173_phi = 0;
+ break;
+ }
+ x_90 = true;
+ x_91 = 1;
+ x_173_phi = 1;
+ break;
+ }
+ }
+ return x_173_phi;
+}
+
+void main_1() {
+ vec2 pos = vec2(0.0f, 0.0f);
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_67 = tint_symbol;
+ vec2 x_70 = x_24.resolution;
+ vec2 x_71 = (vec2(x_67.x, x_67.y) / x_70);
+ pos = x_71;
+ param_6 = x_71;
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_72 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_72 == 1)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:65: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:65: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-array-nested-loop/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-array-nested-loop/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..1023ec7
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-array-nested-loop/0-opt.wgsl.expected.glsl
@@ -0,0 +1,174 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_24;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+float cross2d_vf2_vf2_(inout vec2 a, inout vec2 b) {
+ float x_79 = a.x;
+ float x_81 = b.y;
+ float x_84 = b.x;
+ float x_86 = a.y;
+ return ((x_79 * x_81) - (x_84 * x_86));
+}
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a_1, inout vec2 b_1, inout vec2 c) {
+ bool x_90 = false;
+ int x_91 = 0;
+ float pab = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ float pbc = 0.0f;
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ float pca = 0.0f;
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_140 = false;
+ bool x_168 = false;
+ bool x_141_phi = false;
+ bool x_169_phi = false;
+ int x_173_phi = 0;
+ switch(0u) {
+ default: {
+ float x_95 = p.x;
+ float x_97 = a_1.x;
+ float x_100 = p.y;
+ float x_102 = a_1.y;
+ float x_106 = b_1.x;
+ float x_107 = a_1.x;
+ float x_110 = b_1.y;
+ float x_111 = a_1.y;
+ param = vec2((x_95 - x_97), (x_100 - x_102));
+ param_1 = vec2((x_106 - x_107), (x_110 - x_111));
+ float x_114 = cross2d_vf2_vf2_(param, param_1);
+ pab = x_114;
+ float x_115 = p.x;
+ float x_116 = b_1.x;
+ float x_118 = p.y;
+ float x_119 = b_1.y;
+ float x_123 = c.x;
+ float x_124 = b_1.x;
+ float x_127 = c.y;
+ float x_128 = b_1.y;
+ param_2 = vec2((x_115 - x_116), (x_118 - x_119));
+ param_3 = vec2((x_123 - x_124), (x_127 - x_128));
+ float x_131 = cross2d_vf2_vf2_(param_2, param_3);
+ pbc = x_131;
+ bool x_134 = ((x_114 < 0.0f) & (x_131 < 0.0f));
+ x_141_phi = x_134;
+ if (!(x_134)) {
+ x_140 = ((x_114 >= 0.0f) & (x_131 >= 0.0f));
+ x_141_phi = x_140;
+ }
+ if (!(x_141_phi)) {
+ x_90 = true;
+ x_91 = 0;
+ x_173_phi = 0;
+ break;
+ }
+ float x_145 = p.x;
+ float x_146 = c.x;
+ float x_148 = p.y;
+ float x_149 = c.y;
+ float x_152 = a_1.x;
+ float x_153 = c.x;
+ float x_155 = a_1.y;
+ float x_156 = c.y;
+ param_4 = vec2((x_145 - x_146), (x_148 - x_149));
+ param_5 = vec2((x_152 - x_153), (x_155 - x_156));
+ float x_159 = cross2d_vf2_vf2_(param_4, param_5);
+ pca = x_159;
+ bool x_162 = ((x_114 < 0.0f) & (x_159 < 0.0f));
+ x_169_phi = x_162;
+ if (!(x_162)) {
+ x_168 = ((x_114 >= 0.0f) & (x_159 >= 0.0f));
+ x_169_phi = x_168;
+ }
+ if (!(x_169_phi)) {
+ x_90 = true;
+ x_91 = 0;
+ x_173_phi = 0;
+ break;
+ }
+ x_90 = true;
+ x_91 = 1;
+ x_173_phi = 1;
+ break;
+ }
+ }
+ return x_173_phi;
+}
+
+void main_1() {
+ vec2 pos = vec2(0.0f, 0.0f);
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_67 = tint_symbol;
+ vec2 x_70 = x_24.resolution;
+ vec2 x_71 = (vec2(x_67.x, x_67.y) / x_70);
+ pos = x_71;
+ param_6 = x_71;
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_72 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_72 == 1)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:65: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:65: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/0.spvasm.expected.glsl
new file mode 100644
index 0000000..586b41d
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/0.spvasm.expected.glsl
@@ -0,0 +1,156 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_24;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+float cross2d_vf2_vf2_(inout vec2 a, inout vec2 b) {
+ float x_76 = a.x;
+ float x_78 = b.y;
+ float x_81 = b.x;
+ float x_83 = a.y;
+ return ((x_76 * x_78) - (x_81 * x_83));
+}
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a_1, inout vec2 b_1, inout vec2 c) {
+ float pab = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ float pbc = 0.0f;
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ float pca = 0.0f;
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_137 = false;
+ bool x_169 = false;
+ bool x_138_phi = false;
+ bool x_170_phi = false;
+ float x_88 = p.x;
+ float x_90 = a_1.x;
+ float x_93 = p.y;
+ float x_95 = a_1.y;
+ float x_99 = b_1.x;
+ float x_100 = a_1.x;
+ float x_103 = b_1.y;
+ float x_104 = a_1.y;
+ param = vec2((x_88 - x_90), (x_93 - x_95));
+ param_1 = vec2((x_99 - x_100), (x_103 - x_104));
+ float x_107 = cross2d_vf2_vf2_(param, param_1);
+ pab = x_107;
+ float x_108 = p.x;
+ float x_109 = b_1.x;
+ float x_111 = p.y;
+ float x_112 = b_1.y;
+ float x_116 = c.x;
+ float x_117 = b_1.x;
+ float x_120 = c.y;
+ float x_121 = b_1.y;
+ param_2 = vec2((x_108 - x_109), (x_111 - x_112));
+ param_3 = vec2((x_116 - x_117), (x_120 - x_121));
+ float x_124 = cross2d_vf2_vf2_(param_2, param_3);
+ pbc = x_124;
+ bool x_129 = ((pab < 0.0f) & (pbc < 0.0f));
+ x_138_phi = x_129;
+ if (!(x_129)) {
+ x_137 = ((pab >= 0.0f) & (pbc >= 0.0f));
+ x_138_phi = x_137;
+ }
+ if (!(x_138_phi)) {
+ return 0;
+ }
+ float x_142 = p.x;
+ float x_143 = c.x;
+ float x_145 = p.y;
+ float x_146 = c.y;
+ float x_149 = a_1.x;
+ float x_150 = c.x;
+ float x_152 = a_1.y;
+ float x_153 = c.y;
+ param_4 = vec2((x_142 - x_143), (x_145 - x_146));
+ param_5 = vec2((x_149 - x_150), (x_152 - x_153));
+ float x_156 = cross2d_vf2_vf2_(param_4, param_5);
+ pca = x_156;
+ bool x_161 = ((pab < 0.0f) & (pca < 0.0f));
+ x_170_phi = x_161;
+ if (!(x_161)) {
+ x_169 = ((pab >= 0.0f) & (pca >= 0.0f));
+ x_170_phi = x_169;
+ }
+ if (!(x_170_phi)) {
+ return 0;
+ }
+ return 1;
+}
+
+void main_1() {
+ vec2 pos = vec2(0.0f, 0.0f);
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_63 = tint_symbol;
+ vec2 x_66 = x_24.resolution;
+ pos = (vec2(x_63.x, x_63.y) / x_66);
+ param_6 = pos;
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_69 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_69 == 1)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:60: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:60: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/0.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/0.wgsl.expected.glsl
new file mode 100644
index 0000000..586b41d
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/0.wgsl.expected.glsl
@@ -0,0 +1,156 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_24;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+float cross2d_vf2_vf2_(inout vec2 a, inout vec2 b) {
+ float x_76 = a.x;
+ float x_78 = b.y;
+ float x_81 = b.x;
+ float x_83 = a.y;
+ return ((x_76 * x_78) - (x_81 * x_83));
+}
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a_1, inout vec2 b_1, inout vec2 c) {
+ float pab = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ float pbc = 0.0f;
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ float pca = 0.0f;
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_137 = false;
+ bool x_169 = false;
+ bool x_138_phi = false;
+ bool x_170_phi = false;
+ float x_88 = p.x;
+ float x_90 = a_1.x;
+ float x_93 = p.y;
+ float x_95 = a_1.y;
+ float x_99 = b_1.x;
+ float x_100 = a_1.x;
+ float x_103 = b_1.y;
+ float x_104 = a_1.y;
+ param = vec2((x_88 - x_90), (x_93 - x_95));
+ param_1 = vec2((x_99 - x_100), (x_103 - x_104));
+ float x_107 = cross2d_vf2_vf2_(param, param_1);
+ pab = x_107;
+ float x_108 = p.x;
+ float x_109 = b_1.x;
+ float x_111 = p.y;
+ float x_112 = b_1.y;
+ float x_116 = c.x;
+ float x_117 = b_1.x;
+ float x_120 = c.y;
+ float x_121 = b_1.y;
+ param_2 = vec2((x_108 - x_109), (x_111 - x_112));
+ param_3 = vec2((x_116 - x_117), (x_120 - x_121));
+ float x_124 = cross2d_vf2_vf2_(param_2, param_3);
+ pbc = x_124;
+ bool x_129 = ((pab < 0.0f) & (pbc < 0.0f));
+ x_138_phi = x_129;
+ if (!(x_129)) {
+ x_137 = ((pab >= 0.0f) & (pbc >= 0.0f));
+ x_138_phi = x_137;
+ }
+ if (!(x_138_phi)) {
+ return 0;
+ }
+ float x_142 = p.x;
+ float x_143 = c.x;
+ float x_145 = p.y;
+ float x_146 = c.y;
+ float x_149 = a_1.x;
+ float x_150 = c.x;
+ float x_152 = a_1.y;
+ float x_153 = c.y;
+ param_4 = vec2((x_142 - x_143), (x_145 - x_146));
+ param_5 = vec2((x_149 - x_150), (x_152 - x_153));
+ float x_156 = cross2d_vf2_vf2_(param_4, param_5);
+ pca = x_156;
+ bool x_161 = ((pab < 0.0f) & (pca < 0.0f));
+ x_170_phi = x_161;
+ if (!(x_161)) {
+ x_169 = ((pab >= 0.0f) & (pca >= 0.0f));
+ x_170_phi = x_169;
+ }
+ if (!(x_170_phi)) {
+ return 0;
+ }
+ return 1;
+}
+
+void main_1() {
+ vec2 pos = vec2(0.0f, 0.0f);
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_63 = tint_symbol;
+ vec2 x_66 = x_24.resolution;
+ pos = (vec2(x_63.x, x_63.y) / x_66);
+ param_6 = pos;
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_69 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_69 == 1)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:60: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:60: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/1.spvasm.expected.glsl
new file mode 100644
index 0000000..146bb49
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/1.spvasm.expected.glsl
@@ -0,0 +1,183 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_15;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+float cross2d_vf2_vf2_(inout vec2 a, inout vec2 b) {
+ float x_85 = a.x;
+ float x_87 = b.y;
+ float x_90 = b.x;
+ float x_92 = a.y;
+ return ((x_85 * x_87) - (x_90 * x_92));
+}
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a_1, inout vec2 b_1, inout vec2 c) {
+ float var_y = 0.0f;
+ float x_96 = 0.0f;
+ float x_97 = 0.0f;
+ float clamp_y = 0.0f;
+ float pab = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ float pbc = 0.0f;
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ float pca = 0.0f;
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_173 = false;
+ bool x_205 = false;
+ bool x_174_phi = false;
+ bool x_206_phi = false;
+ float x_99 = x_15.resolution.x;
+ float x_101 = x_15.resolution.y;
+ if ((x_99 == x_101)) {
+ float x_107 = c.y;
+ vec2 x_108 = vec2(0.0f, x_107);
+ if (true) {
+ float x_112 = c.y;
+ x_97 = x_112;
+ } else {
+ x_97 = 1.0f;
+ }
+ float x_113 = x_97;
+ float x_114 = c.y;
+ vec2 x_116 = vec2(1.0f, max(x_113, x_114));
+ vec2 x_117 = vec2(x_108.x, x_108.y);
+ x_96 = x_107;
+ } else {
+ x_96 = -1.0f;
+ }
+ var_y = x_96;
+ float x_120 = c.y;
+ float x_121 = c.y;
+ clamp_y = clamp(x_120, x_121, var_y);
+ float x_125 = p.x;
+ float x_127 = a_1.x;
+ float x_130 = p.y;
+ float x_132 = a_1.y;
+ float x_136 = b_1.x;
+ float x_137 = a_1.x;
+ float x_140 = b_1.y;
+ float x_141 = a_1.y;
+ param = vec2((x_125 - x_127), (x_130 - x_132));
+ param_1 = vec2((x_136 - x_137), (x_140 - x_141));
+ float x_144 = cross2d_vf2_vf2_(param, param_1);
+ pab = x_144;
+ float x_145 = p.x;
+ float x_146 = b_1.x;
+ float x_148 = p.y;
+ float x_149 = b_1.y;
+ float x_153 = c.x;
+ float x_154 = b_1.x;
+ float x_156 = clamp_y;
+ float x_157 = b_1.y;
+ param_2 = vec2((x_145 - x_146), (x_148 - x_149));
+ param_3 = vec2((x_153 - x_154), (x_156 - x_157));
+ float x_160 = cross2d_vf2_vf2_(param_2, param_3);
+ pbc = x_160;
+ bool x_165 = ((pab < 0.0f) & (pbc < 0.0f));
+ x_174_phi = x_165;
+ if (!(x_165)) {
+ x_173 = ((pab >= 0.0f) & (pbc >= 0.0f));
+ x_174_phi = x_173;
+ }
+ if (!(x_174_phi)) {
+ return 0;
+ }
+ float x_178 = p.x;
+ float x_179 = c.x;
+ float x_181 = p.y;
+ float x_182 = c.y;
+ float x_185 = a_1.x;
+ float x_186 = c.x;
+ float x_188 = a_1.y;
+ float x_189 = c.y;
+ param_4 = vec2((x_178 - x_179), (x_181 - x_182));
+ param_5 = vec2((x_185 - x_186), (x_188 - x_189));
+ float x_192 = cross2d_vf2_vf2_(param_4, param_5);
+ pca = x_192;
+ bool x_197 = ((pab < 0.0f) & (pca < 0.0f));
+ x_206_phi = x_197;
+ if (!(x_197)) {
+ x_205 = ((pab >= 0.0f) & (pca >= 0.0f));
+ x_206_phi = x_205;
+ }
+ if (!(x_206_phi)) {
+ return 0;
+ }
+ return 1;
+}
+
+void main_1() {
+ vec2 pos = vec2(0.0f, 0.0f);
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_72 = tint_symbol;
+ vec2 x_75 = x_15.resolution;
+ pos = (vec2(x_72.x, x_72.y) / x_75);
+ param_6 = pos;
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_78 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_78 == 1)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:87: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:87: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/1.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/1.wgsl.expected.glsl
new file mode 100644
index 0000000..146bb49
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-clamp-conditional-mix/1.wgsl.expected.glsl
@@ -0,0 +1,183 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_15;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+float cross2d_vf2_vf2_(inout vec2 a, inout vec2 b) {
+ float x_85 = a.x;
+ float x_87 = b.y;
+ float x_90 = b.x;
+ float x_92 = a.y;
+ return ((x_85 * x_87) - (x_90 * x_92));
+}
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a_1, inout vec2 b_1, inout vec2 c) {
+ float var_y = 0.0f;
+ float x_96 = 0.0f;
+ float x_97 = 0.0f;
+ float clamp_y = 0.0f;
+ float pab = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ float pbc = 0.0f;
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ float pca = 0.0f;
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_173 = false;
+ bool x_205 = false;
+ bool x_174_phi = false;
+ bool x_206_phi = false;
+ float x_99 = x_15.resolution.x;
+ float x_101 = x_15.resolution.y;
+ if ((x_99 == x_101)) {
+ float x_107 = c.y;
+ vec2 x_108 = vec2(0.0f, x_107);
+ if (true) {
+ float x_112 = c.y;
+ x_97 = x_112;
+ } else {
+ x_97 = 1.0f;
+ }
+ float x_113 = x_97;
+ float x_114 = c.y;
+ vec2 x_116 = vec2(1.0f, max(x_113, x_114));
+ vec2 x_117 = vec2(x_108.x, x_108.y);
+ x_96 = x_107;
+ } else {
+ x_96 = -1.0f;
+ }
+ var_y = x_96;
+ float x_120 = c.y;
+ float x_121 = c.y;
+ clamp_y = clamp(x_120, x_121, var_y);
+ float x_125 = p.x;
+ float x_127 = a_1.x;
+ float x_130 = p.y;
+ float x_132 = a_1.y;
+ float x_136 = b_1.x;
+ float x_137 = a_1.x;
+ float x_140 = b_1.y;
+ float x_141 = a_1.y;
+ param = vec2((x_125 - x_127), (x_130 - x_132));
+ param_1 = vec2((x_136 - x_137), (x_140 - x_141));
+ float x_144 = cross2d_vf2_vf2_(param, param_1);
+ pab = x_144;
+ float x_145 = p.x;
+ float x_146 = b_1.x;
+ float x_148 = p.y;
+ float x_149 = b_1.y;
+ float x_153 = c.x;
+ float x_154 = b_1.x;
+ float x_156 = clamp_y;
+ float x_157 = b_1.y;
+ param_2 = vec2((x_145 - x_146), (x_148 - x_149));
+ param_3 = vec2((x_153 - x_154), (x_156 - x_157));
+ float x_160 = cross2d_vf2_vf2_(param_2, param_3);
+ pbc = x_160;
+ bool x_165 = ((pab < 0.0f) & (pbc < 0.0f));
+ x_174_phi = x_165;
+ if (!(x_165)) {
+ x_173 = ((pab >= 0.0f) & (pbc >= 0.0f));
+ x_174_phi = x_173;
+ }
+ if (!(x_174_phi)) {
+ return 0;
+ }
+ float x_178 = p.x;
+ float x_179 = c.x;
+ float x_181 = p.y;
+ float x_182 = c.y;
+ float x_185 = a_1.x;
+ float x_186 = c.x;
+ float x_188 = a_1.y;
+ float x_189 = c.y;
+ param_4 = vec2((x_178 - x_179), (x_181 - x_182));
+ param_5 = vec2((x_185 - x_186), (x_188 - x_189));
+ float x_192 = cross2d_vf2_vf2_(param_4, param_5);
+ pca = x_192;
+ bool x_197 = ((pab < 0.0f) & (pca < 0.0f));
+ x_206_phi = x_197;
+ if (!(x_197)) {
+ x_205 = ((pab >= 0.0f) & (pca >= 0.0f));
+ x_206_phi = x_205;
+ }
+ if (!(x_206_phi)) {
+ return 0;
+ }
+ return 1;
+}
+
+void main_1() {
+ vec2 pos = vec2(0.0f, 0.0f);
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_72 = tint_symbol;
+ vec2 x_75 = x_15.resolution;
+ pos = (vec2(x_72.x, x_72.y) / x_75);
+ param_6 = pos;
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_78 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_78 == 1)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:87: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:87: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-conditional-clamped-float/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-conditional-clamped-float/0.spvasm.expected.glsl
new file mode 100644
index 0000000..58b6985
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-conditional-clamped-float/0.spvasm.expected.glsl
@@ -0,0 +1,156 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_24;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+float cross2d_vf2_vf2_(inout vec2 a, inout vec2 b) {
+ float x_76 = a.x;
+ float x_78 = b.y;
+ float x_81 = b.x;
+ float x_83 = a.y;
+ return ((x_76 * x_78) - (x_81 * x_83));
+}
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a_1, inout vec2 b_1, inout vec2 c) {
+ float pab = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ float pbc = 0.0f;
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ float pca = 0.0f;
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_145 = false;
+ bool x_185 = false;
+ bool x_146_phi = false;
+ bool x_186_phi = false;
+ float x_88 = p.x;
+ float x_90 = a_1.x;
+ float x_93 = p.y;
+ float x_95 = a_1.y;
+ float x_99 = b_1.x;
+ float x_101 = a_1.x;
+ float x_104 = b_1.y;
+ float x_106 = a_1.y;
+ param = vec2((x_88 - x_90), (x_93 - x_95));
+ param_1 = vec2((x_99 - x_101), (x_104 - x_106));
+ float x_109 = cross2d_vf2_vf2_(param, param_1);
+ pab = x_109;
+ float x_111 = p.x;
+ float x_113 = b_1.x;
+ float x_116 = p.y;
+ float x_118 = b_1.y;
+ float x_122 = c.x;
+ float x_124 = b_1.x;
+ float x_127 = c.y;
+ float x_129 = b_1.y;
+ param_2 = vec2((x_111 - x_113), (x_116 - x_118));
+ param_3 = vec2((x_122 - x_124), (x_127 - x_129));
+ float x_132 = cross2d_vf2_vf2_(param_2, param_3);
+ pbc = x_132;
+ bool x_137 = ((pab < 0.0f) & (pbc < 0.0f));
+ x_146_phi = x_137;
+ if (!(x_137)) {
+ x_145 = ((pab >= 0.0f) & (pbc >= 0.0f));
+ x_146_phi = x_145;
+ }
+ if (!(x_146_phi)) {
+ return 0;
+ }
+ float x_151 = p.x;
+ float x_153 = c.x;
+ float x_156 = p.y;
+ float x_158 = c.y;
+ float x_162 = a_1.x;
+ float x_164 = c.x;
+ float x_167 = a_1.y;
+ float x_169 = c.y;
+ param_4 = vec2((x_151 - x_153), (x_156 - x_158));
+ param_5 = vec2((x_162 - x_164), (x_167 - x_169));
+ float x_172 = cross2d_vf2_vf2_(param_4, param_5);
+ pca = x_172;
+ bool x_177 = ((pab < 0.0f) & (pca < 0.0f));
+ x_186_phi = x_177;
+ if (!(x_177)) {
+ x_185 = ((pab >= 0.0f) & (pca >= 0.0f));
+ x_186_phi = x_185;
+ }
+ if (!(x_186_phi)) {
+ return 0;
+ }
+ return 1;
+}
+
+void main_1() {
+ vec2 pos = vec2(0.0f, 0.0f);
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_63 = tint_symbol;
+ vec2 x_66 = x_24.resolution;
+ pos = (vec2(x_63.x, x_63.y) / x_66);
+ param_6 = pos;
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_69 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_69 == 1)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:60: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:60: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/0.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/0.spvasm.expected.glsl
new file mode 100644
index 0000000..625593a
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/0.spvasm.expected.glsl
@@ -0,0 +1,159 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_17;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a, inout vec2 b, inout vec2 c) {
+ float x_66 = 0.0f;
+ float x_67 = 0.0f;
+ float x_68 = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_135 = false;
+ bool x_172 = false;
+ bool x_136_phi = false;
+ bool x_173_phi = false;
+ float x_70 = p.x;
+ float x_72 = a.x;
+ float x_75 = p.y;
+ float x_77 = a.y;
+ float x_81 = b.x;
+ float x_82 = a.x;
+ float x_85 = b.y;
+ float x_86 = a.y;
+ param = vec2((x_70 - x_72), (x_75 - x_77));
+ param_1 = vec2((x_81 - x_82), (x_85 - x_86));
+ float x_90 = param.x;
+ float x_92 = param_1.y;
+ float x_95 = param_1.x;
+ float x_97 = param.y;
+ float x_99 = ((x_90 * x_92) - (x_95 * x_97));
+ x_68 = x_99;
+ float x_100 = p.x;
+ float x_101 = b.x;
+ float x_103 = p.y;
+ float x_104 = b.y;
+ float x_108 = c.x;
+ float x_109 = b.x;
+ float x_112 = c.y;
+ float x_113 = b.y;
+ param_2 = vec2((x_100 - x_101), (x_103 - x_104));
+ param_3 = vec2((x_108 - x_109), (x_112 - x_113));
+ float x_117 = param_2.x;
+ float x_119 = param_3.y;
+ float x_122 = param_3.x;
+ float x_124 = param_2.y;
+ float x_126 = ((x_117 * x_119) - (x_122 * x_124));
+ x_67 = x_126;
+ bool x_127 = (x_99 < 0.0f);
+ bool x_129 = (x_127 & (x_126 < 0.0f));
+ x_136_phi = x_129;
+ if (!(x_129)) {
+ x_135 = ((x_99 >= 0.0f) & (x_126 >= 0.0f));
+ x_136_phi = x_135;
+ }
+ if (!(x_136_phi)) {
+ return 0;
+ }
+ float x_140 = p.x;
+ float x_141 = c.x;
+ float x_143 = p.y;
+ float x_144 = c.y;
+ float x_147 = a.x;
+ float x_148 = c.x;
+ float x_150 = a.y;
+ float x_151 = c.y;
+ param_4 = vec2((x_140 - x_141), (x_143 - x_144));
+ param_5 = vec2((x_147 - x_148), (x_150 - x_151));
+ float x_155 = param_4.x;
+ float x_157 = param_5.y;
+ float x_160 = param_5.x;
+ float x_162 = param_4.y;
+ float x_164 = ((x_155 * x_157) - (x_160 * x_162));
+ x_66 = x_164;
+ bool x_166 = (x_127 & (x_164 < 0.0f));
+ x_173_phi = x_166;
+ if (!(x_166)) {
+ x_172 = ((x_99 >= 0.0f) & (x_164 >= 0.0f));
+ x_173_phi = x_172;
+ }
+ if (!(x_173_phi)) {
+ return 0;
+ }
+ return 1;
+}
+
+void main_1() {
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_55 = tint_symbol;
+ vec2 x_58 = x_17.resolution;
+ param_6 = (vec2(x_55.x, x_55.y) / x_58);
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_60 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_60 == 1)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:61: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:61: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/0.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/0.wgsl.expected.glsl
new file mode 100644
index 0000000..625593a
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/0.wgsl.expected.glsl
@@ -0,0 +1,159 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 resolution;
+};
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_17;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a, inout vec2 b, inout vec2 c) {
+ float x_66 = 0.0f;
+ float x_67 = 0.0f;
+ float x_68 = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_135 = false;
+ bool x_172 = false;
+ bool x_136_phi = false;
+ bool x_173_phi = false;
+ float x_70 = p.x;
+ float x_72 = a.x;
+ float x_75 = p.y;
+ float x_77 = a.y;
+ float x_81 = b.x;
+ float x_82 = a.x;
+ float x_85 = b.y;
+ float x_86 = a.y;
+ param = vec2((x_70 - x_72), (x_75 - x_77));
+ param_1 = vec2((x_81 - x_82), (x_85 - x_86));
+ float x_90 = param.x;
+ float x_92 = param_1.y;
+ float x_95 = param_1.x;
+ float x_97 = param.y;
+ float x_99 = ((x_90 * x_92) - (x_95 * x_97));
+ x_68 = x_99;
+ float x_100 = p.x;
+ float x_101 = b.x;
+ float x_103 = p.y;
+ float x_104 = b.y;
+ float x_108 = c.x;
+ float x_109 = b.x;
+ float x_112 = c.y;
+ float x_113 = b.y;
+ param_2 = vec2((x_100 - x_101), (x_103 - x_104));
+ param_3 = vec2((x_108 - x_109), (x_112 - x_113));
+ float x_117 = param_2.x;
+ float x_119 = param_3.y;
+ float x_122 = param_3.x;
+ float x_124 = param_2.y;
+ float x_126 = ((x_117 * x_119) - (x_122 * x_124));
+ x_67 = x_126;
+ bool x_127 = (x_99 < 0.0f);
+ bool x_129 = (x_127 & (x_126 < 0.0f));
+ x_136_phi = x_129;
+ if (!(x_129)) {
+ x_135 = ((x_99 >= 0.0f) & (x_126 >= 0.0f));
+ x_136_phi = x_135;
+ }
+ if (!(x_136_phi)) {
+ return 0;
+ }
+ float x_140 = p.x;
+ float x_141 = c.x;
+ float x_143 = p.y;
+ float x_144 = c.y;
+ float x_147 = a.x;
+ float x_148 = c.x;
+ float x_150 = a.y;
+ float x_151 = c.y;
+ param_4 = vec2((x_140 - x_141), (x_143 - x_144));
+ param_5 = vec2((x_147 - x_148), (x_150 - x_151));
+ float x_155 = param_4.x;
+ float x_157 = param_5.y;
+ float x_160 = param_5.x;
+ float x_162 = param_4.y;
+ float x_164 = ((x_155 * x_157) - (x_160 * x_162));
+ x_66 = x_164;
+ bool x_166 = (x_127 & (x_164 < 0.0f));
+ x_173_phi = x_166;
+ if (!(x_166)) {
+ x_172 = ((x_99 >= 0.0f) & (x_164 >= 0.0f));
+ x_173_phi = x_172;
+ }
+ if (!(x_173_phi)) {
+ return 0;
+ }
+ return 1;
+}
+
+void main_1() {
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_55 = tint_symbol;
+ vec2 x_58 = x_17.resolution;
+ param_6 = (vec2(x_55.x, x_55.y) / x_58);
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_60 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_60 == 1)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:61: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:61: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/1.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/1.spvasm.expected.glsl
new file mode 100644
index 0000000..a41fe75
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/1.spvasm.expected.glsl
@@ -0,0 +1,201 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf1 {
+ vec2 injectionSwitch;
+};
+struct buf0 {
+ vec2 resolution;
+};
+
+layout (binding = 1) uniform buf1_1 {
+ vec2 injectionSwitch;
+} x_11;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_19;
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a, inout vec2 b, inout vec2 c) {
+ float x_78 = 0.0f;
+ float x_79 = 0.0f;
+ float x_80 = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_147 = false;
+ bool x_203 = false;
+ bool x_148_phi = false;
+ bool x_204_phi = false;
+ float x_82 = p.x;
+ float x_84 = a.x;
+ float x_87 = p.y;
+ float x_89 = a.y;
+ float x_93 = b.x;
+ float x_94 = a.x;
+ float x_97 = b.y;
+ float x_98 = a.y;
+ param = vec2((x_82 - x_84), (x_87 - x_89));
+ param_1 = vec2((x_93 - x_94), (x_97 - x_98));
+ float x_102 = param.x;
+ float x_104 = param_1.y;
+ float x_107 = param_1.x;
+ float x_109 = param.y;
+ float x_111 = ((x_102 * x_104) - (x_107 * x_109));
+ x_80 = x_111;
+ float x_112 = p.x;
+ float x_113 = b.x;
+ float x_115 = p.y;
+ float x_116 = b.y;
+ float x_120 = c.x;
+ float x_121 = b.x;
+ float x_124 = c.y;
+ float x_125 = b.y;
+ param_2 = vec2((x_112 - x_113), (x_115 - x_116));
+ param_3 = vec2((x_120 - x_121), (x_124 - x_125));
+ float x_129 = param_2.x;
+ float x_131 = param_3.y;
+ float x_134 = param_3.x;
+ float x_136 = param_2.y;
+ float x_138 = ((x_129 * x_131) - (x_134 * x_136));
+ x_79 = x_138;
+ bool x_139 = (x_111 < 0.0f);
+ bool x_141 = (x_139 & (x_138 < 0.0f));
+ x_148_phi = x_141;
+ if (!(x_141)) {
+ x_147 = ((x_111 >= 0.0f) & (x_138 >= 0.0f));
+ x_148_phi = x_147;
+ }
+ int x_153_phi = 0;
+ if (!(x_148_phi)) {
+ x_153_phi = 0;
+ while (true) {
+ int x_154 = 0;
+ int x_164_phi = 0;
+ int x_153 = x_153_phi;
+ float x_159 = x_11.injectionSwitch.y;
+ int x_160 = int(x_159);
+ if ((x_153 < x_160)) {
+ } else {
+ break;
+ }
+ x_GLF_color = vec4(1.0f, 1.0f, 1.0f, 1.0f);
+ x_164_phi = 0;
+ while (true) {
+ int x_165 = 0;
+ int x_164 = x_164_phi;
+ if ((x_164 < x_160)) {
+ } else {
+ break;
+ }
+ x_GLF_color = vec4(1.0f, 1.0f, 1.0f, 1.0f);
+ {
+ x_165 = (x_164 + 1);
+ x_164_phi = x_165;
+ }
+ }
+ {
+ x_154 = (x_153 + 1);
+ x_153_phi = x_154;
+ }
+ }
+ return 0;
+ }
+ float x_171 = p.x;
+ float x_172 = c.x;
+ float x_174 = p.y;
+ float x_175 = c.y;
+ float x_178 = a.x;
+ float x_179 = c.x;
+ float x_181 = a.y;
+ float x_182 = c.y;
+ param_4 = vec2((x_171 - x_172), (x_174 - x_175));
+ param_5 = vec2((x_178 - x_179), (x_181 - x_182));
+ float x_186 = param_4.x;
+ float x_188 = param_5.y;
+ float x_191 = param_5.x;
+ float x_193 = param_4.y;
+ float x_195 = ((x_186 * x_188) - (x_191 * x_193));
+ x_78 = x_195;
+ bool x_197 = (x_139 & (x_195 < 0.0f));
+ x_204_phi = x_197;
+ if (!(x_197)) {
+ x_203 = ((x_111 >= 0.0f) & (x_195 >= 0.0f));
+ x_204_phi = x_203;
+ }
+ if (!(x_204_phi)) {
+ return 0;
+ }
+ return 1;
+}
+
+void main_1() {
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_60 = tint_symbol;
+ vec2 x_63 = x_19.resolution;
+ param_6 = (vec2(x_60.x, x_60.y) / x_63);
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_65 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_65 == 1)) {
+ float x_71 = x_11.injectionSwitch.y;
+ float x_73 = x_11.injectionSwitch.x;
+ if ((x_71 >= x_73)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ }
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:67: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:67: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/1.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/1.wgsl.expected.glsl
new file mode 100644
index 0000000..a41fe75
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/stable-triangle-nested-for-loop-and-true-if/1.wgsl.expected.glsl
@@ -0,0 +1,201 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf1 {
+ vec2 injectionSwitch;
+};
+struct buf0 {
+ vec2 resolution;
+};
+
+layout (binding = 1) uniform buf1_1 {
+ vec2 injectionSwitch;
+} x_11;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 0) uniform buf0_1 {
+ vec2 resolution;
+} x_19;
+
+int pointInTriangle_vf2_vf2_vf2_vf2_(inout vec2 p, inout vec2 a, inout vec2 b, inout vec2 c) {
+ float x_78 = 0.0f;
+ float x_79 = 0.0f;
+ float x_80 = 0.0f;
+ vec2 param = vec2(0.0f, 0.0f);
+ vec2 param_1 = vec2(0.0f, 0.0f);
+ vec2 param_2 = vec2(0.0f, 0.0f);
+ vec2 param_3 = vec2(0.0f, 0.0f);
+ vec2 param_4 = vec2(0.0f, 0.0f);
+ vec2 param_5 = vec2(0.0f, 0.0f);
+ bool x_147 = false;
+ bool x_203 = false;
+ bool x_148_phi = false;
+ bool x_204_phi = false;
+ float x_82 = p.x;
+ float x_84 = a.x;
+ float x_87 = p.y;
+ float x_89 = a.y;
+ float x_93 = b.x;
+ float x_94 = a.x;
+ float x_97 = b.y;
+ float x_98 = a.y;
+ param = vec2((x_82 - x_84), (x_87 - x_89));
+ param_1 = vec2((x_93 - x_94), (x_97 - x_98));
+ float x_102 = param.x;
+ float x_104 = param_1.y;
+ float x_107 = param_1.x;
+ float x_109 = param.y;
+ float x_111 = ((x_102 * x_104) - (x_107 * x_109));
+ x_80 = x_111;
+ float x_112 = p.x;
+ float x_113 = b.x;
+ float x_115 = p.y;
+ float x_116 = b.y;
+ float x_120 = c.x;
+ float x_121 = b.x;
+ float x_124 = c.y;
+ float x_125 = b.y;
+ param_2 = vec2((x_112 - x_113), (x_115 - x_116));
+ param_3 = vec2((x_120 - x_121), (x_124 - x_125));
+ float x_129 = param_2.x;
+ float x_131 = param_3.y;
+ float x_134 = param_3.x;
+ float x_136 = param_2.y;
+ float x_138 = ((x_129 * x_131) - (x_134 * x_136));
+ x_79 = x_138;
+ bool x_139 = (x_111 < 0.0f);
+ bool x_141 = (x_139 & (x_138 < 0.0f));
+ x_148_phi = x_141;
+ if (!(x_141)) {
+ x_147 = ((x_111 >= 0.0f) & (x_138 >= 0.0f));
+ x_148_phi = x_147;
+ }
+ int x_153_phi = 0;
+ if (!(x_148_phi)) {
+ x_153_phi = 0;
+ while (true) {
+ int x_154 = 0;
+ int x_164_phi = 0;
+ int x_153 = x_153_phi;
+ float x_159 = x_11.injectionSwitch.y;
+ int x_160 = int(x_159);
+ if ((x_153 < x_160)) {
+ } else {
+ break;
+ }
+ x_GLF_color = vec4(1.0f, 1.0f, 1.0f, 1.0f);
+ x_164_phi = 0;
+ while (true) {
+ int x_165 = 0;
+ int x_164 = x_164_phi;
+ if ((x_164 < x_160)) {
+ } else {
+ break;
+ }
+ x_GLF_color = vec4(1.0f, 1.0f, 1.0f, 1.0f);
+ {
+ x_165 = (x_164 + 1);
+ x_164_phi = x_165;
+ }
+ }
+ {
+ x_154 = (x_153 + 1);
+ x_153_phi = x_154;
+ }
+ }
+ return 0;
+ }
+ float x_171 = p.x;
+ float x_172 = c.x;
+ float x_174 = p.y;
+ float x_175 = c.y;
+ float x_178 = a.x;
+ float x_179 = c.x;
+ float x_181 = a.y;
+ float x_182 = c.y;
+ param_4 = vec2((x_171 - x_172), (x_174 - x_175));
+ param_5 = vec2((x_178 - x_179), (x_181 - x_182));
+ float x_186 = param_4.x;
+ float x_188 = param_5.y;
+ float x_191 = param_5.x;
+ float x_193 = param_4.y;
+ float x_195 = ((x_186 * x_188) - (x_191 * x_193));
+ x_78 = x_195;
+ bool x_197 = (x_139 & (x_195 < 0.0f));
+ x_204_phi = x_197;
+ if (!(x_197)) {
+ x_203 = ((x_111 >= 0.0f) & (x_195 >= 0.0f));
+ x_204_phi = x_203;
+ }
+ if (!(x_204_phi)) {
+ return 0;
+ }
+ return 1;
+}
+
+void main_1() {
+ vec2 param_6 = vec2(0.0f, 0.0f);
+ vec2 param_7 = vec2(0.0f, 0.0f);
+ vec2 param_8 = vec2(0.0f, 0.0f);
+ vec2 param_9 = vec2(0.0f, 0.0f);
+ vec4 x_60 = tint_symbol;
+ vec2 x_63 = x_19.resolution;
+ param_6 = (vec2(x_60.x, x_60.y) / x_63);
+ param_7 = vec2(0.699999988f, 0.300000012f);
+ param_8 = vec2(0.5f, 0.899999976f);
+ param_9 = vec2(0.100000001f, 0.400000006f);
+ int x_65 = pointInTriangle_vf2_vf2_vf2_vf2_(param_6, param_7, param_8, param_9);
+ if ((x_65 == 1)) {
+ float x_71 = x_11.injectionSwitch.y;
+ float x_73 = x_11.injectionSwitch.x;
+ if ((x_71 >= x_73)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ }
+ } else {
+ x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:67: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:67: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/two-for-loops-with-barrier-function/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/two-for-loops-with-barrier-function/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..2a963e8
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/two-for-loops-with-barrier-function/0-opt.spvasm.expected.glsl
@@ -0,0 +1,87 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+struct doesNotMatter {
+ uint x_compute_data[];
+};
+
+vec4 GLF_live2gl_FragCoord = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_9;
+layout (binding = 0) buffer doesNotMatter_1 {
+ uint x_compute_data[];
+} x_12;
+
+void main_1() {
+ int GLF_live2_looplimiter1 = 0;
+ int i = 0;
+ int j = 0;
+ float GLF_dead3x = 0.0f;
+ float x_51 = 0.0f;
+ int GLF_dead3k = 0;
+ GLF_live2_looplimiter1 = 0;
+ i = 0;
+ {
+ for(; (i < 1); i = (i + 1)) {
+ if ((GLF_live2_looplimiter1 >= 3)) {
+ j = 0;
+ {
+ for(; (j < 1); j = (j + 1)) {
+ float x_13 = GLF_live2gl_FragCoord.x;
+ if ((int(x_13) < 120)) {
+ } else {
+ memoryBarrierShared();
+ }
+ }
+ }
+ break;
+ }
+ }
+ }
+ float x_81 = x_9.injectionSwitch.x;
+ float x_83 = x_9.injectionSwitch.y;
+ if ((x_81 > x_83)) {
+ float x_14 = GLF_live2gl_FragCoord.x;
+ x_51 = x_14;
+ } else {
+ x_51 = 0.0f;
+ }
+ GLF_dead3x = x_51;
+ GLF_dead3k = 0;
+ {
+ for(; (GLF_dead3k < 2); GLF_dead3k = (GLF_dead3k + 1)) {
+ if ((GLF_dead3x > 4.0f)) {
+ break;
+ }
+ float x_16 = GLF_live2gl_FragCoord.x;
+ GLF_dead3x = x_16;
+ memoryBarrierShared();
+ }
+ }
+ x_12.x_compute_data[0] = 42u;
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 18, local_size_z = 6) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '' : array size required
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/two-for-loops-with-barrier-function/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/two-for-loops-with-barrier-function/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..2a963e8
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/two-for-loops-with-barrier-function/0-opt.wgsl.expected.glsl
@@ -0,0 +1,87 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ vec2 injectionSwitch;
+};
+struct doesNotMatter {
+ uint x_compute_data[];
+};
+
+vec4 GLF_live2gl_FragCoord = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+layout (binding = 1) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_9;
+layout (binding = 0) buffer doesNotMatter_1 {
+ uint x_compute_data[];
+} x_12;
+
+void main_1() {
+ int GLF_live2_looplimiter1 = 0;
+ int i = 0;
+ int j = 0;
+ float GLF_dead3x = 0.0f;
+ float x_51 = 0.0f;
+ int GLF_dead3k = 0;
+ GLF_live2_looplimiter1 = 0;
+ i = 0;
+ {
+ for(; (i < 1); i = (i + 1)) {
+ if ((GLF_live2_looplimiter1 >= 3)) {
+ j = 0;
+ {
+ for(; (j < 1); j = (j + 1)) {
+ float x_13 = GLF_live2gl_FragCoord.x;
+ if ((int(x_13) < 120)) {
+ } else {
+ memoryBarrierShared();
+ }
+ }
+ }
+ break;
+ }
+ }
+ }
+ float x_81 = x_9.injectionSwitch.x;
+ float x_83 = x_9.injectionSwitch.y;
+ if ((x_81 > x_83)) {
+ float x_14 = GLF_live2gl_FragCoord.x;
+ x_51 = x_14;
+ } else {
+ x_51 = 0.0f;
+ }
+ GLF_dead3x = x_51;
+ GLF_dead3k = 0;
+ {
+ for(; (GLF_dead3k < 2); GLF_dead3k = (GLF_dead3k + 1)) {
+ if ((GLF_dead3x > 4.0f)) {
+ break;
+ }
+ float x_16 = GLF_live2gl_FragCoord.x;
+ GLF_dead3x = x_16;
+ memoryBarrierShared();
+ }
+ }
+ x_12.x_compute_data[0] = 42u;
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 18, local_size_z = 6) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '' : array size required
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/two-nested-for-loops-with-returns/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/two-nested-for-loops-with-returns/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..ea4016a
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/two-nested-for-loops-with-returns/0-opt.spvasm.expected.glsl
@@ -0,0 +1,78 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct doesNotMatter {
+ float x_compute_data[];
+};
+
+layout (binding = 0) buffer doesNotMatter_1 {
+ float x_compute_data[];
+} x_9;
+
+float nb_mod_() {
+ float s = 0.0f;
+ int i = 0;
+ int GLF_live1i = 0;
+ int GLF_live1_looplimiter2 = 0;
+ float x_51 = 0.0f;
+ float x_56_phi = 0.0f;
+ s = 0.0f;
+ i = 5;
+ while (true) {
+ float x_50 = 0.0f;
+ float x_51_phi = 0.0f;
+ x_56_phi = 0.0f;
+ if ((5 < 800)) {
+ } else {
+ break;
+ }
+ GLF_live1i = 0;
+ while (true) {
+ x_51_phi = 0.0f;
+ if ((0 < 20)) {
+ } else {
+ break;
+ }
+ if ((0 >= 5)) {
+ x_50 = (0.0f + 1.0f);
+ s = x_50;
+ x_51_phi = x_50;
+ break;
+ }
+ return 42.0f;
+ }
+ x_51 = x_51_phi;
+ if ((float(5) <= x_51)) {
+ x_56_phi = x_51;
+ break;
+ }
+ return 42.0f;
+ }
+ return x_56_phi;
+}
+
+void main_1() {
+ float x_32 = nb_mod_();
+ x_9.x_compute_data[0] = x_32;
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/two-nested-for-loops-with-returns/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/two-nested-for-loops-with-returns/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..ea4016a
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/two-nested-for-loops-with-returns/0-opt.wgsl.expected.glsl
@@ -0,0 +1,78 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct doesNotMatter {
+ float x_compute_data[];
+};
+
+layout (binding = 0) buffer doesNotMatter_1 {
+ float x_compute_data[];
+} x_9;
+
+float nb_mod_() {
+ float s = 0.0f;
+ int i = 0;
+ int GLF_live1i = 0;
+ int GLF_live1_looplimiter2 = 0;
+ float x_51 = 0.0f;
+ float x_56_phi = 0.0f;
+ s = 0.0f;
+ i = 5;
+ while (true) {
+ float x_50 = 0.0f;
+ float x_51_phi = 0.0f;
+ x_56_phi = 0.0f;
+ if ((5 < 800)) {
+ } else {
+ break;
+ }
+ GLF_live1i = 0;
+ while (true) {
+ x_51_phi = 0.0f;
+ if ((0 < 20)) {
+ } else {
+ break;
+ }
+ if ((0 >= 5)) {
+ x_50 = (0.0f + 1.0f);
+ s = x_50;
+ x_51_phi = x_50;
+ break;
+ }
+ return 42.0f;
+ }
+ x_51 = x_51_phi;
+ if ((float(5) <= x_51)) {
+ x_56_phi = x_51;
+ break;
+ }
+ return 42.0f;
+ }
+ return x_56_phi;
+}
+
+void main_1() {
+ float x_32 = nb_mod_();
+ x_9.x_compute_data[0] = x_32;
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/unreachable-barrier-in-loops/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/unreachable-barrier-in-loops/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..d81ec78
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/unreachable-barrier-in-loops/0-opt.spvasm.expected.glsl
@@ -0,0 +1,141 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf1 {
+ vec2 injectionSwitch;
+};
+struct buf2 {
+ vec2 resolution;
+};
+struct doesNotMatter {
+ int x_compute_data[];
+};
+
+uvec3 tint_symbol = uvec3(0u, 0u, 0u);
+layout (binding = 1) uniform buf1_1 {
+ vec2 injectionSwitch;
+} x_10;
+layout (binding = 2) uniform buf2_1 {
+ vec2 resolution;
+} x_13;
+layout (binding = 0) buffer doesNotMatter_1 {
+ int x_compute_data[];
+} x_15;
+
+void main_1() {
+ float A[1] = float[1](0.0f);
+ int i = 0;
+ vec4 value = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ int m = 0;
+ int l = 0;
+ int n = 0;
+ A[0] = 0.0f;
+ i = 0;
+ {
+ for(; (i < 50); i = (i + 1)) {
+ if ((i > 0)) {
+ float x_68 = A[0];
+ float x_70 = A[0];
+ A[0] = (x_70 + x_68);
+ }
+ }
+ }
+ while (true) {
+ uint x_80 = tint_symbol.x;
+ if ((x_80 < 100u)) {
+ value = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ m = 0;
+ {
+ for(; (m < 1); m = (m + 1)) {
+ l = 0;
+ {
+ for(; (l < 1); l = (l + 1)) {
+ float x_100 = x_10.injectionSwitch.x;
+ float x_102 = x_10.injectionSwitch.y;
+ if ((x_100 > x_102)) {
+ return;
+ }
+ }
+ }
+ }
+ }
+ n = 0;
+ {
+ for(; (n < 1); n = (n + 1)) {
+ float x_118 = x_10.injectionSwitch.x;
+ float x_120 = x_10.injectionSwitch.y;
+ if ((x_118 > x_120)) {
+ memoryBarrierShared();
+ }
+ }
+ }
+ } else {
+ uint x_127 = tint_symbol.x;
+ if ((x_127 < 120u)) {
+ float x_133 = A[0];
+ float x_135 = x_13.resolution.x;
+ float x_138 = A[0];
+ float x_140 = x_13.resolution.y;
+ value = vec4((x_133 / x_135), (x_138 / x_140), 0.0f, 1.0f);
+ } else {
+ float x_144 = x_10.injectionSwitch.x;
+ float x_146 = x_10.injectionSwitch.y;
+ if ((x_144 > x_146)) {
+ {
+ if (false) {
+ } else {
+ break;
+ }
+ }
+ continue;
+ }
+ }
+ }
+ {
+ if (false) {
+ } else {
+ break;
+ }
+ }
+ }
+ float x_151 = value.x;
+ x_15.x_compute_data[0] = int(x_151);
+ float x_155 = value.y;
+ x_15.x_compute_data[1] = int(x_155);
+ float x_159 = value.z;
+ x_15.x_compute_data[2] = int(x_159);
+ float x_163 = value.w;
+ x_15.x_compute_data[3] = int(x_163);
+ return;
+}
+
+struct tint_symbol_4 {
+ uvec3 tint_symbol_2;
+};
+
+void tint_symbol_1_inner(uvec3 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ return;
+}
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_GlobalInvocationID;
+ tint_symbol_1(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:11: '' : array size required
+ERROR: 0:12: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/unreachable-barrier-in-loops/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/graphicsfuzz/unreachable-barrier-in-loops/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..d81ec78
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/unreachable-barrier-in-loops/0-opt.wgsl.expected.glsl
@@ -0,0 +1,141 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf1 {
+ vec2 injectionSwitch;
+};
+struct buf2 {
+ vec2 resolution;
+};
+struct doesNotMatter {
+ int x_compute_data[];
+};
+
+uvec3 tint_symbol = uvec3(0u, 0u, 0u);
+layout (binding = 1) uniform buf1_1 {
+ vec2 injectionSwitch;
+} x_10;
+layout (binding = 2) uniform buf2_1 {
+ vec2 resolution;
+} x_13;
+layout (binding = 0) buffer doesNotMatter_1 {
+ int x_compute_data[];
+} x_15;
+
+void main_1() {
+ float A[1] = float[1](0.0f);
+ int i = 0;
+ vec4 value = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+ int m = 0;
+ int l = 0;
+ int n = 0;
+ A[0] = 0.0f;
+ i = 0;
+ {
+ for(; (i < 50); i = (i + 1)) {
+ if ((i > 0)) {
+ float x_68 = A[0];
+ float x_70 = A[0];
+ A[0] = (x_70 + x_68);
+ }
+ }
+ }
+ while (true) {
+ uint x_80 = tint_symbol.x;
+ if ((x_80 < 100u)) {
+ value = vec4(0.0f, 0.0f, 0.0f, 1.0f);
+ m = 0;
+ {
+ for(; (m < 1); m = (m + 1)) {
+ l = 0;
+ {
+ for(; (l < 1); l = (l + 1)) {
+ float x_100 = x_10.injectionSwitch.x;
+ float x_102 = x_10.injectionSwitch.y;
+ if ((x_100 > x_102)) {
+ return;
+ }
+ }
+ }
+ }
+ }
+ n = 0;
+ {
+ for(; (n < 1); n = (n + 1)) {
+ float x_118 = x_10.injectionSwitch.x;
+ float x_120 = x_10.injectionSwitch.y;
+ if ((x_118 > x_120)) {
+ memoryBarrierShared();
+ }
+ }
+ }
+ } else {
+ uint x_127 = tint_symbol.x;
+ if ((x_127 < 120u)) {
+ float x_133 = A[0];
+ float x_135 = x_13.resolution.x;
+ float x_138 = A[0];
+ float x_140 = x_13.resolution.y;
+ value = vec4((x_133 / x_135), (x_138 / x_140), 0.0f, 1.0f);
+ } else {
+ float x_144 = x_10.injectionSwitch.x;
+ float x_146 = x_10.injectionSwitch.y;
+ if ((x_144 > x_146)) {
+ {
+ if (false) {
+ } else {
+ break;
+ }
+ }
+ continue;
+ }
+ }
+ }
+ {
+ if (false) {
+ } else {
+ break;
+ }
+ }
+ }
+ float x_151 = value.x;
+ x_15.x_compute_data[0] = int(x_151);
+ float x_155 = value.y;
+ x_15.x_compute_data[1] = int(x_155);
+ float x_159 = value.z;
+ x_15.x_compute_data[2] = int(x_159);
+ float x_163 = value.w;
+ x_15.x_compute_data[3] = int(x_163);
+ return;
+}
+
+struct tint_symbol_4 {
+ uvec3 tint_symbol_2;
+};
+
+void tint_symbol_1_inner(uvec3 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ return;
+}
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_GlobalInvocationID;
+ tint_symbol_1(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:11: '' : array size required
+ERROR: 0:12: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/write-before-break/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/write-before-break/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..c2d5431
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/write-before-break/0-opt.spvasm.expected.glsl
@@ -0,0 +1,105 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct buf0 {
+ int injected;
+};
+
+layout (binding = 0) uniform buf0_1 {
+ int injected;
+} x_9;
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ int idx = 0;
+ mat4x3 m43 = mat4x3(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ int ll_1 = 0;
+ int GLF_live6rows = 0;
+ int z = 0;
+ int ll_2 = 0;
+ int ctr = 0;
+ mat4x3 tempm43 = mat4x3(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ int ll_3 = 0;
+ int c = 0;
+ int d = 0;
+ float GLF_live6sums[9] = float[9](0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ idx = 0;
+ m43 = mat4x3(vec3(1.0f, 0.0f, 0.0f), vec3(0.0f, 1.0f, 0.0f), vec3(0.0f, 0.0f, 1.0f), vec3(0.0f, 0.0f, 0.0f));
+ ll_1 = 0;
+ GLF_live6rows = 2;
+ while (true) {
+ int x_18 = ll_1;
+ int x_19 = x_9.injected;
+ if ((x_18 >= x_19)) {
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ break;
+ }
+ ll_1 = (ll_1 + 1);
+ int x_22 = x_9.injected;
+ z = x_22;
+ ll_2 = 0;
+ ctr = 0;
+ {
+ for(; (ctr < 1); ctr = (ctr + 1)) {
+ int x_24 = ll_2;
+ int x_25 = x_9.injected;
+ if ((x_24 >= x_25)) {
+ break;
+ }
+ ll_2 = (ll_2 + 1);
+ tempm43 = m43;
+ ll_3 = 0;
+ c = 0;
+ {
+ for(; (1 < z); c = (c + 1)) {
+ d = 0;
+ tempm43[(((c >= 0) & (c < 4)) ? c : 0)][(((d >= 0) & (d < 3)) ? d : 0)] = 1.0f;
+ }
+ }
+ int x_117 = (((idx >= 0) & (idx < 9)) ? idx : 0);
+ float x_119 = m43[ctr].y;
+ float x_121 = GLF_live6sums[x_117];
+ GLF_live6sums[x_117] = (x_121 + x_119);
+ }
+ }
+ idx = (idx + 1);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:56: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:56: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/write-red-after-search/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/write-red-after-search/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..8a64285
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/write-red-after-search/0-opt.spvasm.expected.glsl
@@ -0,0 +1,382 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct BST {
+ int data;
+ int leftIndex;
+ int rightIndex;
+};
+struct buf0 {
+ vec2 injectionSwitch;
+};
+struct Obj {
+ float odd_numbers[10];
+ float even_numbers[10];
+};
+
+BST tree_1[10] = BST[10](BST(0, 0, 0), BST(0, 0, 0), BST(0, 0, 0), BST(0, 0, 0), BST(0, 0, 0), BST(0, 0, 0), BST(0, 0, 0), BST(0, 0, 0), BST(0, 0, 0), BST(0, 0, 0));
+layout (binding = 0) uniform buf0_1 {
+ vec2 injectionSwitch;
+} x_27;
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void makeTreeNode_struct_BST_i1_i1_i11_i1_(inout BST tree, inout int data) {
+ int x_74 = data;
+ tree.data = x_74;
+ tree.leftIndex = -1;
+ tree.rightIndex = -1;
+ return;
+}
+
+void insert_i1_i1_(inout int treeIndex, inout int data_1) {
+ int baseIndex = 0;
+ BST param = BST(0, 0, 0);
+ int param_1 = 0;
+ BST param_2 = BST(0, 0, 0);
+ int param_3 = 0;
+ int GLF_live8i = 0;
+ float GLF_live8A[50] = float[50](0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ baseIndex = 0;
+ while (true) {
+ int x_75 = baseIndex;
+ int x_76 = treeIndex;
+ if ((x_75 <= x_76)) {
+ } else {
+ break;
+ }
+ int x_77 = data_1;
+ int x_79 = tree_1[baseIndex].data;
+ if ((x_77 <= x_79)) {
+ int x_81 = tree_1[baseIndex].leftIndex;
+ if ((x_81 == -1)) {
+ int x_82 = baseIndex;
+ int x_83 = treeIndex;
+ tree_1[x_82].leftIndex = x_83;
+ int x_84 = treeIndex;
+ BST x_350 = tree_1[x_84];
+ param = x_350;
+ int x_85 = data_1;
+ param_1 = x_85;
+ makeTreeNode_struct_BST_i1_i1_i11_i1_(param, param_1);
+ tree_1[x_84] = param;
+ return;
+ } else {
+ int x_87 = tree_1[baseIndex].leftIndex;
+ baseIndex = x_87;
+ continue;
+ }
+ } else {
+ int x_89 = tree_1[baseIndex].rightIndex;
+ if ((x_89 == -1)) {
+ int x_90 = baseIndex;
+ int x_91 = treeIndex;
+ tree_1[x_90].rightIndex = x_91;
+ int x_92 = treeIndex;
+ BST x_362 = tree_1[x_92];
+ param_2 = x_362;
+ int x_93 = data_1;
+ param_3 = x_93;
+ makeTreeNode_struct_BST_i1_i1_i11_i1_(param_2, param_3);
+ tree_1[x_92] = param_2;
+ return;
+ } else {
+ GLF_live8i = 1;
+ int x_369 = (((GLF_live8i >= 0) & (GLF_live8i < 50)) ? GLF_live8i : 0);
+ float x_371 = GLF_live8A[0];
+ float x_373 = GLF_live8A[x_369];
+ GLF_live8A[x_369] = (x_373 + x_371);
+ while (true) {
+ int x_98 = tree_1[baseIndex].rightIndex;
+ baseIndex = x_98;
+ {
+ float x_382 = x_27.injectionSwitch.x;
+ float x_384 = x_27.injectionSwitch.y;
+ if ((x_382 > x_384)) {
+ } else {
+ break;
+ }
+ }
+ }
+ continue;
+ }
+ }
+ }
+ return;
+}
+
+int search_i1_(inout int target) {
+ int index = 0;
+ BST currentNode = BST(0, 0, 0);
+ int x_387 = 0;
+ index = 0;
+ while (true) {
+ if ((index != -1)) {
+ } else {
+ break;
+ }
+ BST x_395 = tree_1[index];
+ currentNode = x_395;
+ int x_101 = currentNode.data;
+ int x_102 = target;
+ if ((x_101 == x_102)) {
+ int x_103 = target;
+ return x_103;
+ }
+ int x_104 = target;
+ int x_105 = currentNode.data;
+ if ((x_104 > x_105)) {
+ int x_106 = currentNode.rightIndex;
+ x_387 = x_106;
+ } else {
+ int x_107 = currentNode.leftIndex;
+ x_387 = x_107;
+ }
+ index = x_387;
+ }
+ return -1;
+}
+
+float makeFrame_f1_(inout float v) {
+ int param_5 = 0;
+ int param_6 = 0;
+ int param_7 = 0;
+ float x_418 = v;
+ v = (x_418 * 6.5f);
+ float x_420 = v;
+ if ((x_420 < 1.5f)) {
+ param_5 = 100;
+ int x_110 = search_i1_(param_5);
+ return float(x_110);
+ }
+ float x_425 = v;
+ if ((x_425 < 4.0f)) {
+ return 0.0f;
+ }
+ float x_429 = v;
+ param_6 = 6;
+ int x_111 = search_i1_(param_6);
+ if ((x_429 < float(x_111))) {
+ return 1.0f;
+ }
+ param_7 = 30;
+ int x_112 = search_i1_(param_7);
+ return (10.0f + float(x_112));
+}
+
+vec3 hueColor_f1_(inout float angle) {
+ float nodeData = 0.0f;
+ int param_4 = 0;
+ param_4 = 15;
+ int x_109 = search_i1_(param_4);
+ nodeData = float(x_109);
+ float x_409 = angle;
+ return ((vec3(30.0f, 30.0f, 30.0f) + (vec3(1.0f, 5.0f, nodeData) * x_409)) / vec3(50.0f, 50.0f, 50.0f));
+}
+
+void main_1() {
+ int treeIndex_1 = 0;
+ BST param_8 = BST(0, 0, 0);
+ int param_9 = 0;
+ int param_10 = 0;
+ int param_11 = 0;
+ int GLF_live1_looplimiter2 = 0;
+ int GLF_live1i = 0;
+ int param_12 = 0;
+ int param_13 = 0;
+ int param_14 = 0;
+ int param_15 = 0;
+ int param_16 = 0;
+ int param_17 = 0;
+ int param_18 = 0;
+ int param_19 = 0;
+ int param_20 = 0;
+ int param_21 = 0;
+ int param_22 = 0;
+ int param_23 = 0;
+ int GLF_live4_looplimiter3 = 0;
+ int GLF_live4i = 0;
+ int GLF_live4index = 0;
+ Obj GLF_live4obj = Obj(float[10](0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f), float[10](0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f));
+ int param_24 = 0;
+ int param_25 = 0;
+ int param_26 = 0;
+ int param_27 = 0;
+ vec2 z = vec2(0.0f, 0.0f);
+ float x_1 = 0.0f;
+ float param_28 = 0.0f;
+ float y_1 = 0.0f;
+ float param_29 = 0.0f;
+ int sum = 0;
+ int target_1 = 0;
+ int result = 0;
+ int param_30 = 0;
+ float a = 0.0f;
+ vec3 x_235 = vec3(0.0f, 0.0f, 0.0f);
+ float param_31 = 0.0f;
+ treeIndex_1 = 0;
+ BST x_237 = tree_1[0];
+ param_8 = x_237;
+ param_9 = 9;
+ makeTreeNode_struct_BST_i1_i1_i11_i1_(param_8, param_9);
+ tree_1[0] = param_8;
+ treeIndex_1 = (treeIndex_1 + 1);
+ param_10 = treeIndex_1;
+ param_11 = 5;
+ insert_i1_i1_(param_10, param_11);
+ treeIndex_1 = (treeIndex_1 + 1);
+ GLF_live1_looplimiter2 = 0;
+ GLF_live1i = 0;
+ {
+ for(; true; GLF_live1i = (GLF_live1i + 1)) {
+ if ((GLF_live1_looplimiter2 >= 7)) {
+ break;
+ }
+ GLF_live1_looplimiter2 = (GLF_live1_looplimiter2 + 1);
+ }
+ }
+ param_12 = treeIndex_1;
+ param_13 = 12;
+ insert_i1_i1_(param_12, param_13);
+ treeIndex_1 = (treeIndex_1 + 1);
+ param_14 = treeIndex_1;
+ param_15 = 15;
+ insert_i1_i1_(param_14, param_15);
+ treeIndex_1 = (treeIndex_1 + 1);
+ param_16 = treeIndex_1;
+ param_17 = 7;
+ insert_i1_i1_(param_16, param_17);
+ treeIndex_1 = (treeIndex_1 + 1);
+ param_18 = treeIndex_1;
+ param_19 = 8;
+ insert_i1_i1_(param_18, param_19);
+ treeIndex_1 = (treeIndex_1 + 1);
+ param_20 = treeIndex_1;
+ param_21 = 2;
+ insert_i1_i1_(param_20, param_21);
+ treeIndex_1 = (treeIndex_1 + 1);
+ param_22 = treeIndex_1;
+ param_23 = 6;
+ insert_i1_i1_(param_22, param_23);
+ treeIndex_1 = (treeIndex_1 + 1);
+ GLF_live4_looplimiter3 = 0;
+ GLF_live4i = 0;
+ {
+ for(; true; GLF_live4i = (GLF_live4i + 1)) {
+ if ((GLF_live4_looplimiter3 >= 3)) {
+ break;
+ }
+ GLF_live4_looplimiter3 = (GLF_live4_looplimiter3 + 1);
+ GLF_live4index = 1;
+ int x_144 = GLF_live4index;
+ int x_145 = GLF_live4index;
+ int x_146 = GLF_live4index;
+ float x_269 = GLF_live4obj.even_numbers[1];
+ GLF_live4obj.even_numbers[(((x_144 >= 0) & (x_145 < 10)) ? x_146 : 0)] = x_269;
+ GLF_live4obj.even_numbers[(((GLF_live4i >= 0) & (GLF_live4i < 10)) ? GLF_live4i : 0)] = 1.0f;
+ }
+ }
+ param_24 = treeIndex_1;
+ param_25 = 17;
+ insert_i1_i1_(param_24, param_25);
+ float x_278 = x_27.injectionSwitch.x;
+ float x_280 = x_27.injectionSwitch.y;
+ if ((x_278 > x_280)) {
+ return;
+ }
+ treeIndex_1 = (treeIndex_1 + 1);
+ param_26 = treeIndex_1;
+ param_27 = 13;
+ insert_i1_i1_(param_26, param_27);
+ vec4 x_285 = tint_symbol;
+ z = (vec2(x_285.y, x_285.x) / vec2(256.0f, 256.0f));
+ float x_289 = z.x;
+ param_28 = x_289;
+ float x_290 = makeFrame_f1_(param_28);
+ x_1 = x_290;
+ float x_292 = z.y;
+ param_29 = x_292;
+ float x_293 = makeFrame_f1_(param_29);
+ y_1 = x_293;
+ sum = -100;
+ target_1 = 0;
+ {
+ for(; (target_1 < 20); target_1 = (target_1 + 1)) {
+ param_30 = target_1;
+ int x_158 = search_i1_(param_30);
+ result = x_158;
+ if ((result > 0)) {
+ } else {
+ switch(result) {
+ case 0: {
+ return;
+ break;
+ }
+ case -1: {
+ sum = (sum + 1);
+ break;
+ }
+ default: {
+ break;
+ }
+ }
+ }
+ }
+ }
+ a = (x_1 + (y_1 * float(sum)));
+ float x_313 = x_27.injectionSwitch.x;
+ float x_315 = x_27.injectionSwitch.y;
+ if ((x_313 < x_315)) {
+ x_235 = vec3(1.0f, 0.0f, 0.0f);
+ } else {
+ param_31 = a;
+ vec3 x_321 = hueColor_f1_(param_31);
+ x_235 = x_321;
+ }
+ vec3 x_322 = x_235;
+ x_GLF_color = vec4(x_322.x, x_322.y, x_322.z, 1.0f);
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(x_GLF_color);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:85: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:85: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/graphicsfuzz/write-red-in-loop-nest/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/graphicsfuzz/write-red-in-loop-nest/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..f3ab858
--- /dev/null
+++ b/test/vk-gl-cts/graphicsfuzz/write-red-in-loop-nest/0-opt.spvasm.expected.glsl
@@ -0,0 +1,95 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_GLF_color = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+
+void main_1() {
+ mat4x3 m43 = mat4x3(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ int ll1 = 0;
+ int rows = 0;
+ int ll4 = 0;
+ int ll2 = 0;
+ int c = 0;
+ mat4x3 tempm43 = mat4x3(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ int ll3 = 0;
+ int d = 0;
+ int r = 0;
+ float sums[9] = float[9](0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f);
+ int idx = 0;
+ m43 = mat4x3(vec3(1.0f, 0.0f, 0.0f), vec3(0.0f, 1.0f, 0.0f), vec3(0.0f, 0.0f, 1.0f), vec3(0.0f, 0.0f, 0.0f));
+ ll1 = 0;
+ rows = 2;
+ while (true) {
+ if (true) {
+ } else {
+ break;
+ }
+ x_GLF_color = vec4(1.0f, 0.0f, 0.0f, 1.0f);
+ if ((ll1 >= 5)) {
+ break;
+ }
+ ll1 = (ll1 + 1);
+ ll4 = 10;
+ ll2 = 0;
+ c = 0;
+ {
+ for(; (c < 1); c = (c + 1)) {
+ if ((ll2 >= 0)) {
+ break;
+ }
+ ll2 = (ll2 + 1);
+ tempm43 = m43;
+ ll3 = 0;
+ d = 0;
+ {
+ for(; (1 < ll4); d = (d + 1)) {
+ tempm43[(((d >= 0) & (d < 4)) ? d : 0)][(((r >= 0) & (r < 3)) ? r : 0)] = 1.0f;
+ }
+ }
+ int x_111 = (((idx >= 0) & (idx < 9)) ? idx : 0);
+ float x_113 = m43[c].y;
+ float x_115 = sums[x_111];
+ sums[x_111] = (x_115 + x_113);
+ }
+ }
+ idx = (idx + 1);
+ }
+ return;
+}
+
+struct main_out {
+ vec4 x_GLF_color_1;
+};
+struct tint_symbol_1 {
+ vec4 x_GLF_color_1;
+};
+
+main_out tint_symbol_inner() {
+ main_1();
+ main_out tint_symbol_2 = main_out(x_GLF_color);
+ return tint_symbol_2;
+}
+
+tint_symbol_1 tint_symbol() {
+ main_out inner_result = tint_symbol_inner();
+ tint_symbol_1 wrapper_result = tint_symbol_1(vec4(0.0f, 0.0f, 0.0f, 0.0f));
+ wrapper_result.x_GLF_color_1 = inner_result.x_GLF_color_1;
+ return wrapper_result;
+}
+out vec4 x_GLF_color_1;
+void main() {
+ tint_symbol_1 outputs;
+ outputs = tint_symbol();
+ x_GLF_color_1 = outputs.x_GLF_color_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:46: '&' : wrong operand types: no operation '&' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:46: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/arraylength/array-stride-larger-than-element-size/1.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/arraylength/array-stride-larger-than-element-size/1.spvasm.expected.glsl
new file mode 100644
index 0000000..647bb19
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/arraylength/array-stride-larger-than-element-size/1.spvasm.expected.glsl
@@ -0,0 +1,51 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct Buf1 {
+ int result;
+};
+struct Buf0 {
+ uint values[];
+};
+
+layout (binding = 1) buffer Buf1_1 {
+ int result;
+} x_4;
+layout (binding = 0) buffer Buf0_1 {
+ uint values[];
+} x_7;
+
+void main_1() {
+ uint i = 0u;
+ x_4.result = 1;
+ i = 0u;
+ {
+ for(; (i < 512u); i = (i + uint(1))) {
+ uint x_39 = x_7.values[(i * 2u)];
+ if ((x_39 != i)) {
+ x_4.result = 0;
+ }
+ }
+ }
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '' : array size required
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/arraylength/array-stride-larger-than-element-size/1.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/arraylength/array-stride-larger-than-element-size/1.wgsl.expected.glsl
new file mode 100644
index 0000000..647bb19
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/arraylength/array-stride-larger-than-element-size/1.wgsl.expected.glsl
@@ -0,0 +1,51 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct Buf1 {
+ int result;
+};
+struct Buf0 {
+ uint values[];
+};
+
+layout (binding = 1) buffer Buf1_1 {
+ int result;
+} x_4;
+layout (binding = 0) buffer Buf0_1 {
+ uint values[];
+} x_7;
+
+void main_1() {
+ uint i = 0u;
+ x_4.result = 1;
+ i = 0u;
+ {
+ for(; (i < 512u); i = (i + uint(1))) {
+ uint x_39 = x_7.values[(i * 2u)];
+ if ((x_39 != i)) {
+ x_4.result = 0;
+ }
+ }
+ }
+ return;
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol() {
+ main_1();
+ return;
+}
+void main() {
+ tint_symbol();
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:8: '' : array size required
+ERROR: 0:9: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthan/0.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthan/0.spvasm.expected.glsl
new file mode 100644
index 0000000..4051a89
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthan/0.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_21 = x_2.x;
+ uint x_23 = x_5.field0[x_21];
+ uint x_25 = x_6.field0[x_21];
+ x_7.field0[x_21] = ((int(x_23) > int(x_25)) ? 1u : 0u);
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthan/0.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthan/0.wgsl.expected.glsl
new file mode 100644
index 0000000..4051a89
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthan/0.wgsl.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_21 = x_2.x;
+ uint x_23 = x_5.field0[x_21];
+ uint x_25 = x_6.field0[x_21];
+ x_7.field0[x_21] = ((int(x_23) > int(x_25)) ? 1u : 0u);
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthanequal/0.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthanequal/0.spvasm.expected.glsl
new file mode 100644
index 0000000..00d95b5
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthanequal/0.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_21 = x_2.x;
+ uint x_23 = x_5.field0[x_21];
+ uint x_25 = x_6.field0[x_21];
+ x_7.field0[x_21] = ((int(x_23) >= int(x_25)) ? 1u : 0u);
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthanequal/0.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthanequal/0.wgsl.expected.glsl
new file mode 100644
index 0000000..00d95b5
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_sgreaterthanequal/0.wgsl.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_21 = x_2.x;
+ uint x_23 = x_5.field0[x_21];
+ uint x_25 = x_6.field0[x_21];
+ x_7.field0[x_21] = ((int(x_23) >= int(x_25)) ? 1u : 0u);
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthan/0.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthan/0.spvasm.expected.glsl
new file mode 100644
index 0000000..6549a16
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthan/0.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_21 = x_2.x;
+ uint x_23 = x_5.field0[x_21];
+ uint x_25 = x_6.field0[x_21];
+ x_7.field0[x_21] = ((int(x_23) < int(x_25)) ? 1u : 0u);
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthan/0.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthan/0.wgsl.expected.glsl
new file mode 100644
index 0000000..6549a16
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthan/0.wgsl.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_21 = x_2.x;
+ uint x_23 = x_5.field0[x_21];
+ uint x_25 = x_6.field0[x_21];
+ x_7.field0[x_21] = ((int(x_23) < int(x_25)) ? 1u : 0u);
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthanequal/0.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthanequal/0.spvasm.expected.glsl
new file mode 100644
index 0000000..b7820e5
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthanequal/0.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_21 = x_2.x;
+ uint x_23 = x_5.field0[x_21];
+ uint x_25 = x_6.field0[x_21];
+ x_7.field0[x_21] = ((int(x_23) <= int(x_25)) ? 1u : 0u);
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthanequal/0.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthanequal/0.wgsl.expected.glsl
new file mode 100644
index 0000000..b7820e5
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_int_compare/uint_slessthanequal/0.wgsl.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_21 = x_2.x;
+ uint x_23 = x_5.field0[x_21];
+ uint x_25 = x_6.field0[x_21];
+ x_7.field0[x_21] = ((int(x_23) <= int(x_25)) ? 1u : 0u);
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_int_uclamp/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_int_uclamp/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..9c107df
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_int_uclamp/0-opt.spvasm.expected.glsl
@@ -0,0 +1,60 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ int field0[];
+};
+
+uvec3 x_3 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ int field0[];
+} x_6;
+layout (binding = 1) buffer S_2 {
+ int field0[];
+} x_7;
+layout (binding = 2) buffer S_3 {
+ int field0[];
+} x_8;
+layout (binding = 3) buffer S_4 {
+ int field0[];
+} x_9;
+
+void main_1() {
+ uint x_26 = x_3.x;
+ int x_28 = x_6.field0[x_26];
+ int x_30 = x_7.field0[x_26];
+ int x_32 = x_8.field0[x_26];
+ x_9.field0[x_26] = int(clamp(uint(x_28), uint(x_30), uint(x_32)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_3_param;
+};
+
+void tint_symbol_inner(uvec3 x_3_param) {
+ x_3 = x_3_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_3_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_int_uclamp/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_int_uclamp/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..9c107df
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_int_uclamp/0-opt.wgsl.expected.glsl
@@ -0,0 +1,60 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ int field0[];
+};
+
+uvec3 x_3 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ int field0[];
+} x_6;
+layout (binding = 1) buffer S_2 {
+ int field0[];
+} x_7;
+layout (binding = 2) buffer S_3 {
+ int field0[];
+} x_8;
+layout (binding = 3) buffer S_4 {
+ int field0[];
+} x_9;
+
+void main_1() {
+ uint x_26 = x_3.x;
+ int x_28 = x_6.field0[x_26];
+ int x_30 = x_7.field0[x_26];
+ int x_32 = x_8.field0[x_26];
+ x_9.field0[x_26] = int(clamp(uint(x_28), uint(x_30), uint(x_32)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_3_param;
+};
+
+void tint_symbol_inner(uvec3 x_3_param) {
+ x_3 = x_3_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_3_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sabs/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sabs/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..c2f72f4
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sabs/0-opt.spvasm.expected.glsl
@@ -0,0 +1,52 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_3 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_6;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_21 = x_3.x;
+ uint x_23 = x_6.field0[x_21];
+ x_7.field0[x_21] = uint(abs(int(x_23)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_3_param;
+};
+
+void tint_symbol_inner(uvec3 x_3_param) {
+ x_3 = x_3_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_3_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sabs/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sabs/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..c2f72f4
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sabs/0-opt.wgsl.expected.glsl
@@ -0,0 +1,52 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_3 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_6;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_21 = x_3.x;
+ uint x_23 = x_6.field0[x_21];
+ x_7.field0[x_21] = uint(abs(int(x_23)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_3_param;
+};
+
+void tint_symbol_inner(uvec3 x_3_param) {
+ x_3 = x_3_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_3_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sclamp/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sclamp/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..0d2cc7a
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sclamp/0-opt.spvasm.expected.glsl
@@ -0,0 +1,60 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_3 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_6;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_7;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_8;
+layout (binding = 3) buffer S_4 {
+ uint field0[];
+} x_9;
+
+void main_1() {
+ uint x_23 = x_3.x;
+ uint x_25 = x_6.field0[x_23];
+ uint x_27 = x_7.field0[x_23];
+ uint x_29 = x_8.field0[x_23];
+ x_9.field0[x_23] = uint(clamp(int(x_25), int(x_27), int(x_29)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_3_param;
+};
+
+void tint_symbol_inner(uvec3 x_3_param) {
+ x_3 = x_3_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_3_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sclamp/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sclamp/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..0d2cc7a
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_sclamp/0-opt.wgsl.expected.glsl
@@ -0,0 +1,60 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_3 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_6;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_7;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_8;
+layout (binding = 3) buffer S_4 {
+ uint field0[];
+} x_9;
+
+void main_1() {
+ uint x_23 = x_3.x;
+ uint x_25 = x_6.field0[x_23];
+ uint x_27 = x_7.field0[x_23];
+ uint x_29 = x_8.field0[x_23];
+ x_9.field0[x_23] = uint(clamp(int(x_25), int(x_27), int(x_29)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_3_param;
+};
+
+void tint_symbol_inner(uvec3 x_3_param) {
+ x_3 = x_3_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_3_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smax/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smax/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..7c5c515
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smax/0-opt.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_3 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_6;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_7;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_8;
+
+void main_1() {
+ uint x_21 = x_3.x;
+ uint x_23 = x_6.field0[x_21];
+ uint x_25 = x_7.field0[x_21];
+ x_8.field0[x_21] = uint(max(int(x_23), int(x_25)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_3_param;
+};
+
+void tint_symbol_inner(uvec3 x_3_param) {
+ x_3 = x_3_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_3_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smax/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smax/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..7c5c515
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smax/0-opt.wgsl.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_3 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_6;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_7;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_8;
+
+void main_1() {
+ uint x_21 = x_3.x;
+ uint x_23 = x_6.field0[x_21];
+ uint x_25 = x_7.field0[x_21];
+ x_8.field0[x_21] = uint(max(int(x_23), int(x_25)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_3_param;
+};
+
+void tint_symbol_inner(uvec3 x_3_param) {
+ x_3 = x_3_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_3_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smin/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smin/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..d0da7f2
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smin/0-opt.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_3 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_6;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_7;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_8;
+
+void main_1() {
+ uint x_21 = x_3.x;
+ uint x_23 = x_6.field0[x_21];
+ uint x_25 = x_7.field0[x_21];
+ x_8.field0[x_21] = uint(min(int(x_23), int(x_25)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_3_param;
+};
+
+void tint_symbol_inner(uvec3 x_3_param) {
+ x_3 = x_3_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_3_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smin/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smin/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..d0da7f2
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/glsl_uint_smin/0-opt.wgsl.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_3 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_6;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_7;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_8;
+
+void main_1() {
+ uint x_21 = x_3.x;
+ uint x_23 = x_6.field0[x_21];
+ uint x_25 = x_7.field0[x_21];
+ x_8.field0[x_21] = uint(min(int(x_23), int(x_25)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_3_param;
+};
+
+void tint_symbol_inner(uvec3 x_3_param) {
+ x_3 = x_3_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_3_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_sdiv/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_sdiv/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..714c300
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_sdiv/0-opt.spvasm.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_20 = x_2.x;
+ uint x_22 = x_5.field0[x_20];
+ uint x_24 = x_6.field0[x_20];
+ x_7.field0[x_20] = uint((int(x_22) / int(x_24)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_sdiv/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_sdiv/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..714c300
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_sdiv/0-opt.wgsl.expected.glsl
@@ -0,0 +1,56 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+layout (binding = 2) buffer S_3 {
+ uint field0[];
+} x_7;
+
+void main_1() {
+ uint x_20 = x_2.x;
+ uint x_22 = x_5.field0[x_20];
+ uint x_24 = x_6.field0[x_20];
+ x_7.field0[x_20] = uint((int(x_22) / int(x_24)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_snegate/0-opt.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_snegate/0-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..b49fe89
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_snegate/0-opt.spvasm.expected.glsl
@@ -0,0 +1,52 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+
+void main_1() {
+ uint x_20 = x_2.x;
+ uint x_22 = x_5.field0[x_20];
+ x_6.field0[x_20] = uint(-(int(x_22)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_snegate/0-opt.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_snegate/0-opt.wgsl.expected.glsl
new file mode 100644
index 0000000..b49fe89
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/compute/signed_op/uint_snegate/0-opt.wgsl.expected.glsl
@@ -0,0 +1,52 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ uint field0[];
+};
+
+uvec3 x_2 = uvec3(0u, 0u, 0u);
+layout (binding = 0) buffer S_1 {
+ uint field0[];
+} x_5;
+layout (binding = 1) buffer S_2 {
+ uint field0[];
+} x_6;
+
+void main_1() {
+ uint x_20 = x_2.x;
+ uint x_22 = x_5.field0[x_20];
+ x_6.field0[x_20] = uint(-(int(x_22)));
+ return;
+}
+
+struct tint_symbol_2 {
+ uvec3 x_2_param;
+};
+
+void tint_symbol_inner(uvec3 x_2_param) {
+ x_2 = x_2_param;
+ main_1();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void tint_symbol(tint_symbol_2 tint_symbol_1) {
+ tint_symbol_inner(tint_symbol_1.x_2_param);
+ return;
+}
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_2_param = gl_GlobalInvocationID;
+ tint_symbol(inputs);
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_image_store/1.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_image_store/1.spvasm.expected.glsl
new file mode 100644
index 0000000..7f525f9
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_image_store/1.spvasm.expected.glsl
@@ -0,0 +1,65 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+uniform highp writeonly iimage2D x_5;
+
+void main_1() {
+ x_4 = 1;
+ vec4 x_23 = x_2;
+ int x_27 = int(x_23.x);
+ int x_28 = int(x_23.y);
+ if (((((x_27 & 1) + (x_28 & 1)) + x_3) == int(x_23.z))) {
+ }
+ imageStore(x_5, ivec2(x_27, x_28), ivec4(x_27, 0, 0, 0));
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:45: 'int' : must be qualified as flat in
+ERROR: 0:45: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_image_store/1.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_image_store/1.wgsl.expected.glsl
new file mode 100644
index 0000000..f63590e
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_image_store/1.wgsl.expected.glsl
@@ -0,0 +1,69 @@
+SKIP: FAILED
+
+vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_image_store/1.wgsl:27:70 warning: integral user-defined fragment inputs must have a flat interpolation attribute
+fn main([[builtin(position)]] x_2_param : vec4<f32>, [[location(0)]] x_3_param : i32) -> main_out {
+ ^^^^^^^^^
+
+#version 310 es
+precision mediump float;
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+uniform highp writeonly iimage2D x_5;
+
+void main_1() {
+ x_4 = 1;
+ vec4 x_23 = x_2;
+ int x_27 = int(x_23.x);
+ int x_28 = int(x_23.y);
+ if (((((x_27 & 1) + (x_28 & 1)) + x_3) == int(x_23.z))) {
+ }
+ imageStore(x_5, ivec2(x_27, x_28), ivec4(x_27, 0, 0, 0));
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:45: 'int' : must be qualified as flat in
+ERROR: 0:45: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write/1.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write/1.spvasm.expected.glsl
new file mode 100644
index 0000000..9d119bb
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write/1.spvasm.expected.glsl
@@ -0,0 +1,61 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+
+void main_1() {
+ vec4 x_16 = x_2;
+ if (((((int(x_16.x) & 1) + (int(x_16.y) & 1)) + x_3) == int(x_16.z))) {
+ }
+ x_4 = 1;
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:41: 'int' : must be qualified as flat in
+ERROR: 0:41: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write/1.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write/1.wgsl.expected.glsl
new file mode 100644
index 0000000..c7468bb
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write/1.wgsl.expected.glsl
@@ -0,0 +1,65 @@
+SKIP: FAILED
+
+vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write/1.wgsl:22:70 warning: integral user-defined fragment inputs must have a flat interpolation attribute
+fn main([[builtin(position)]] x_2_param : vec4<f32>, [[location(0)]] x_3_param : i32) -> main_out {
+ ^^^^^^^^^
+
+#version 310 es
+precision mediump float;
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+
+void main_1() {
+ vec4 x_16 = x_2;
+ if (((((int(x_16.x) & 1) + (int(x_16.y) & 1)) + x_3) == int(x_16.z))) {
+ }
+ x_4 = 1;
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:41: 'int' : must be qualified as flat in
+ERROR: 0:41: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write/2-opt.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write/2-opt.spvasm.expected.glsl
new file mode 100644
index 0000000..f01d6d3
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write/2-opt.spvasm.expected.glsl
@@ -0,0 +1,59 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 tint_symbol = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int out_data = 0;
+
+void main_1() {
+ bool x_is_odd = false;
+ bool y_is_odd = false;
+ float x_24 = tint_symbol.x;
+ x_is_odd = ((int(x_24) & 1) == 1);
+ float x_29 = tint_symbol.y;
+ y_is_odd = ((int(x_29) & 1) == 1);
+ out_data = ((x_is_odd | y_is_odd) ? 1 : 0);
+ return;
+}
+
+struct main_out {
+ int out_data_1;
+};
+struct tint_symbol_4 {
+ vec4 tint_symbol_2;
+};
+struct tint_symbol_5 {
+ int out_data_1;
+};
+
+main_out tint_symbol_1_inner(vec4 tint_symbol_2) {
+ tint_symbol = tint_symbol_2;
+ main_1();
+ main_out tint_symbol_6 = main_out(out_data);
+ return tint_symbol_6;
+}
+
+tint_symbol_5 tint_symbol_1(tint_symbol_4 tint_symbol_3) {
+ main_out inner_result = tint_symbol_1_inner(tint_symbol_3.tint_symbol_2);
+ tint_symbol_5 wrapper_result = tint_symbol_5(0);
+ wrapper_result.out_data_1 = inner_result.out_data_1;
+ return wrapper_result;
+}
+out int out_data_1;
+void main() {
+ tint_symbol_4 inputs;
+ inputs.tint_symbol_2 = gl_FragCoord;
+ tint_symbol_5 outputs;
+ outputs = tint_symbol_1(inputs);
+ out_data_1 = outputs.out_data_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:14: '|' : wrong operand types: no operation '|' exists that takes a left-hand operand of type ' temp bool' and a right operand of type ' temp bool' (or there is no acceptable conversion)
+ERROR: 0:14: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write_before_terminate/1.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write_before_terminate/1.spvasm.expected.glsl
new file mode 100644
index 0000000..905ff1d
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write_before_terminate/1.spvasm.expected.glsl
@@ -0,0 +1,62 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+
+void main_1() {
+ vec4 x_16 = x_2;
+ int x_26 = x_3;
+ x_4 = 1;
+ if (((((int(x_16.x) & 1) + (int(x_16.y) & 1)) + x_26) == int(x_16.z))) {
+ }
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:42: 'int' : must be qualified as flat in
+ERROR: 0:42: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write_before_terminate/1.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write_before_terminate/1.wgsl.expected.glsl
new file mode 100644
index 0000000..42a8717
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write_before_terminate/1.wgsl.expected.glsl
@@ -0,0 +1,66 @@
+SKIP: FAILED
+
+vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_output_write_before_terminate/1.wgsl:22:70 warning: integral user-defined fragment inputs must have a flat interpolation attribute
+fn main([[builtin(position)]] x_2_param : vec4<f32>, [[location(0)]] x_3_param : i32) -> main_out {
+ ^^^^^^^^^
+
+#version 310 es
+precision mediump float;
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+
+void main_1() {
+ vec4 x_16 = x_2;
+ int x_26 = x_3;
+ x_4 = 1;
+ if (((((int(x_16.x) & 1) + (int(x_16.y) & 1)) + x_26) == int(x_16.z))) {
+ }
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:42: 'int' : must be qualified as flat in
+ERROR: 0:42: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_ssbo_store/1.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_ssbo_store/1.spvasm.expected.glsl
new file mode 100644
index 0000000..1a50997
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_ssbo_store/1.spvasm.expected.glsl
@@ -0,0 +1,71 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ int field0[];
+};
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+layout (binding = 0) buffer S_1 {
+ int field0[];
+} x_5;
+
+void main_1() {
+ x_4 = 1;
+ vec4 x_23 = x_2;
+ int x_27 = int(x_23.x);
+ int x_28 = int(x_23.y);
+ if (((((x_27 & 1) + (x_28 & 1)) + x_3) == int(x_23.z))) {
+ }
+ x_5.field0[(x_27 + (x_28 * 8))] = x_27;
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_ssbo_store/1.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_ssbo_store/1.wgsl.expected.glsl
new file mode 100644
index 0000000..41b83dd
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_ssbo_store/1.wgsl.expected.glsl
@@ -0,0 +1,75 @@
+SKIP: FAILED
+
+vk-gl-cts/spirv_assembly/instruction/terminate_invocation/no_ssbo_store/1.wgsl:33:70 warning: integral user-defined fragment inputs must have a flat interpolation attribute
+fn main([[builtin(position)]] x_2_param : vec4<f32>, [[location(0)]] x_3_param : i32) -> main_out {
+ ^^^^^^^^^
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ int field0[];
+};
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+layout (binding = 0) buffer S_1 {
+ int field0[];
+} x_5;
+
+void main_1() {
+ x_4 = 1;
+ vec4 x_23 = x_2;
+ int x_27 = int(x_23.x);
+ int x_28 = int(x_23.y);
+ if (((((x_27 & 1) + (x_28 & 1)) + x_3) == int(x_23.z))) {
+ }
+ x_5.field0[(x_27 + (x_28 * 8))] = x_27;
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/ssbo_store_before_terminate/1.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/ssbo_store_before_terminate/1.spvasm.expected.glsl
new file mode 100644
index 0000000..839eaae
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/ssbo_store_before_terminate/1.spvasm.expected.glsl
@@ -0,0 +1,72 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ int field0[];
+};
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+layout (binding = 0) buffer S_1 {
+ int field0[];
+} x_5;
+
+void main_1() {
+ x_4 = 1;
+ vec4 x_23 = x_2;
+ int x_27 = int(x_23.x);
+ int x_28 = int(x_23.y);
+ int x_33 = x_3;
+ x_5.field0[(x_27 + (x_28 * 8))] = x_27;
+ if (((((x_27 & 1) + (x_28 & 1)) + x_33) == int(x_23.z))) {
+ }
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/ssbo_store_before_terminate/1.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/ssbo_store_before_terminate/1.wgsl.expected.glsl
new file mode 100644
index 0000000..4b8208a
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/ssbo_store_before_terminate/1.wgsl.expected.glsl
@@ -0,0 +1,76 @@
+SKIP: FAILED
+
+vk-gl-cts/spirv_assembly/instruction/terminate_invocation/ssbo_store_before_terminate/1.wgsl:33:70 warning: integral user-defined fragment inputs must have a flat interpolation attribute
+fn main([[builtin(position)]] x_2_param : vec4<f32>, [[location(0)]] x_3_param : i32) -> main_out {
+ ^^^^^^^^^
+
+#version 310 es
+precision mediump float;
+
+struct S {
+ int field0[];
+};
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+layout (binding = 0) buffer S_1 {
+ int field0[];
+} x_5;
+
+void main_1() {
+ x_4 = 1;
+ vec4 x_23 = x_2;
+ int x_27 = int(x_23.x);
+ int x_28 = int(x_23.y);
+ int x_33 = x_3;
+ x_5.field0[(x_27 + (x_28 * 8))] = x_27;
+ if (((((x_27 & 1) + (x_28 & 1)) + x_33) == int(x_23.z))) {
+ }
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:5: '' : array size required
+ERROR: 0:6: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/terminate_loop/1.spvasm.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/terminate_loop/1.spvasm.expected.glsl
new file mode 100644
index 0000000..bb321ca
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/terminate_loop/1.spvasm.expected.glsl
@@ -0,0 +1,76 @@
+SKIP: FAILED
+
+#version 310 es
+precision mediump float;
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+
+void main_1() {
+ int x_33_phi = 0;
+ vec4 x_18 = x_2;
+ int x_28 = x_3;
+ x_33_phi = 0;
+ if (((((int(x_18.x) & 1) + (int(x_18.y) & 1)) + x_28) == int(x_18.z))) {
+ while (true) {
+ int x_34 = 0;
+ int x_33 = x_33_phi;
+ if ((uint(x_33) < uint(10))) {
+ } else {
+ break;
+ }
+ {
+ x_34 = (x_33 + 1);
+ x_33_phi = x_34;
+ }
+ }
+ }
+ x_4 = 1;
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:56: 'int' : must be qualified as flat in
+ERROR: 0:56: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
diff --git a/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/terminate_loop/1.wgsl.expected.glsl b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/terminate_loop/1.wgsl.expected.glsl
new file mode 100644
index 0000000..2d61612
--- /dev/null
+++ b/test/vk-gl-cts/spirv_assembly/instruction/terminate_invocation/terminate_loop/1.wgsl.expected.glsl
@@ -0,0 +1,80 @@
+SKIP: FAILED
+
+vk-gl-cts/spirv_assembly/instruction/terminate_invocation/terminate_loop/1.wgsl:37:70 warning: integral user-defined fragment inputs must have a flat interpolation attribute
+fn main([[builtin(position)]] x_2_param : vec4<f32>, [[location(0)]] x_3_param : i32) -> main_out {
+ ^^^^^^^^^
+
+#version 310 es
+precision mediump float;
+
+vec4 x_2 = vec4(0.0f, 0.0f, 0.0f, 0.0f);
+int x_3 = 0;
+int x_4 = 0;
+
+void main_1() {
+ int x_33_phi = 0;
+ vec4 x_18 = x_2;
+ int x_28 = x_3;
+ x_33_phi = 0;
+ if (((((int(x_18.x) & 1) + (int(x_18.y) & 1)) + x_28) == int(x_18.z))) {
+ while (true) {
+ int x_34 = 0;
+ int x_33 = x_33_phi;
+ if ((uint(x_33) < uint(10))) {
+ } else {
+ break;
+ }
+ {
+ x_34 = (x_33 + 1);
+ x_33_phi = x_34;
+ }
+ }
+ }
+ x_4 = 1;
+ return;
+}
+
+struct main_out {
+ int x_4_1;
+};
+struct tint_symbol_2 {
+ int x_3_param;
+ vec4 x_2_param;
+};
+struct tint_symbol_3 {
+ int x_4_1;
+};
+
+main_out tint_symbol_inner(vec4 x_2_param, int x_3_param) {
+ x_2 = x_2_param;
+ x_3 = x_3_param;
+ main_1();
+ main_out tint_symbol_4 = main_out(x_4);
+ return tint_symbol_4;
+}
+
+tint_symbol_3 tint_symbol(tint_symbol_2 tint_symbol_1) {
+ main_out inner_result = tint_symbol_inner(tint_symbol_1.x_2_param, tint_symbol_1.x_3_param);
+ tint_symbol_3 wrapper_result = tint_symbol_3(0);
+ wrapper_result.x_4_1 = inner_result.x_4_1;
+ return wrapper_result;
+}
+in int x_3_param;
+out int x_4_1;
+void main() {
+ tint_symbol_2 inputs;
+ inputs.x_3_param = x_3_param;
+ inputs.x_2_param = gl_FragCoord;
+ tint_symbol_3 outputs;
+ outputs = tint_symbol(inputs);
+ x_4_1 = outputs.x_4_1;
+}
+
+
+Error parsing GLSL shader:
+ERROR: 0:56: 'int' : must be qualified as flat in
+ERROR: 0:56: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+