miasm
Reverse engineering framework
miasm.analysis.data_flow.UnionFind Class Reference
Inheritance diagram for miasm.analysis.data_flow.UnionFind:
Collaboration diagram for miasm.analysis.data_flow.UnionFind:

Public Member Functions

def __init__ (self)
 
def copy (self)
 
def replace_node (self, old_node, new_node)
 
def get_classes (self)
 
def nodes (self)
 
def __eq__ (self, other)
 
def __ne__ (self, other)
 
def __str__ (self)
 
def add_equivalence (self, node_a, node_b)
 
def get_master (self, node)
 
def del_element (self, node)
 
def del_get_new_master (self, node)
 

Public Attributes

 index
 
 node_to_class
 
 order
 

Detailed Description

Implementation of UnionFind structure
__classes: a list of Set of equivalent elements
node_to_class: Dictionary linkink an element to its equivalent class
order: Dictionary link an element to it's weight

The order attributes is used to allow the selection of a representative
element of an equivalence class

Constructor & Destructor Documentation

◆ __init__()

def miasm.analysis.data_flow.UnionFind.__init__ (   self)

Member Function Documentation

◆ __eq__()

def miasm.analysis.data_flow.UnionFind.__eq__ (   self,
  other 
)
Here is the caller graph for this function:

◆ __ne__()

def miasm.analysis.data_flow.UnionFind.__ne__ (   self,
  other 
)

◆ __str__()

def miasm.analysis.data_flow.UnionFind.__str__ (   self)
Here is the caller graph for this function:

◆ add_equivalence()

def miasm.analysis.data_flow.UnionFind.add_equivalence (   self,
  node_a,
  node_b 
)
Add the new equivalence @node_a == @node_b
@node_a is equivalent to @node_b, but @node_b is more representative
than @node_a

◆ copy()

def miasm.analysis.data_flow.UnionFind.copy (   self)
Return a copy of the object
Here is the caller graph for this function:

◆ del_element()

def miasm.analysis.data_flow.UnionFind.del_element (   self,
  node 
)
Remove @node for the equivalence classes

◆ del_get_new_master()

def miasm.analysis.data_flow.UnionFind.del_get_new_master (   self,
  node 
)
Remove @node for the equivalence classes and return it's representative
equivalent element
@node: Element to delete

◆ get_classes()

def miasm.analysis.data_flow.UnionFind.get_classes (   self)
Return a list of the equivalent classes
Here is the caller graph for this function:

◆ get_master()

def miasm.analysis.data_flow.UnionFind.get_master (   self,
  node 
)
Return the representative element of the equivalence class containing
@node
@node: ExprMem or ExprId
Here is the call graph for this function:

◆ nodes()

def miasm.analysis.data_flow.UnionFind.nodes (   self)
Here is the caller graph for this function:

◆ replace_node()

def miasm.analysis.data_flow.UnionFind.replace_node (   self,
  old_node,
  new_node 
)
Replace the @old_node by the @new_node
Here is the call graph for this function:

Member Data Documentation

◆ index

miasm.analysis.data_flow.UnionFind.index

◆ node_to_class

miasm.analysis.data_flow.UnionFind.node_to_class

◆ order

miasm.analysis.data_flow.UnionFind.order

The documentation for this class was generated from the following file: