HP Caliper Ktrace Features Guide

A Sample ktracedump Output
Appendix A shows an example of the content of a ktrace.out file. This output was
produced by running:
ktracer -w workload > ktrace.out
ktracer: INFO: starting workload 'workloadat Mon Jul 9 15:12:51 2007
ktracer: INFO: finished workload 'workload' at Mon Jul 9 15:12:51 2007
Executing: ktracedump D ktracedump 3.4.2 2007/04/02 20:00
ktracedump compiled on Jun 12 2007 10:31:56
ktracedump invoked on Mon Jul 9 15:12:54 2007
Kernel release_version = @(#)
$Revision: vmunix:jazz @ 20070618.12:13:06PDT;
jmkvw -proj kern1 -RW -c Task: r11.31(R11.31_BL2007_0612);
FLAVOR=perf Kernel linkstamp = Mon Jun 18 12:16:14 PDT 2007
AbsTime and ElTime are in iticks. itick/sec=1.000 GHz nanosec/itick=1.000
AbsTime is adjusted by tod_info.offset_correction
The circular trace buffers hold 2048 traces per CPU.
2 CPUs are traced, making 4096 traces total. nmpinfo=2
The traces consume 0.6 Mb (160 pages) of memory.
Q total # of traces gathered = 12
C Spu 1; 12 traces; The columns mean:
C column# Header - Description - Format
C ------- ------ - ------------------------------------ - ------
F 1 H - Awk Parse Info %1s
F 2 ZSeq - Zero-based Sequence number %611u
F 3 Cpu - Processor Number %3u
F 4 PID - PID (process ID) %5d
F 5 SpnD - Spinlock Depth %4d
F 6 Function - Traced function (callee) %-20s
F 7 ElUSec - Elapsed Time in microseconds.ns %10.31f
F 8 PSR - PSR pp/ic/pk/dt/i = pCPDI when on, _off %5s
F 9 SymArg0 - Symbolic Name for Function Argument %-18s
#
H ZSeq Cpu PID SpnD Function ElUSec PSR SymArg0
T 0 1 28231 0 syscall 0.000 pCPDI siginhibit
T 1 1 28231 0 syscall 21.719 pCPDI sigenable
T 2 1 28231 0 syscall 1.621 pCPDI kill
T 3 1 28231 0 syscall 7.956 pCPDI siginhibit
T 4 1 28231 0 syscall 5.267 pCPDI sigenable
T 5 1 28231 0 syscall 2.150 pCPDI wait
T 6 1 28231 1 resume_cleanup 5.190 pCPD_ 0x10
T 7 1 28234 1 swtch 436.322 pCPDI 0xe00000013c076b80
T 8 1 28234 1 resume_cleanup 3.677 pCPD_ 0x10
T 9 1 28231 0 syscall 31.407 pCPDI time
T 10 1 28231 0 syscall 46.232 pCPDI toolbox
T 11 1 28231 0 syscall 1.907 pCPDI toolbox
With the dump output to ktrace.out you can create a function histogram where:
T = Trace record, $6 = Function (column 6)
egrep "^T" ktrace.out | awk '{print $6}' | sort | uniq -c
2 resume_cleanup
1 swtch
9 syscall
33