예제 #1
0
        /// <summary>
        /// Run analysis starting at EntryMethodGraph
        /// </summary>
        private void analyse()
        {
            EntryInput.CommitTransaction();

            ProgramPointGraph = ProgramPointGraph.FromSource(EntryCFG);
            _services.SetProgramEnd(ProgramPointGraph.End);
            _services.SetServices(ProgramPointGraph);

            var output = _services.CreateEmptySet();

            ProgramPointGraph.Start.Initialize(EntryInput, output);

            _services.EnqueueEntryPoint(ProgramPointGraph.Start, ProgramPointGraph.End);


            //fix point computation
            while (_workList.HasWork)
            {
                var point = _workList.GetWork();

                //during flow through are enqueued all needed flow children
                point.FlowThrough();
            }

            //because of avoid incorrect use
            //_services.UnSetServices(ProgramPointGraph);
        }
예제 #2
0
 public override void VisitSourceMethodValue(SourceMethodValue value)
 {
     Output = ProgramPointGraph.FromSource(value.Declaration, value.DeclaringScript);
 }