A stack profile collects sampled call stacks with measurements of execution or resource use. In a flame graph, each rectangle represents a sampled function or system call; its width indicates call count or time, while vertical position shows stack depth. section 9.1.2
Reading a Go pprof flame graph
A Go pprof example shows slowTask() called by main(). Because slowTask() occupies more CPU than quickTask(), its rectangle is wider. The colors help navigation but carry no inherent meaning. Similar profiles can represent memory, network I/O, garbage collection, or other runtime and operating-system activity. section 9.1.2
message Profile {
repeated ValueType sample_type = 1; #1
repeated Sample sample = 2; #2
repeated Mapping mapping = 3; #3
repeated Location location = 4; #4
repeated Function function = 5; #5
repeated string string_table = 6; #6
int64 time_nanos = 9; #7
int64 duration_nanos = 10; #8
repeated int64 comment = 13; #9
}
A pprof Profile records sample types, samples, mappings, locations, functions, string data, and timing metadata. section 9.1.2
