00001 00019 #ifndef ManagerCallGraph_H 00020 #define ManagerCallGraph_H 00021 00022 //-------------------------------------------------------------------- 00023 // standard headers 00024 #ifdef NO_STD_CHEADERS 00025 # include <string.h> 00026 #else 00027 # include <cstring> 00028 #endif 00029 00030 // STL headers 00031 #include <list> 00032 #include <set> 00033 #include <map> 00034 00035 // OpenAnalysis headers 00036 #include <OpenAnalysis/Utils/OA_ptr.hpp> 00037 #include <OpenAnalysis/Utils/Util.hpp> 00038 #include <OpenAnalysis/Location/Locations.hpp> 00039 #include <OpenAnalysis/CallGraph/CallGraph.hpp> 00040 #include <OpenAnalysis/Alias/InterAliasInterface.hpp> 00041 #include <OpenAnalysis/IRInterface/CallGraphIRInterface.hpp> 00042 00043 namespace OA { 00044 namespace CallGraph { 00045 00046 00047 //-------------------------------------------------------------------- 00052 class ManagerCallGraphStandard { //??? eventually public OA::AnnotationManager 00053 public: 00054 ManagerCallGraphStandard(OA_ptr<CallGraphIRInterface> _ir); 00055 virtual ~ManagerCallGraphStandard () {} 00056 00057 //??? don't think this guy need AQM, but will eventually have 00058 //to have one so is standard with other AnnotationManagers 00059 //what type of handle are we going to attach the CallGraph to? 00060 virtual OA_ptr<CallGraph> 00061 performAnalysis(OA_ptr<IRProcIterator> procIter, 00062 OA_ptr<Alias::InterAliasInterface> interAlias ); 00063 00064 //------------------------------------- 00065 // information access 00066 //------------------------------------- 00067 OA_ptr<CallGraphIRInterface> getIRInterface() { return mIR; } 00068 00069 //------------------------------------------------------------------ 00070 // Exceptions 00071 //------------------------------------------------------------------ 00079 private: 00080 00081 //------------------------------------------------------------------ 00082 // Methods that build CallGraphStandard 00083 //------------------------------------------------------------------ 00084 void build_graph(OA_ptr<IRProcIterator> funcIter); 00085 00086 private: 00087 OA_ptr<CallGraphIRInterface> mIR; 00088 OA_ptr<CallGraph> mCallGraph; 00089 OA_ptr<Alias::InterAliasInterface> mInterAlias; 00090 00091 }; 00092 //-------------------------------------------------------------------- 00093 00094 } // end of CallGraph namespace 00095 } // end of OA namespace 00096 00097 #endif
1.6.1