go - pprof (for golang) doesn't show details for my package -
i've been trying profile go application (evm-specification-miner
) pprof, output not useful:
(pprof) top5 108.59mins of 109.29mins total (99.36%) dropped 607 nodes (cum <= 0.55mins) showing top 5 nodes out of 103 (cum >= 0.98mins) flat flat% sum% cum cum% 107.83mins 98.66% 98.66% 108.64mins 99.40% [evm-specification-miner] 0.36mins 0.33% 98.99% 6mins 5.49% net.dialip 0.30mins 0.28% 99.27% 4.18mins 3.83% net.listenip 0.06mins 0.052% 99.32% 34.66mins 31.71% github.com/urfave/cli.boolflag.applywitherror 0.04mins 0.036% 99.36% 0.98mins 0.9% net.probeipv6stack
and here cumulative output:
(pprof) top5 --cum 1.80hrs of 1.82hrs total (98.66%) dropped 607 nodes (cum <= 0.01hrs) showing top 5 nodes out of 103 (cum >= 1.53hrs) flat flat% sum% cum cum% 1.80hrs 98.66% 98.66% 1.81hrs 99.40% [evm-specification-miner] 0 0% 98.66% 1.53hrs 83.93% net.ip.matchaddrfamily 0 0% 98.66% 1.53hrs 83.92% net.(*udpconn).writetoudp 0 0% 98.66% 1.53hrs 83.90% net.sockaddrtoudp 0 0% 98.66% 1.53hrs 83.89% net.(*udpconn).readmsg
as can see, of time spent in evm-specification-miner
(which name of go application), i've been unable obtain more details or understand these square brackets meant (there a question similar problem, didn't receive answer).
here build , pprof commands:
go install evm-specification-miner go tool pprof evm-specification-miner cpuprof
i've tried debug flags -gcflags "-n -l"
(as noted here: https://golang.org/doc/gdb#introduction), no avail.
the profiling done calls pprof.startcpuprofile()
, pprof.stopcpuprofile()
explained blog post: https://blog.golang.org/profiling-go-programs:
func startprofiling(cpuprof string) error { f, err := os.create(cpuprof) if err != nil { return err } return pprof.startcpuprofile(f) } func stopprofiling() error { pprof.stopcpuprofile() return nil }
startprofiling
called @ beginning of main()
, , stopprofiling
when signal (interrupt or kill) received (or if program terminates normally). profile obtained after interruption.
looks updating 1.9rc1 fixed it.
i no longer have [evm-specifiation-miner]
in profile (for record, top functions not come own package, weirder did not appear before).
Comments
Post a Comment