filtercalltree(1) BSD General Commands Manual filtercalltree(1)NAME
filtercalltree -- Filter or prune a call tree file generated by sample or malloc_history
SYNOPSIS
filtercalltree call-tree-file [-invertCallTree] [-pruneCount count] [-pruneMallocSize size] [-chargeSystemLibraries]
[-chargeLibrary libraryName] [-keepBoundaries]
DESCRIPTION
filtercalltree reads a file containing a call tree, as generated by the sample(1) or malloc_history(1) commands, and filters or prunes it as
specified by the options.
OPTIONS -invertCallTree Print the call tree from hottest to coldest stack frame.
-pruneCount count Remove branches of the call tree that have count less than count
-pruneMallocSize size Remove branches of the call tree that have malloc size less than size, such as 500K or 1.2M.
-chargeSystemLibraries Remove stack frames from all libraries in /System and /usr, while still charging their cost to the caller.
-chargeLibrary library-name
Remove stack frames from library-name, while still charging their cost to the caller. This argument can be repeated
for multiple libraries.
-keepBoundaries When charging libraries to callers, keep the top call into excluded libraries.
SEE ALSO malloc_history(1), sample(1)BSD May 7, 2011 BSD
Check Out this Related Man Page
stringdups(1) BSD General Commands Manual stringdups(1)NAME
stringdups -- Identify duplicate strings or other objects in malloc blocks of a target process
SYNOPSIS
stringdups [-minimumCount count] [-stringsOnly] [-nostacks] [-callTrees] [-invertCallTrees] pid | partial-executable-name
DESCRIPTION
stringdups examines the content of malloc blocks in the specified target process. For all blocks which have the same content, it shows a
line with the number of such blocks, their total allocated size (the total size in the malloc heap, not just the specific size of their con-
tent), and the average allocated size.
If the MallocStackLogging environment variable was set when the target process was launched, stringdups also displays stack backtraces or
call trees showing where all the blocks with a particular grouping of content were allocated.
stringdups gathers the content of blocks of various types including:
o C strings (composed of UTF8 characters, null terminated, of any length)
o Pascal strings (composed of UTF8 characters with length byte at start, no longer than 255 characters, not necessarily null terminated)
o NSString of all types (immutable, mutable, UTF8, Unicode). Malloc blocks which are the storage blocks for non-inline or mutable
NSString's are listed separately. The string content is shown for both but the block sizes accurately show what is allocated in the mal-
loc heap for that particular chunk of storage.
o NSDate
o NSNumber
o NSPathStore2 (Cocoa's representation of file paths)
o item counts for collection classes such as NSArray, NSSet, and NSDictionary
OPTIONS -minimumCount count Only print information for object descriptions which appear at least count times in the target process. The default
minimum count is 2. To see all strings in the target process, use 1 or use 'heap <pid> -addresses all'.
-stringsOnly Only print information for objects that have string content such as C or Pascal strings, or NSString.
-nostacks Do not print stack backtraces or call trees even if the target process has the MallocStackLogging environment variable
set.
-callTrees If stack bactraces are available, then by default all the object descriptions for a particular stack backtrace are con-
solidated together. However if this argument is passed then the output is consolidated by each particular string and a
call tree is displayed showing the allocation backtraces of all occurrences of objects with that description. This out-
put can be very lengthy if minimumCount is a low value, because the same call tree may be displayed many times.
-invertCallTrees Same as except that the call trees are printed from hottest to coldest stack frame, so the leaf malloc call appears
first.
SEE ALSO heap(1), leaks(1), malloc_history(1), vmmap(1), DevToolsSecurity(1)BSD July 21, 2011 BSD