On Fri, Nov 06, 2009 at 02:44:22PM +0000, Joel Reymont wrote:
> I'm trying to collect function calls in Firefox in the time order.
> 
> I want just the XUL library but I must not miss any functions since I  
> will be feeding the list to the linker for reordering of symbols.
> 
> I collect about 11Gb of function names but I can't manage to eliminate  
> drops despite increasing the buffer size and switch rate, e.g.
> 
> grep CPU time.order
> __ZL15SelectorMatchesR17RuleProcessorDataP13nsCSSSelectordtrace:  
> 684061 drops on CPU 0
> __ZNK19ndtrace: 205307 drops on CPU 0
> 
> Should I further increase the buffer size? Any other suggestions?
> 
> In reality, I just want the first invocation of each function but I  
> think keeping track of calls will take too much memory in DTrace, e.g.  
> one associative array for the time order, indexed on timestamp or  
> similar, plus another array indexed on the function name.

This is custom-fit for an aggregation.  Try:

pid$target:library::entry
{
        @a[probefunc] = min(timestamp);
}

The aggregation will automatically only keep one record per function per CPU,
which should significantly reduce the data traffic.

Cheers,
- jonathan

_______________________________________________
dtrace-discuss mailing list
dtrace-discuss@opensolaris.org

Reply via email to