pub unsafe fn permlane16_swap<const FI: bool, const BOUND_CONTROL: bool>(
vdst_old: u32,
vsrc_src0: u32,
) -> (u32, u32)🔬This is a nightly-only experimental API. (
stdarch_amdgpu #149988)Available on AMD GPU only.
Expand description
Provide direct access to v_permlane16_swap_b32 instruction on supported targets.
Swaps the values across lanes of first 2 operands. Odd rows of the first operand are swapped with even rows of the second operand (one row is 16 lanes). Returns a pair for the swapped registers. The first element of the return corresponds to the swapped element of the first argument.
This intrinsic does not behave like a normal function call; it is a “convergent” operation and as such has non-standard control-flow effects which need special treatment by the language. Rust currently does not properly support convergent operations. This operation is hence provided on a best-effort basis. Using it may result in incorrect code under some circumstances.