/// End the current basic block. Must be called after emitting vcode insts
/// for IR insts and prior to ending the function (building the VCode).
End the current basic block. Must be called after emitting vcode insts
for IR insts and prior to ending the function (building the VCode).
End the current basic block . Must be called after emitting vcode insts for IR insts and prior to ending the function ( building the VCode ) .
pub fn end_bb(&mut self) -> BlockIndex {
        assert!(self.ir_inst_insns.is_empty());
        let block_num = self.vcode.block_ranges.len() as BlockIndex;
        // Push the instructions.
        let start_idx = self.vcode.insts.len() as InsnIndex;
        while let Some(i) = self.bb_insns.pop() {
            self.vcode.insts.push(i);
        }
        let end_idx = self.vcode.insts.len() as InsnIndex;
        // Add the instruction index range to the list of blocks.
        self.vcode.block_ranges.push((start_idx, end_idx));
        // End the successors list.
        let succ_end = self.vcode.block_succs.len();
        self.vcode
            .block_succ_range
            .push((self.succ_start, succ_end));
        self.succ_start = succ_end;
        block_num
    }
pub fn end_bb ( & mut self ) -> BlockIndex { assert ! ( self ir_inst_insns is_empty ( ) ) ; let block_num = self . vcode . block_ranges . len ( ) as BlockIndex ; // Push the instructions. let start_idx = self . vcode . insts . len ( ) as InsnIndex ; while let Some ( i ) = self . bb_insns . pop ( ) { self . vcode . insts . push ( i ) ; } let end_idx = self . vcode . insts . len ( ) as InsnIndex ; // Add the instruction index range to the list of blocks. self . vcode . block_ranges . push ( ( start_idx , end_idx ) ) ; // End the successors list. let succ_end = self . vcode . block_succs . len ( ) ; self . vcode . block_succ_range . push ( ( self . succ_start , succ_end ) ) ; self . succ_start = succ_end ; block_num }
End the current basic block.
End the current basic block .
&mut self