#[repr(C, align(16))]pub struct i8x16 { /* private fields */ }
Implementations§
source§impl i8x16
impl i8x16
pub fn new(array: [i8; 16]) -> Self
sourcepub fn from_i16x16_saturate(v: i16x16) -> i8x16
pub fn from_i16x16_saturate(v: i16x16) -> i8x16
converts i16
to i8
, saturating values that are too large
sourcepub fn from_i16x16_truncate(v: i16x16) -> i8x16
pub fn from_i16x16_truncate(v: i16x16) -> i8x16
converts i16
to i8
, truncating the upper bits if they are set
pub fn blend(self, t: Self, f: Self) -> Self
pub fn abs(self) -> Self
pub fn unsigned_abs(self) -> u8x16
pub fn max(self, rhs: Self) -> Self
pub fn min(self, rhs: Self) -> Self
pub fn from_slice_unaligned(input: &[i8]) -> Self
pub fn move_mask(self) -> i32
pub fn any(self) -> bool
pub fn all(self) -> bool
sourcepub fn swizzle(self, rhs: i8x16) -> i8x16
pub fn swizzle(self, rhs: i8x16) -> i8x16
Returns a new vector where each element is based on the index values in
rhs
.
- Index values in the range
[0, 15]
select the i-th element ofself
. - Index values that are out of range will cause that output lane to be
0
.
sourcepub fn swizzle_relaxed(self, rhs: i8x16) -> i8x16
pub fn swizzle_relaxed(self, rhs: i8x16) -> i8x16
Works like swizzle
with the following additional details
- Indices in the range
[0, 15]
will select the i-th element ofself
. - If the high bit of any index is set (meaning that the index is negative), then the corresponding output lane is guaranteed to be zero.
- Otherwise the output lane is either
0
orself[rhs[i] % 16]
, depending on the implementation.
pub fn none(self) -> bool
pub fn saturating_add(self, rhs: Self) -> Self
pub fn saturating_sub(self, rhs: Self) -> Self
pub fn to_array(self) -> [i8; 16]
pub fn as_array_ref(&self) -> &[i8; 16]
pub fn as_array_mut(&mut self) -> &mut [i8; 16]
Trait Implementations§
source§impl AddAssign<&i8x16> for i8x16
impl AddAssign<&i8x16> for i8x16
source§fn add_assign(&mut self, rhs: &Self)
fn add_assign(&mut self, rhs: &Self)
Performs the
+=
operation. Read moresource§impl AddAssign for i8x16
impl AddAssign for i8x16
source§fn add_assign(&mut self, rhs: Self)
fn add_assign(&mut self, rhs: Self)
Performs the
+=
operation. Read moresource§impl BitAndAssign<&i8x16> for i8x16
impl BitAndAssign<&i8x16> for i8x16
source§fn bitand_assign(&mut self, rhs: &Self)
fn bitand_assign(&mut self, rhs: &Self)
Performs the
&=
operation. Read moresource§impl BitAndAssign for i8x16
impl BitAndAssign for i8x16
source§fn bitand_assign(&mut self, rhs: Self)
fn bitand_assign(&mut self, rhs: Self)
Performs the
&=
operation. Read moresource§impl BitOrAssign<&i8x16> for i8x16
impl BitOrAssign<&i8x16> for i8x16
source§fn bitor_assign(&mut self, rhs: &Self)
fn bitor_assign(&mut self, rhs: &Self)
Performs the
|=
operation. Read moresource§impl BitOrAssign for i8x16
impl BitOrAssign for i8x16
source§fn bitor_assign(&mut self, rhs: Self)
fn bitor_assign(&mut self, rhs: Self)
Performs the
|=
operation. Read moresource§impl BitXorAssign<&i8x16> for i8x16
impl BitXorAssign<&i8x16> for i8x16
source§fn bitxor_assign(&mut self, rhs: &Self)
fn bitxor_assign(&mut self, rhs: &Self)
Performs the
^=
operation. Read moresource§impl BitXorAssign for i8x16
impl BitXorAssign for i8x16
source§fn bitxor_assign(&mut self, rhs: Self)
fn bitxor_assign(&mut self, rhs: Self)
Performs the
^=
operation. Read moresource§impl PartialEq for i8x16
impl PartialEq for i8x16
source§impl SubAssign<&i8x16> for i8x16
impl SubAssign<&i8x16> for i8x16
source§fn sub_assign(&mut self, rhs: &Self)
fn sub_assign(&mut self, rhs: &Self)
Performs the
-=
operation. Read moresource§impl SubAssign for i8x16
impl SubAssign for i8x16
source§fn sub_assign(&mut self, rhs: Self)
fn sub_assign(&mut self, rhs: Self)
Performs the
-=
operation. Read moreimpl Copy for i8x16
impl Eq for i8x16
impl Pod for i8x16
impl StructuralPartialEq for i8x16
Auto Trait Implementations§
impl Freeze for i8x16
impl RefUnwindSafe for i8x16
impl Send for i8x16
impl Sync for i8x16
impl Unpin for i8x16
impl UnwindSafe for i8x16
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
§type Bits = T
type Bits = T
Self
must have the same layout as the specified Bits
except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern
.source§fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
If this function returns true, then it must be valid to reinterpret
bits
as &Self
.