Kernel Profiler Topics | Next

KernProf Syntax


One Stepkernprof [-a] [-c] [-d] [-f filename] [-i interval] [-n] [-p] [-r] [-s source] [-t lowthreshold] [-v] [-w waittime] [-x] [sampletime]

Where:

-a
displays function address and length and bucket size of the actual functions being called by the kernel.
-c
displays individual counters per call.
-d
computes hit density for each function. This tells you how many times each function is being called, which can be helpful in determining what the majority of the kernel calls are.
-f filename
specifies an output file. The default is output to STDOUT.
-i interval
specifies a sampling interval in 100ns. The default is 10000.
-n
prints hit percentages.
-p
displays per-processor profile objects. This gives you a display for each processor as opposed to combining data for all processors into the same counters.
-r
waits for an Enter keystroke before starting collection.
-s source
specifies a source to use instead of the clock as profile source. kernprof -s ? lists alternative profile sources.
-t lowthreshold
specifies a minimum number of counts to report. The default is 100.
Setting a count for the minimum number of hits for a particular sample can help to limit the amount of data you collect. For example, if you set lowthreshold to 200, you will get all counters that are above 200, while any counters below 200 will not be reported in the output data.
-v
displays verbose symbol information.
-w waittime
sets a wait time of waittime before starting sampling (collection). This is helpful if time is needed to start an application or process before taking a sample.
-x
displays context switch counters. Context switch counters track how many times a process switches from User mode to Kernel mode.
sampletime
specifies, in seconds, how long to collect profile information. The default is to sample until CTRL+C is pressed.