dawn-cmake/test/tint/builtins/repeated_use.wgsl.expected.wgsl
Antonio Maiorano 239a92d2d0 tint: transform::RemovePhonies: skip builtins with no side effects
This transform was attempting to remove builtins with no side
effects, such as a call with abstract int/float args, which is unhandled
by this transform. For example, this would cause the transform to ICE:

_ = clamp(1, 2, 3);

Fixes ClusterFuzz issue crbug.com/1348739.

Bug: chromium:1348739
Change-Id: Ie355eb36c6c020417c2d93f2dc434c11dbb72d1f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/97880
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
2022-08-01 17:21:54 +00:00

16 lines
450 B
WebGPU Shading Language

@compute @workgroup_size(1)
fn main() {
let a = degrees(vec4<f32>());
let b = degrees(vec4<f32>(1.0));
let c = degrees(vec4<f32>(1.0, 2.0, 3.0, 4.0));
let d = degrees(vec3<f32>());
let e = degrees(vec3<f32>(1.0));
let f = degrees(vec3<f32>(1.0, 2.0, 3.0));
let g = degrees(vec2<f32>());
let h = degrees(vec2<f32>(1.0));
let i = degrees(vec2<f32>(1.0, 2.0));
let j = degrees(1.0);
let k = degrees(2.0);
let l = degrees(3.0);
}