pub struct VCodeGenerator<I, S>where
S: InstructionSelector<Instruction = I>,
I: Instr,{ /* private fields */ }Expand description
VCodeGenerator is an internal structure used to generate VCode for a given backend.
Implementations§
Source§impl<I, S> VCodeGenerator<I, S>where
S: InstructionSelector<Instruction = I>,
I: Instr,
impl<I, S> VCodeGenerator<I, S>where
S: InstructionSelector<Instruction = I>,
I: Instr,
Sourcepub fn new_unassociated_vreg(&mut self) -> VReg
pub fn new_unassociated_vreg(&mut self) -> VReg
Sourcepub fn func_map(&self) -> &HashMap<FunctionId, usize>
pub fn func_map(&self) -> &HashMap<FunctionId, usize>
Returns the map from IR FunctionIds to indexes into the VCode’s list of functions.
Sourcepub fn label_map(&self) -> &HashMap<BasicBlockId, usize>
pub fn label_map(&self) -> &HashMap<BasicBlockId, usize>
Returns the map from IR BasicBlockIds to indexes into the current function’s list of
labels.
pub fn push_prelabel_instruction(&mut self, instruction: I)
pub fn push_prereturn_instruction(&mut self, instruction: I)
Sourcepub fn push_instruction(&mut self, instruction: I)
pub fn push_instruction(&mut self, instruction: I)
Pushes an instruction into the VCode being generated.
Auto Trait Implementations§
impl<I, S> Freeze for VCodeGenerator<I, S>
impl<I, S> RefUnwindSafe for VCodeGenerator<I, S>where
S: RefUnwindSafe,
I: RefUnwindSafe,
impl<I, S> Send for VCodeGenerator<I, S>
impl<I, S> Sync for VCodeGenerator<I, S>
impl<I, S> Unpin for VCodeGenerator<I, S>
impl<I, S> UnwindSafe for VCodeGenerator<I, S>where
S: UnwindSafe,
I: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more