Ejemplo n.º 1
0
 private void FindPostDominators(ProcedureBuilder m)
 {
     ProcedureStructureBuilder graphs = new ProcedureStructureBuilder(m.Procedure);
     h = graphs.Build();
     sw = new StringWriter();
     graphs.AnalyzeGraph().Write(sw);
 }
Ejemplo n.º 2
0
        private void FindPostDominators(ProcedureBuilder m)
        {
            ProcedureStructureBuilder graphs = new ProcedureStructureBuilder(m.Procedure);

            h  = graphs.Build();
            sw = new StringWriter();
            graphs.AnalyzeGraph().Write(sw);
        }
Ejemplo n.º 3
0
        public void LoopFinder_Reg00013()
        {
            Program prog = RewriteProgramMsdos("Fragments/regressions/r00013.asm", Address.SegPtr(0x800, 0));
            ProcedureStructureBuilder psb = new ProcedureStructureBuilder(prog.Procedures.Values[0]);
            proc = psb.Build();
            psb.AnalyzeGraph();

            proc.Dump();
            var lf = new LoopFinder(proc.Ordering[23], proc.Ordering[0], proc.Ordering);
            var intervalNodes = proc.Nodes[23].Interval.FindIntervalNodes(0);
            var loopNodes = lf.FindNodesInLoop(intervalNodes);
            proc.Dump();
            Loop loop = lf.DetermineLoopType(loopNodes);
            Assert.IsTrue(loop is TestlessLoop);
        }
Ejemplo n.º 4
0
        public void LoopFinder_Reg00013()
        {
            Program prog = RewriteProgramMsdos("Fragments/regressions/r00013.asm", Address.SegPtr(0x800, 0));
            ProcedureStructureBuilder psb = new ProcedureStructureBuilder(prog.Procedures.Values[0]);

            proc = psb.Build();
            psb.AnalyzeGraph();

            proc.Dump();
            var lf            = new LoopFinder(proc.Ordering[23], proc.Ordering[0], proc.Ordering);
            var intervalNodes = proc.Nodes[23].Interval.FindIntervalNodes(0);
            var loopNodes     = lf.FindNodesInLoop(intervalNodes);

            proc.Dump();
            Loop loop = lf.DetermineLoopType(loopNodes);

            Assert.IsTrue(loop is TestlessLoop);
        }
Ejemplo n.º 5
0
 private void RunTest(ProcedureBuilder m)
 {
     var psb = new ProcedureStructureBuilder(m.Procedure);
     proc = psb.Build();
 }
Ejemplo n.º 6
0
        private void RunTest(ProcedureBuilder m)
        {
            var psb = new ProcedureStructureBuilder(m.Procedure);

            proc = psb.Build();
        }
Ejemplo n.º 7
0
 public void BuildProcedureStructure()
 {
     var cfgs = new ProcedureStructureBuilder(proc);
     ProcedureStructure = cfgs.Build();
     cfgs.AnalyzeGraph();
 }