blob: f29554ba82fe564e4dda7f79df68bbdc6132d878 [file] [log] [blame]
James Price88c231b2023-08-15 12:47:28 +00001// Copyright 2023 The Tint Authors.
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15////////////////////////////////////////////////////////////////////////////////
Ben Clayton57ded6a2023-08-22 13:22:22 +000016// File generated by 'tools/src/cmd/gen' using the template:
James Price88c231b2023-08-15 12:47:28 +000017// test/tint/builtins/gen/gen.wgsl.tmpl
18//
Ben Clayton57ded6a2023-08-22 13:22:22 +000019// To regenerate run: './tools/run gen'
20//
21// Do not modify this file directly
James Price88c231b2023-08-15 12:47:28 +000022////////////////////////////////////////////////////////////////////////////////
23
24
25enable chromium_experimental_read_write_storage_texture;
26@group(1) @binding(0) var arg_0: texture_storage_2d<r32uint, read>;
27
28// fn textureDimensions(texture: texture_storage_2d<r32uint, read>) -> vec2<u32>
29fn textureDimensions_b56112() {
30 var res: vec2<u32> = textureDimensions(arg_0);
31 prevent_dce = res;
32}
33@group(2) @binding(0) var<storage, read_write> prevent_dce : vec2<u32>;
34
35@vertex
36fn vertex_main() -> @builtin(position) vec4<f32> {
37 textureDimensions_b56112();
38 return vec4<f32>();
39}
40
41@fragment
42fn fragment_main() {
43 textureDimensions_b56112();
44}
45
46@compute @workgroup_size(1)
47fn compute_main() {
48 textureDimensions_b56112();
49}