[][src]Struct cranelift_codegen_meta::cdsl::instructions::InstructionPredicate

pub(crate) struct InstructionPredicate {
    node: Option<InstructionPredicateNode>,
}

Fields

node: Option<InstructionPredicateNode>

Methods

impl InstructionPredicate[src]

pub fn new() -> Self[src]

pub fn unwrap(self) -> InstructionPredicateNode[src]

pub fn new_typevar_check(
    inst: &Rc<InstructionContent>,
    type_var: &TypeVar,
    value_type: &ValueType
) -> InstructionPredicateNode
[src]

pub fn new_ctrl_typevar_check(
    value_type: &ValueType
) -> InstructionPredicateNode
[src]

pub fn new_is_field_equal(
    format: &InstructionFormat,
    field_name: &'static str,
    imm_value: String
) -> InstructionPredicateNode
[src]

pub fn new_is_field_equal_ast(
    format: &InstructionFormat,
    field: &FormatField,
    imm_value: String
) -> InstructionPredicateNode
[src]

Used only for the AST module, which directly passes in the format field.

pub fn new_is_signed_int(
    format: &InstructionFormat,
    field_name: &'static str,
    width: usize,
    scale: usize
) -> InstructionPredicateNode
[src]

pub fn new_is_unsigned_int(
    format: &InstructionFormat,
    field_name: &'static str,
    width: usize,
    scale: usize
) -> InstructionPredicateNode
[src]

pub fn new_is_zero_int(
    format: &InstructionFormat,
    field_name: &'static str
) -> InstructionPredicateNode
[src]

pub fn new_is_zero_32bit_float(
    format: &InstructionFormat,
    field_name: &'static str
) -> InstructionPredicateNode
[src]

pub fn new_is_zero_64bit_float(
    format: &InstructionFormat,
    field_name: &'static str
) -> InstructionPredicateNode
[src]

pub fn new_is_all_zeroes(
    format: &InstructionFormat,
    field_name: &'static str
) -> InstructionPredicateNode
[src]

pub fn new_is_all_ones(
    format: &InstructionFormat,
    field_name: &'static str
) -> InstructionPredicateNode
[src]

pub fn new_length_equals(
    format: &InstructionFormat,
    size: usize
) -> InstructionPredicateNode
[src]

pub fn new_is_colocated_func(
    format: &InstructionFormat,
    field_name: &'static str
) -> InstructionPredicateNode
[src]

pub fn new_is_colocated_data(formats: &Formats) -> InstructionPredicateNode[src]

pub fn and(self, new_node: InstructionPredicateNode) -> Self[src]

pub fn or(self, new_node: InstructionPredicateNode) -> Self[src]

pub fn rust_predicate(&self, func_str: &str) -> Option<String>[src]

pub fn type_predicate(&self, func_str: &str) -> Option<String>[src]

Returns the type predicate if this is one, or None otherwise.

pub fn collect_leaves(&self) -> Vec<&InstructionPredicateNode>[src]

Returns references to all the nodes that are leaves in the condition (i.e. by flattening AND/OR).

Trait Implementations

impl Clone for InstructionPredicate[src]

impl Eq for InstructionPredicate[src]

impl Hash for InstructionPredicate[src]

impl Into<InstructionPredicate> for InstructionPredicateNode[src]

impl PartialEq<InstructionPredicate> for InstructionPredicate[src]

impl StructuralEq for InstructionPredicate[src]

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