コード例 #1
0
        private static void removeTypeQuantification(Procedure procedure)
        {
            var qtc = new QuantifiedTypeCollector(procedure);

            foreach (var bb in procedure.blocks)
            {
                foreach (var si in bb.statements)
                {
                    qtc.collect(si.statementId);
                }
            }
            TypeQuantificationRemover.remove(procedure, qtc);
        }
コード例 #2
0
        private static bool commonSubexpressionElimination(Procedure procedure)
        {
            bool cse = false;

            if (cse)
            {
                var ser = new BackwardEvaluator <SubexpressionCounter>(procedure, new SubexpressionCounter(procedure));
                ser.analyze();
                SubexpressionEliminator.appendSubexpressions(procedure);
                procedure.cfg.validate();
            }

            return(cse);
        }
コード例 #3
0
 private StructuredProgramToCFG(Procedure procedure)
 {
     this.procedure = procedure;
     scope          = procedure;
 }
コード例 #4
0
 private static void removeUnusedSymbols(Procedure procedure)
 {
     UnusedSymbolRemover.Remove(procedure);
 }
コード例 #5
0
 private static void consolidateBranchConditionAssignments(Procedure procedure)
 {
     BranchConditionAssignmentConsolidator.consolidate(procedure);
 }
コード例 #6
0
 private static void determinizeBranches(Procedure procedure)
 {
     BranchDeterminizer.analyze(procedure);
 }