Tracing the sequence of method invocations in an application

  • Thread starter Thread starter Stig
  • Start date Start date
S

Stig

I would like to output the sequence of method calls from a running c#
applcaition, but I don't want to add Debug.trace calls at the entry and
exit points in each an every methods.

Does there exist a c# profiler which can profile and then log the
sequence of function calls automatically?

regards

Stig Nielsson
 
Stig,

VS.NET 2005 will do this for you. You can instrument your application,
at a cost, it will cause your application to run much, much slower though.

There are also third party tools on the market that will do this for
you, I would search google for ".NET" and "profiler"

Hope this helps.
 
well, I did some searching before posting, but all profilers I found
seems to deal with performance, ie. how many times each statement is
called etc., and not tracing of the program flow at runtime. I need
this to figure out exactly which and when events are raised in very
complex GUI.

Hope somebody knows a tool for this.

regards Stig Nielsson
 
Stig said:
well, I did some searching before posting, but all profilers I found
seems to deal with performance, ie. how many times each statement is
called etc., and not tracing of the program flow at runtime. I need
this to figure out exactly which and when events are raised in very
complex GUI.

The profiler I use is AQTime 4 by AutomatedQA (www.automatedqa.com). It
can show you a so-called "call tree" after a program run, in which you
can interactively analyse the calls that each method made, and that were
made into each method.

The other thing in AQTime you might want to use is the Sequence Diagram
Link Profiler. From the help file:

"The Sequence Diagram Link profiler analyzes the sequence of function
calls in your application and then builds a UML-style diagram of
function calls in Microsoft Word or Microsoft Visio. It is a convenient
tool to trace links between methods and functions without running the
application. Note that these are potential links between routines, since
the profiler statically analyzes your application and it cannot predict
whether conditional calls will be performed."

I'm quite sure they have a trial version for download on their website,
so it's probably best if you download that and try whether it helps you.


Oliver Sturm
 
ok, thanks. I will investigate it - I hope it is good, as it costs $600
pr. license.

/Stig Nielsson
 
Stig said:
ok, thanks. I will investigate it - I hope it is good, as it costs $600
pr. license.

Well, I think it's that good. But obviously it depends on whether it
solves your particular problem - I just had a look and they have a 15
day trial version, plus a 60 day money back guarantee, so you should be
able to try it out without any commitment.

I don't get anything for advocating the AutomatedQA products, but I do
know several of their people personally and I can assure you that their
products are top and their money back guarantee is for real.


Oliver Sturm
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top