IgProf profile dump format

The IgProf output is a simple text file, possibly gzip / bzip2 compressed. The first few lines of the output look like this:

P=(ID=32365 N=(ls) T=0.010000)
C1 FN0=(F0=(/lib/tls/libc.so.6)+87962 N=(__libc_start_main))+218
C2 FN1=(F1=(ls)+8661 N=(strcoll))+2753
C3 FN2=(F1+14168 N=(strftime))+8740
C4 FN3=(F1+19717 N=(@?0x804cd05))+0
C5 FN4=(F0+171919 N=(qsort))+143
C6 FN5=(F0+171435 N=(@?0x13adab))+0
C7 FN5+0
C8 FN5+0
C9 FN6=(F0+171396 N=(@?0x13ad84))+0
C10 FN5+0
C11 FN5+0
C12 FN7=(F0+171552 N=(@?0x13ae20))+0
C13 FN8=(F1+19068 N=(@?0x804ca7c))+0
C14 FN9=(F1+17715 N=(@?0x804c533))+0 V0=(PERF_TICKS):(1,1,1)
C3 FN2+8334 V0:(1,1,1)
C3 FN2+8538

Each line of the profile output describes one piece of information, usually just a call frame. The general format is “keyword”, usually just one letter, either a reference or a definition, followed by trailing data. For example A1=(foo)+5 would be definition of instance 1 of type A, whose parameters are foo, followed by delta offset 5. A simple A1 would be a reference to an already redefined entity 1 of type A. A1+4 would be a delta offset 4 of instance 1 of type A. Every instance is defined before referred to, no instance is defined twice, and a definition may occur anywhere a reference could.

The possible top level entities are:

The call stack (C) entries may be followed function descriptor and counter values. The function descriptors are composed of: