mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-06-24 15:33:42 +00:00
When an initializer is present, use type inference instead of explicitly typing `var` and `let` declarations. This reduces the size of the generated WGSL and improves readability. Change-Id: I241ee2108279b550735945940f2b62bbbd493708 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/132142 Commit-Queue: David Neto <dneto@google.com> Kokoro: Kokoro <noreply+kokoro@google.com> Auto-Submit: James Price <jrprice@google.com> Reviewed-by: David Neto <dneto@google.com>
16 lines
242 B
WebGPU Shading Language
16 lines
242 B
WebGPU Shading Language
fn f_1() {
|
|
var v = vec3i();
|
|
var offset_1 = 0u;
|
|
var count = 0u;
|
|
let x_17 = v;
|
|
let x_18 = offset_1;
|
|
let x_19 = count;
|
|
let x_15 = extractBits(x_17, x_18, x_19);
|
|
return;
|
|
}
|
|
|
|
@compute @workgroup_size(1i, 1i, 1i)
|
|
fn f() {
|
|
f_1();
|
|
}
|