The purpose of this issue is to track the differences between our implementation and the WebGPU proposal so that we can ideally move both in the same direction.
Extra WGSL builtin attributes num_subgroups and subgroup_id with polyfill on HLSL.
Extra validation for subgroup_id & subgroup_invocation_id, they are only allowed in compute stages with one dimensional workgroup sizes (since we are not confident that the HLSL polyfill works for workgroup sizes with multiple dimensions; see previous conversation for more info https://github.com/gfx-rs/wgpu/pull/5301#discussion_r1526470201).
The standard changed their naming to match ours, so "Slightly different naming (sum vs add and product vs mul)" can be removed: https://github.com/gpuweb/gpuweb/pull/4627
The purpose of this issue is to track the differences between our implementation and the WebGPU proposal so that we can ideally move both in the same direction.
Subgroup support landed in https://github.com/gfx-rs/wgpu/pull/5301. The WebGPU proposal landed in https://github.com/gpuweb/gpuweb/pull/4368.
Differences:
subgroupElect
.num_subgroups
andsubgroup_id
with polyfill on HLSL.subgroup_id
&subgroup_invocation_id
, they are only allowed in compute stages with one dimensional workgroup sizes (since we are not confident that the HLSL polyfill works for workgroup sizes with multiple dimensions; see previous conversation for more info https://github.com/gfx-rs/wgpu/pull/5301#discussion_r1526470201).