[][src]Struct cranelift_codegen_meta::cdsl::types::VectorType

pub(crate) struct VectorType {
    base: LaneType,
    lanes: u64,
}

A concrete SIMD vector type.

A vector type has a lane type which is an instance of LaneType, and a positive number of lanes.

Fields

base: LaneTypelanes: u64

Methods

impl VectorType[src]

pub fn new(base: LaneType, lanes: u64) -> Self[src]

Initialize a new integer type with n bits.

pub fn doc(&self) -> String[src]

Return a string containing the documentation comment for this vector type.

pub fn lane_bits(&self) -> u64[src]

Return the number of bits in a lane.

pub fn lane_count(&self) -> u64[src]

Return the number of lanes.

pub fn lane_type(&self) -> LaneType[src]

Return the lane type.

pub fn number(&self) -> u8[src]

Find the unique number associated with this vector type.

Vector types are encoded with the lane type in the low 4 bits and log2(lanes) in the high 4 bits, giving a range of 2-256 lanes.

Trait Implementations

impl Clone for VectorType[src]

impl Debug for VectorType[src]

impl Display for VectorType[src]

impl Eq for VectorType[src]

impl From<VectorType> for ValueType[src]

Create a ValueType from a given vector type.

impl Hash for VectorType[src]

impl PartialEq<VectorType> for VectorType[src]

impl StructuralEq for VectorType[src]

impl StructuralPartialEq for VectorType[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.