CallGraph.h 631 B

12345678910111213141516171819
  1. #pragma once
  2. #include "Procedure.h"
  3. /* CALL GRAPH NODE */
  4. struct CALL_GRAPH
  5. {
  6. ilFunction proc; /* Pointer to procedure in pProcList */
  7. std::vector<CALL_GRAPH *> outEdges; /* array of out edges */
  8. public:
  9. void write();
  10. CALL_GRAPH()
  11. {
  12. }
  13. public:
  14. void writeNodeCallGraph(int indIdx);
  15. bool insertCallGraph(ilFunction caller, ilFunction callee);
  16. bool insertCallGraph(Function *caller, ilFunction callee);
  17. void insertArc(ilFunction newProc);
  18. };
  19. //extern CALL_GRAPH * callGraph; /* Pointer to the head of the call graph */