[tint] Add RW storage textureLoad overloads
Adds them to the intrinsics table but no codegen support yet.
Bug: tint:2007
Change-Id: I4e3b768461ce06016e1ae6a4bf02ca70d0584237
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/145982
Auto-Submit: James Price <jrprice@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
diff --git a/test/tint/builtins/gen/literal/textureLoad/34d97c.wgsl.expected.glsl b/test/tint/builtins/gen/literal/textureLoad/34d97c.wgsl.expected.glsl
new file mode 100644
index 0000000..81b13fb
--- /dev/null
+++ b/test/tint/builtins/gen/literal/textureLoad/34d97c.wgsl.expected.glsl
@@ -0,0 +1,90 @@
+SKIP: FAILED
+
+#version 310 es
+
+layout(rg32ui) uniform highp writeonly uimage2DArray arg_0;
+layout(binding = 0, std430) buffer prevent_dce_block_ssbo {
+ uvec4 inner;
+} prevent_dce;
+
+void textureLoad_34d97c() {
+ uvec4 res = texelFetch(arg_0, ivec3(ivec2(1), 1));
+ prevent_dce.inner = res;
+}
+
+vec4 vertex_main() {
+ textureLoad_34d97c();
+ return vec4(0.0f);
+}
+
+void main() {
+ gl_PointSize = 1.0;
+ vec4 inner_result = vertex_main();
+ gl_Position = inner_result;
+ gl_Position.y = -(gl_Position.y);
+ gl_Position.z = ((2.0f * gl_Position.z) - gl_Position.w);
+ return;
+}
+Error parsing GLSL shader:
+ERROR: 0:3: 'image load-store format' : not supported with this profile: es
+ERROR: 0:3: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+precision highp float;
+
+layout(rg32ui) uniform highp writeonly uimage2DArray arg_0;
+layout(binding = 0, std430) buffer prevent_dce_block_ssbo {
+ uvec4 inner;
+} prevent_dce;
+
+void textureLoad_34d97c() {
+ uvec4 res = texelFetch(arg_0, ivec3(ivec2(1), 1));
+ prevent_dce.inner = res;
+}
+
+void fragment_main() {
+ textureLoad_34d97c();
+}
+
+void main() {
+ fragment_main();
+ return;
+}
+Error parsing GLSL shader:
+ERROR: 0:4: 'image load-store format' : not supported with this profile: es
+ERROR: 0:4: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+
+#version 310 es
+
+layout(rg32ui) uniform highp writeonly uimage2DArray arg_0;
+layout(binding = 0, std430) buffer prevent_dce_block_ssbo {
+ uvec4 inner;
+} prevent_dce;
+
+void textureLoad_34d97c() {
+ uvec4 res = texelFetch(arg_0, ivec3(ivec2(1), 1));
+ prevent_dce.inner = res;
+}
+
+void compute_main() {
+ textureLoad_34d97c();
+}
+
+layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
+void main() {
+ compute_main();
+ return;
+}
+Error parsing GLSL shader:
+ERROR: 0:3: 'image load-store format' : not supported with this profile: es
+ERROR: 0:3: '' : compilation terminated
+ERROR: 2 compilation errors. No code generated.
+
+
+