Trait cranelift_codegen::ir::InstInserterBase [−][src]
pub trait InstInserterBase<'f>: Sized { fn data_flow_graph(&self) -> &DataFlowGraph; fn data_flow_graph_mut(&mut self) -> &mut DataFlowGraph; fn insert_built_inst(
self,
inst: Inst,
ctrl_typevar: Type
) -> &'f mut DataFlowGraph; }
Expand description
Base trait for instruction inserters.
This is an alternative base trait for an instruction builder to implement.
An instruction inserter can be adapted into an instruction builder by wrapping it in an
InsertBuilder
. This provides some common functionality for instruction builders that insert
new instructions, as opposed to the ReplaceBuilder
which overwrites existing instructions.
Required methods
fn data_flow_graph(&self) -> &DataFlowGraph
[src]
fn data_flow_graph(&self) -> &DataFlowGraph
[src]Get an immutable reference to the data flow graph.
fn data_flow_graph_mut(&mut self) -> &mut DataFlowGraph
[src]
fn data_flow_graph_mut(&mut self) -> &mut DataFlowGraph
[src]Get a mutable reference to the data flow graph.
fn insert_built_inst(
self,
inst: Inst,
ctrl_typevar: Type
) -> &'f mut DataFlowGraph
[src]
fn insert_built_inst(
self,
inst: Inst,
ctrl_typevar: Type
) -> &'f mut DataFlowGraph
[src]Insert a new instruction which belongs to the DFG.