trace of method calls
am 28.11.2007 11:00:18 von avilellaHi,
I would like to trace all the method calls for a script. What is the
best module people would recommend for this?
Cheers,
Albert.
Hi,
I would like to trace all the method calls for a script. What is the
best module people would recommend for this?
Cheers,
Albert.
On Nov 28, 10:00 am, "avile...@gmail.com"
> Hi,
>
> I would like to trace all the method calls for a script. What is the
> best module people would recommend for this?
>
> Cheers,
>
> Albert.
Hi Albert,
I would use the Perl debugger for this.
perl -d script.pl
tracing is available with 'T' and it toggled with 't'.
Run 'perldoc perldebtut' for more info.
Addionally, I believe the Perl profiler has a similar output support.
Have a look at:
http://search.cpan.org/~nwclark/perl-5.8.6/utils/dprofpp.PL
and
http://search.cpan.org/perldoc?Devel::DProf
hope this helps,
Spiros
avilella@gmail.com wrote:
> Hi,
>
> I would like to trace all the method calls for a script. What is the
> best module people would recommend for this?
Dynamically, or statically?
BugBear
On Nov 28, 10:22 am, bugbear
wrote:
> avile...@gmail.com wrote:
> > Hi,
>
> > I would like to trace all the method calls for a script. What is the
> > best module people would recommend for this?
>
> Dynamically, or statically?
>
> BugBear
I think what I want is statically. I can use breakpoints and "T", but
I rather want to run the script completely and then have a debug file
with all the method calls.
avilella@gmail.com wrote:
> On Nov 28, 10:22 am, bugbear
> wrote:
>> avile...@gmail.com wrote:
>>> Hi,
>>> I would like to trace all the method calls for a script. What is the
>>> best module people would recommend for this?
>> Dynamically, or statically?
>>
>> BugBear
>
> I think what I want is statically. I can use breakpoints and "T", but
> I rather want to run the script completely and then have a debug file
> with all the method calls.
That's "dynamic".
BugBear
On Nov 28, 1:50 pm, bugbear
> avile...@gmail.com wrote:
> > On Nov 28, 10:22 am, bugbear
> > wrote:
> >> avile...@gmail.com wrote:
> >>> Hi,
> >>> I would like to trace all the method calls for a script. What is the
> >>> best module people would recommend for this?
> >> Dynamically, or statically?
>
> >> BugBear
>
> > I think what I want is statically. I can use breakpoints and "T", but
> > I rather want to run the script completely and then have a debug file
> > with all the method calls.
>
> That's "dynamic".
>
> BugBear
oh, ok, dynamic then :-)
Anyone?
On Nov 28, 3:12 pm, "avile...@gmail.com"
> On Nov 28, 1:50 pm, bugbear
>
>
>
> > avile...@gmail.com wrote:
> > > On Nov 28, 10:22 am, bugbear
> > > wrote:
> > >> avile...@gmail.com wrote:
> > >>> Hi,
> > >>> I would like to trace all the method calls for a script. What is the
> > >>> best module people would recommend for this?
> > >> Dynamically, or statically?
>
> > >> BugBear
>
> > > I think what I want is statically. I can use breakpoints and "T", but
> > > I rather want to run the script completely and then have a debug file
> > > with all the method calls.
>
> > That's "dynamic".
>
> > BugBear
>
> oh, ok, dynamic then :-)
>
> Anyone?
Hi,
then use the Perl profiler and analyze its output with dprofpp.
from the manpage:
-T Display subroutine call tree to stdout. Subroutine
statistics are
not displayed.
-t Display subroutine call tree to stdout. Subroutine
statistics are
not displayed. When a function is called multiple
consecutive
times at the same calling level then it is displayed once
with a
repeat count.
Hope this helps,
Spiros