Struct binaryninja::mlil::MediumLevelILInstruction
source · pub struct MediumLevelILInstruction {
pub function: Ref<MediumLevelILFunction>,
pub address: u64,
pub index: usize,
pub size: usize,
pub kind: MediumLevelILInstructionKind,
}
Fields§
§function: Ref<MediumLevelILFunction>
§address: u64
§index: usize
§size: usize
§kind: MediumLevelILInstructionKind
Implementations§
source§impl MediumLevelILInstruction
impl MediumLevelILInstruction
pub fn lift(&self) -> MediumLevelILLiftedInstruction
pub fn tokens(&self) -> Array<InstructionTextToken>
sourcepub fn value(&self) -> RegisterValue
pub fn value(&self) -> RegisterValue
Value of expression if constant or a known value
sourcepub fn possible_values(
&self,
options: Option<&[DataFlowQueryOption]>
) -> PossibleValueSet
pub fn possible_values( &self, options: Option<&[DataFlowQueryOption]> ) -> PossibleValueSet
Possible values of expression using path-sensitive static data flow analysis
pub fn possible_ssa_variable_values( &self, ssa_var: SSAVariable, options: Option<&[DataFlowQueryOption]> ) -> PossibleValueSet
sourcepub fn ssa_variable_version(&self, var: Variable) -> SSAVariable
pub fn ssa_variable_version(&self, var: Variable) -> SSAVariable
return the variable version used at this instruction
sourcepub fn branch_dependence(&self) -> Array<BranchDependence>
pub fn branch_dependence(&self) -> Array<BranchDependence>
Set of branching instructions that must take the true or false path to reach this instruction
pub fn branch_dependence_at( &self, instruction: MediumLevelILInstruction ) -> BranchDependence
sourcepub fn ssa_memory_version(&self) -> usize
pub fn ssa_memory_version(&self) -> usize
Version of active memory contents in SSA form for this instruction
sourcepub fn set_expr_type<'a, T: Into<Conf<&'a Type>>>(&self, value: T)
pub fn set_expr_type<'a, T: Into<Conf<&'a Type>>>(&self, value: T)
Set type of expression
This API is only meant for workflows or for debugging purposes, since the changes they make are not persistent and get lost after a database save and reload. To make persistent changes to the analysis, one should use other APIs to, for example, change the type of variables. The analysis will then propagate the type of the variable and update the type of related expressions.
pub fn variable_for_register(&self, reg_id: u32) -> Variable
pub fn variable_for_flag(&self, flag_id: u32) -> Variable
pub fn variable_for_stack_location(&self, offset: i64) -> Variable
pub fn register_value(&self, reg_id: u32) -> RegisterValue
pub fn register_value_after(&self, reg_id: u32) -> RegisterValue
pub fn possible_register_values( &self, reg_id: u32, options: Option<&[DataFlowQueryOption]> ) -> PossibleValueSet
pub fn possible_register_values_after( &self, reg_id: u32, options: Option<&[DataFlowQueryOption]> ) -> PossibleValueSet
pub fn flag_value(&self, flag_id: u32) -> RegisterValue
pub fn flag_value_after(&self, flag_id: u32) -> RegisterValue
pub fn possible_flag_values( &self, flag_id: u32, options: Option<&[DataFlowQueryOption]> ) -> PossibleValueSet
pub fn possible_flag_values_after( &self, flag_id: u32, options: Option<&[DataFlowQueryOption]> ) -> PossibleValueSet
pub fn stack_contents(&self, offset: i64, size: usize) -> RegisterValue
pub fn stack_contents_after(&self, offset: i64, size: usize) -> RegisterValue
pub fn possible_stack_contents( &self, offset: i64, size: usize, options: Option<&[DataFlowQueryOption]> ) -> PossibleValueSet
pub fn possible_stack_contents_after( &self, offset: i64, size: usize, options: Option<&[DataFlowQueryOption]> ) -> PossibleValueSet
sourcepub fn split_var_for_definition(&self, var: Variable) -> Variable
pub fn split_var_for_definition(&self, var: Variable) -> Variable
Gets the unique variable for a definition instruction. This unique variable can be passed
to crate::function::Function::split_variable to split a variable at a definition. The given var
is the
assigned variable to query.
var
- variable to query
sourcepub fn get_split_var_for_definition(&self, var: &Variable) -> Variable
pub fn get_split_var_for_definition(&self, var: &Variable) -> Variable
Trait Implementations§
source§impl Clone for MediumLevelILInstruction
impl Clone for MediumLevelILInstruction
source§fn clone(&self) -> MediumLevelILInstruction
fn clone(&self) -> MediumLevelILInstruction
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more