[][src]Struct cranelift_codegen_meta::cdsl::xform::TransformGroupBuilder

pub(crate) struct TransformGroupBuilder {
    name: &'static str,
    doc: &'static str,
    chain_with: Option<TransformGroupIndex>,
    isa_name: Option<&'static str>,
    pub custom_legalizes: HashMap<String, &'static str>,
    pub transforms: Vec<Transform>,
}

Fields

name: &'static strdoc: &'static strchain_with: Option<TransformGroupIndex>isa_name: Option<&'static str>custom_legalizes: HashMap<String, &'static str>transforms: Vec<Transform>

Methods

impl TransformGroupBuilder[src]

pub fn new(name: &'static str, doc: &'static str) -> Self[src]

pub fn chain_with(self, next_id: TransformGroupIndex) -> Self[src]

pub fn isa(self, isa_name: &'static str) -> Self[src]

pub fn custom_legalize(
    &mut self,
    inst: &Rc<InstructionContent>,
    func_name: &'static str
)
[src]

Add a custom legalization action for inst.

The func_name parameter is the fully qualified name of a Rust function which takes the same arguments as the isa::Legalize actions.

The custom function will be called to legalize inst and any return value is ignored.

pub fn legalize(&mut self, src: DummyDef, dst: Vec<DummyDef>)[src]

Add a legalization pattern to this group.

pub fn build_and_add_to(
    self,
    owner: &mut TransformGroups
) -> TransformGroupIndex
[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, 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.