[dtrace-discuss] How to limits stack frames in pid provider with ustack?

Brian Utterback
Thu, 21 Jul 2005 16:43:53 -0000

I am trying to implement a call analyzing graph tool, and I am
trying to get dtrace to capture counts of caller-callee pairs.
My thought on this was to use an aggregate for this, indexing by
the output of ustack. I though to limit the stack frames to only
2, but for some reason, dtrace doesn''t like it when I add the
frame limit:

# dtrace -n pid6886::gettimeofday:entry''{ustack();}''
dtrace: description ''pid6886::gettimeofday:entry'' matched 3
probes
CPU     ID                    FUNCTION:NAME
   1  44286               gettimeofday:entry
               libc.so.1`gettimeofday
               libumem.so.1`umem_update_thread+0x1e4
               libc.so.1`_lwp_start
^C

#dtrace -n pid6886::gettimeofday:entry''{ustack(2);}''
dtrace: invalid probe specifier pid6886::gettimeofday:entry: extraneous
argument ''{ustack(2);}'' ($1 is not referenced)

Any ideas?
--
blu

Remember when SOX compliant meant they were both the same color?
----------------------------------------------------------------------
Brian Utterback - OP/N1 RPE, Sun Microsystems, Inc.
Ph:877-259-7345, Em:brian.utterback-at-ess-you-enn-dot-kom