core::arch::wasm64

Function i8x16_shuffle

1.54.0 ยท source
pub fn i8x16_shuffle<const I0: usize, const I1: usize, const I2: usize, const I3: usize, const I4: usize, const I5: usize, const I6: usize, const I7: usize, const I8: usize, const I9: usize, const I10: usize, const I11: usize, const I12: usize, const I13: usize, const I14: usize, const I15: usize>(
    a: v128,
    b: v128,
) -> v128
Available on target_family="wasm" and target feature simd128 and WebAssembly only.
Expand description

Returns a new vector with lanes selected from the lanes of the two input vectors $a and $b specified in the 16 immediate operands.

The $a and $b expressions must have type v128, and this function generates a wasm instruction that is encoded with 16 bytes providing the indices of the elements to return. The indices i in range [0, 15] select the i-th element of a. The indices in range [16, 31] select the i - 16-th element of b.

Note that this is a macro due to the codegen requirements of all of the index expressions $i* must be constant. A compiler error will be generated if any of the expressions are not constant.

All indexes $i* must have the type u32.