|
def | __init__ (self, ir_arch, expr_to_original_expr=None) |
|
def | add_expr_to_original_expr (self, expr_to_original_expr) |
|
def | is_unkillable_destination (self, lval, rval) |
|
def | get_block_useful_destinations (self, block) |
|
def | is_tracked_var (self, lval, variable) |
|
def | find_definitions_from_worklist (self, worklist, ircfg) |
|
def | find_out_regs_definitions_from_block (self, block, ircfg) |
|
def | add_def_for_incomplete_leaf (self, block, ircfg, reaching_defs) |
|
def | get_useful_assignments (self, ircfg, defuse, reaching_defs) |
|
def | do_dead_removal (self, ircfg) |
|
def | __call__ (self, ircfg) |
|
◆ __init__()
def miasm.analysis.data_flow.DeadRemoval.__init__ |
( |
|
self, |
|
|
|
ir_arch, |
|
|
|
expr_to_original_expr = None |
|
) |
| |
◆ __call__()
def miasm.analysis.data_flow.DeadRemoval.__call__ |
( |
|
self, |
|
|
|
ircfg |
|
) |
| |
◆ add_def_for_incomplete_leaf()
def miasm.analysis.data_flow.DeadRemoval.add_def_for_incomplete_leaf |
( |
|
self, |
|
|
|
block, |
|
|
|
ircfg, |
|
|
|
reaching_defs |
|
) |
| |
Add valid definitions at end of @block plus out regs
◆ add_expr_to_original_expr()
def miasm.analysis.data_flow.DeadRemoval.add_expr_to_original_expr |
( |
|
self, |
|
|
|
expr_to_original_expr |
|
) |
| |
◆ do_dead_removal()
def miasm.analysis.data_flow.DeadRemoval.do_dead_removal |
( |
|
self, |
|
|
|
ircfg |
|
) |
| |
Remove useless assignments.
This function is used to analyse relation of a * complete function *
This means the blocks under study represent a solid full function graph.
Source : Kennedy, K. (1979). A survey of data flow analysis techniques.
IBM Thomas J. Watson Research Division, page 43
@ircfg: IntermediateRepresentation instance
◆ find_definitions_from_worklist()
def miasm.analysis.data_flow.DeadRemoval.find_definitions_from_worklist |
( |
|
self, |
|
|
|
worklist, |
|
|
|
ircfg |
|
) |
| |
Find variables definition in @worklist by browsing the @ircfg
◆ find_out_regs_definitions_from_block()
def miasm.analysis.data_flow.DeadRemoval.find_out_regs_definitions_from_block |
( |
|
self, |
|
|
|
block, |
|
|
|
ircfg |
|
) |
| |
Find definitions of out regs starting from @block
◆ get_block_useful_destinations()
def miasm.analysis.data_flow.DeadRemoval.get_block_useful_destinations |
( |
|
self, |
|
|
|
block |
|
) |
| |
Force keeping of specific cases
block: IRBlock instance
◆ get_useful_assignments()
def miasm.analysis.data_flow.DeadRemoval.get_useful_assignments |
( |
|
self, |
|
|
|
ircfg, |
|
|
|
defuse, |
|
|
|
reaching_defs |
|
) |
| |
Mark useful statements using previous reach analysis and defuse
Return a set of triplets (block, assignblk number, lvalue) of
useful definitions
PRE: compute_reach(self)
◆ is_tracked_var()
def miasm.analysis.data_flow.DeadRemoval.is_tracked_var |
( |
|
self, |
|
|
|
lval, |
|
|
|
variable |
|
) |
| |
◆ is_unkillable_destination()
def miasm.analysis.data_flow.DeadRemoval.is_unkillable_destination |
( |
|
self, |
|
|
|
lval, |
|
|
|
rval |
|
) |
| |
◆ expr_to_original_expr
miasm.analysis.data_flow.DeadRemoval.expr_to_original_expr |
◆ ir_arch
miasm.analysis.data_flow.DeadRemoval.ir_arch |
The documentation for this class was generated from the following file:
- /home/serpilliere/projet/test_doc_miasm/miasm/miasm/analysis/data_flow.py