pub trait Swizzle2<const INPUT_LANES: usize, const OUTPUT_LANES: usize> {
const INDEX: [Which; OUTPUT_LANES];
fn swizzle2<T>(
first: Simd<T, INPUT_LANES>,
second: Simd<T, INPUT_LANES>
) -> Simd<T, OUTPUT_LANES>
where
T: SimdElement,
LaneCount<INPUT_LANES>: SupportedLaneCount,
LaneCount<OUTPUT_LANES>: SupportedLaneCount,
{ ... }
}🔬This is a nightly-only experimental API. (
portable_simd #86656)Expand description
Create a vector from the elements of two other vectors.
Required Associated Constants§
sourceconst INDEX: [Which; OUTPUT_LANES]
const INDEX: [Which; OUTPUT_LANES]
🔬This is a nightly-only experimental API. (
portable_simd #86656)Map from the lanes of the input vectors to the output vector
Provided Methods§
sourcefn swizzle2<T>(
first: Simd<T, INPUT_LANES>,
second: Simd<T, INPUT_LANES>
) -> Simd<T, OUTPUT_LANES>where
T: SimdElement,
LaneCount<INPUT_LANES>: SupportedLaneCount,
LaneCount<OUTPUT_LANES>: SupportedLaneCount,
fn swizzle2<T>(
first: Simd<T, INPUT_LANES>,
second: Simd<T, INPUT_LANES>
) -> Simd<T, OUTPUT_LANES>where
T: SimdElement,
LaneCount<INPUT_LANES>: SupportedLaneCount,
LaneCount<OUTPUT_LANES>: SupportedLaneCount,
🔬This is a nightly-only experimental API. (
portable_simd #86656)Create a new vector from the lanes of first and second.
Lane i is first[j] when Self::INDEX[i] is First(j), or second[j] when it is
Second(j).