diff options
| author | serpilliere <fabrice.desclaux@cea.fr> | 2015-03-21 01:00:38 +0100 |
|---|---|---|
| committer | Fabrice Desclaux <fabrice.desclaux@cea.fr> | 2015-03-23 14:06:51 +0100 |
| commit | af01125f2caccfc8838c3fe5f8b3066f4ddc212f (patch) | |
| tree | 8ab972cd6506759039b898648d2b1f3893f956c1 /test/analysis/depgraph.py | |
| parent | 12a9bed690f7f9fa5e30af13968e2ce52e965448 (diff) | |
| download | miasm-af01125f2caccfc8838c3fe5f8b3066f4ddc212f.tar.gz miasm-af01125f2caccfc8838c3fe5f8b3066f4ddc212f.zip | |
Example: add NoCallNoMem in ida/depgraph
Diffstat (limited to 'test/analysis/depgraph.py')
| -rw-r--r-- | test/analysis/depgraph.py | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/test/analysis/depgraph.py b/test/analysis/depgraph.py index 5484ec02..a661d785 100644 --- a/test/analysis/depgraph.py +++ b/test/analysis/depgraph.py @@ -3,7 +3,7 @@ from miasm2.core.asmbloc import asm_label from miasm2.ir.analysis import ira from miasm2.ir.ir import ir, irbloc from miasm2.core.graph import DiGraph -from miasm2.analysis.depgraph import DependencyNode, DependencyGraph, DependencyDict, DependencyGraph_NoMemory +from miasm2.analysis.depgraph import DependencyNode, DependencyGraph, DependencyDict from pdb import pm a = ExprId("a") @@ -58,9 +58,6 @@ class IRATest(ir, ira): ir.__init__(self, arch, 32, symbol_pool) self.IRDst = pc - def gen_graph(self): - return - class GraphTest(DiGraph): def __init__(self, ira): self.ira = ira @@ -73,9 +70,6 @@ class GraphTest(DiGraph): return False return True - def gen_graph(self): - return - def node2str(self, node): if not node in self.ira.blocs: return str(node) @@ -603,7 +597,9 @@ for i, test in enumerate([(g1_ira, g1_input, [g1_output1]), open("graph_%02d.dot" % (i+1), "w").write(g_ira.g.dot()) # Test classes for g_dep in [DependencyGraph(g_ira), - DependencyGraph_NoMemory(g_ira)]: + DependencyGraph(g_ira, apply_simp=False), + DependencyGraph(g_ira, follow_mem=False), + DependencyGraph(g_ira, follow_mem=False, follow_call=False)]: print " - Class %s" % g_dep.__class__.__name__ ## Test public APIs |