Struct falcon::il::Block [−][src]
pub struct Block { /* fields omitted */ }
A basic block in Falcon IL.
Methods
impl Block
[src]
impl Block
pub fn address(&self) -> Option<u64>
[src]
pub fn address(&self) -> Option<u64>
Get the address of the first instruction in this block
pub fn append(&mut self, other: &Block)
[src]
pub fn append(&mut self, other: &Block)
Appends the contents of another Block
to this Block
.
Instruction indices are updated accordingly.
pub fn index(&self) -> usize
[src]
pub fn index(&self) -> usize
Returns the index of this Block
pub fn instructions(&self) -> &Vec<Instruction>
[src]
pub fn instructions(&self) -> &Vec<Instruction>
Returns instructions for this Block
pub fn instructions_mut(&mut self) -> &mut Vec<Instruction>
[src]
pub fn instructions_mut(&mut self) -> &mut Vec<Instruction>
Returns a mutable reference to the instructions for this Block
.
pub fn is_empty(&self) -> bool
[src]
pub fn is_empty(&self) -> bool
Returns try if this Block
is empty, meaning it has no Instruction
pub fn instruction(&self, index: usize) -> Option<&Instruction>
[src]
pub fn instruction(&self, index: usize) -> Option<&Instruction>
Returns an Instruction
by index, or None
if the instruction does not
exist.
pub fn instruction_mut(&mut self, index: usize) -> Option<&mut Instruction>
[src]
pub fn instruction_mut(&mut self, index: usize) -> Option<&mut Instruction>
Returns a mutable reference to an Instruction
by index, or None
if
the Instruction
does not exist.
pub fn remove_instruction(&mut self, index: usize) -> Result<()>
[src]
pub fn remove_instruction(&mut self, index: usize) -> Result<()>
Deletes an Instruction
by its index.
pub fn temp(&mut self, bits: usize) -> Scalar
[src]
pub fn temp(&mut self, bits: usize) -> Scalar
Generates a temporary scalar unique to this block.
pub fn assign(&mut self, dst: Scalar, src: Expression)
[src]
pub fn assign(&mut self, dst: Scalar, src: Expression)
Adds an assign operation to the end of this block.
pub fn store(&mut self, address: Expression, src: Expression)
[src]
pub fn store(&mut self, address: Expression, src: Expression)
Adds a store operation to the end of this block.
pub fn load(&mut self, dst: Scalar, address: Expression)
[src]
pub fn load(&mut self, dst: Scalar, address: Expression)
Adds a load operation to the end of this block.
pub fn branch(&mut self, dst: Expression)
[src]
pub fn branch(&mut self, dst: Expression)
Adds a conditional branch operation to the end of this block.
pub fn intrinsic(&mut self, intrinsic: Intrinsic)
[src]
pub fn intrinsic(&mut self, intrinsic: Intrinsic)
Adds an intrinsic operation to the end of this block.
pub fn nop(&mut self)
[src]
pub fn nop(&mut self)
Adds a nop operation to the end of this block.
Trait Implementations
impl Clone for Block
[src]
impl Clone for Block
fn clone(&self) -> Block
[src]
fn clone(&self) -> Block
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Debug for Block
[src]
impl Debug for Block
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Eq for Block
[src]
impl Eq for Block
impl Hash for Block
[src]
impl Hash for Block
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl Ord for Block
[src]
impl Ord for Block
fn cmp(&self, other: &Block) -> Ordering
[src]
fn cmp(&self, other: &Block) -> Ordering
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
1.21.0[src]
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
impl PartialEq for Block
[src]
impl PartialEq for Block
fn eq(&self, other: &Block) -> bool
[src]
fn eq(&self, other: &Block) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Block) -> bool
[src]
fn ne(&self, other: &Block) -> bool
This method tests for !=
.
impl PartialOrd for Block
[src]
impl PartialOrd for Block
fn partial_cmp(&self, other: &Block) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Block) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Block) -> bool
[src]
fn lt(&self, other: &Block) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Block) -> bool
[src]
fn le(&self, other: &Block) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Block) -> bool
[src]
fn gt(&self, other: &Block) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Block) -> bool
[src]
fn ge(&self, other: &Block) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Vertex for Block
[src]
impl Vertex for Block
impl Display for Block
[src]
impl Display for Block