Function spirv_std::arch::subgroup_broadcast

source ·
pub unsafe fn subgroup_broadcast<T: VectorOrScalar>(value: T, id: u32) -> T
Expand description

Result is the Value of the invocation identified by the id Id to all active invocations in the group.

Result Type must be a scalar or vector of floating-point type, integer type, or Boolean type.

Execution is a Scope that identifies the group of invocations affected by this command. It must be Subgroup.

The type of Value must be the same as Result Type.

Id must be a scalar of integer type, whose Signedness operand is 0.

Before version 1.5, Id must come from a constant instruction. Starting with version 1.5, this restriction is lifted. However, behavior is undefined when Id is not dynamically uniform.

The resulting value is undefined if Id is an inactive invocation, or is greater than or equal to the size of the group.

Requires Capability GroupNonUniformBallot.