pub struct SpirVBasicBlock {
pub label_id: u32,
pub instructions: Vec<SpirVInstruction>,
}Expand description
A basic block within a SPIR-V function.
Fields§
§label_id: u32Label ID for this block (OpLabel)
instructions: Vec<SpirVInstruction>Instructions within this block (excluding the label)
Implementations§
Source§impl SpirVBasicBlock
impl SpirVBasicBlock
Sourcepub fn push(&mut self, instr: SpirVInstruction)
pub fn push(&mut self, instr: SpirVInstruction)
Add an instruction.
Sourcepub fn instr_count(&self) -> usize
pub fn instr_count(&self) -> usize
Count the instructions in this block.
Trait Implementations§
Source§impl Clone for SpirVBasicBlock
impl Clone for SpirVBasicBlock
Source§fn clone(&self) -> SpirVBasicBlock
fn clone(&self) -> SpirVBasicBlock
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for SpirVBasicBlock
impl RefUnwindSafe for SpirVBasicBlock
impl Send for SpirVBasicBlock
impl Sync for SpirVBasicBlock
impl Unpin for SpirVBasicBlock
impl UnsafeUnpin for SpirVBasicBlock
impl UnwindSafe for SpirVBasicBlock
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