[][src]Enum cranelift_codegen_meta::cdsl::types::ValueType

pub(crate) enum ValueType {
    Lane(LaneType),
    Reference(ReferenceType),
    Special(SpecialType),
    Vector(VectorType),
}

A concrete SSA value type.

All SSA values have a type that is described by an instance of ValueType or one of its subclasses.

Variants

Lane(LaneType)
Reference(ReferenceType)
Special(SpecialType)
Vector(VectorType)

Methods

impl ValueType[src]

Important traits for LaneTypeIterator
pub fn all_lane_types() -> LaneTypeIterator[src]

Iterate through all of the lane types.

Important traits for SpecialTypeIterator
pub fn all_special_types() -> SpecialTypeIterator[src]

Iterate through all of the special types (neither lanes nor vectors).

Important traits for ReferenceTypeIterator
pub fn all_reference_types() -> ReferenceTypeIterator[src]

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

Return a string containing the documentation comment for this 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 membytes(&self) -> u64[src]

Find the number of bytes that this type occupies in memory.

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

Find the unique number associated with this type.

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

Return the name of this type for generated Rust source files.

pub fn _wider_or_equal(&self, rhs: &ValueType) -> bool[src]

Return true iff:

  1. self and other have equal number of lanes
  2. each lane in self has at least as many bits as a lane in other

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

Return the total number of bits of an instance of this type.

Trait Implementations

impl Clone for ValueType[src]

impl Debug for ValueType[src]

impl Display for ValueType[src]

impl Eq for ValueType[src]

impl From<LaneType> for ValueType[src]

Create a ValueType from a given lane type.

impl From<ReferenceType> for ValueType[src]

Create a ValueType from a given reference type.

impl From<SpecialType> for ValueType[src]

Create a ValueType from a given special type.

impl From<VectorType> for ValueType[src]

Create a ValueType from a given vector type.

impl Hash for ValueType[src]

impl Into<TypeVar> for ValueType[src]

impl PartialEq<ValueType> for ValueType[src]

impl StructuralEq for ValueType[src]

impl StructuralPartialEq for ValueType[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.