Programmer
Programmer

Reputation: 8697

Trace a code flow in VIsual Studio

We have our C++ project codebase developed in VC++ IDE. I can compile and run the same.

The executable covers a lot of scenarios and flow executions. Is there a way by which during a flow execution - the VC++ Studio can tell us which are the methods the flow entered or trace the flow.

Assume that 3 functions are called out of 10 during a flow execution. Can we get a trace stating the 3 functions entered during execution in order?

Upvotes: 1

Views: 4744

Answers (1)

dave
dave

Reputation: 575

In Visual Studio 2015(+), there is a 'Call Stack' window that can be used to do exactly what you are describing. With that being said, it still does require you to place at least one break-point somewhere. See this post for more information.

So what you can do is launch the application, then from Visual Studio click Debug > Windows > Call Stack. Unfortunately this window will remain empty until you designate a break-point somewhere in your script - somewhat frustrating. However the Call Stack window does provide more information than simply placing breakpoints in code and performing manual tracing.

Hopefully this information will help your project!

Upvotes: 1

Related Questions