Trait MaskWiden

pub trait MaskWiden<S: Simd>: SimdMask<S> + Seal

Widening conversion of a SIMD mask, preserving each lane's boolean value.

The results have the same logical bit width as the input, with lanes twice as wide and half as many lanes. The first result contains the lower lanes and the second contains the upper lanes. This is supported for 8-, 16-, and 32-bit lanes at logical widths of 128, 256, and 512 bits, independently of the backend's physical mask representation.

Masks constructed from integer lanes other than 0 or -1 have unspecified behavior.

Associated Types

type Widened: MaskNarrow<S, Narrowed = Self>;

The same logical-width mask type with lanes twice as wide.

Required Methods

fn widen(self) -> (Self::Widened, Self::Widened)

Widen each boolean lane, returning the lower and upper halves in that order.

Implementors