C ++ Call Routing Modes

I am looking for a tool that will report / resolve for every function all the call paths (call it “routes”).

For instance:

void deeper(int *pNumber)
{
 *pNumber++;
}
void gateA(int *pNumber)
{
 deeper(pNumber);
}
void gateB(int *pNumber)
{
 gateA(pNumber);
}

void main()
{
 int x = 123;
 gateA(&x);
 gateB(&x);
}

Cm? I need a tool that will tell me all the routes to the deeper () and, if possible, more.

By saying more, I mean that it will tell me if the pointer is the same as for the calling function.

It will save me a lot. Thank!

+5
source share
3 answers

Doxygen will do it for you. He would draw you beautiful inheritance trees and show you all who call (and call) your functions.

+5
source

, cppDepend ( )

+6

you can look at the clang analyzer .

Clang Static Analyzer is a source code analysis tool that finds errors in C / C ++ and Objective-C programs.

I have not tried, but looking at the screenshots of the code review may be useful

+1
source

All Articles