Discussion:
DTrace probes for bleadperl part 2
(too old to reply)
Sven Dowideit
2008-02-15 06:59:18 UTC
Permalink
I've ported my additional DTrace probes to blead perl, and have attached
a patch.

This patch adds
**new-sv and del-sv to track Perl allocations,
**main-enter and main-exit to show what part of Perl's execution phase
we're in
**load-module-entry and load-module-return to instrument use, require, do.

As you can see from the code in op.c, I have not worked out howto get
all the desired information from perl yet - the staggering amount of
TLA's is blowing this 1week old Perl hacker's mind a bit.

Any tips and pointers would be appreciated - I'd like to get this merged :)

I've started to document the probes at
http://wikis.sun.com/display/DTrace/perl+Provider


Cheers

Sven
--
Professional Wiki Innovation and Support
Sven Dowideit - http://DistributedINFORMATION.com
A WikiRing Partner http://wikiring.com
Sven Dowideit
2008-02-17 01:27:46 UTC
Permalink
Heya Andy,

As I have understood it, opmini.c is essentially a copy of op.c, and
I've added the load-module probes to op.c, thus forcing this change. I
think I also saw this resolve some issues when turning on the dtrace
probes while miniperl is running, but that might have been the the
333201 problem I stumbled over.


Sven
$spitshell >>Makefile <<'!NO!SUBS!'
-$(DTRACE_O): perldtrace.d
- $(DTRACE) -G -s perldtrace.d -o $(DTRACE_O) $(ndt_obj)
+$(DTRACE_O): perldtrace.d $(DTRACE_H) $(ndt_obj) opmini.o
+ $(DTRACE) -G -s perldtrace.d -o $(DTRACE_O) $(ndt_obj) opmini.o
I think ndt_obj is everything about from perldtrace.o - so there
should be no need to add opmini.o unless I'm missing something.
--
Professional Wiki Innovation and Support
Sven Dowideit - http://DistributedINFORMATION.com
A WikiRing Partner http://wikiring.com
Loading...