MCPcopy Create free account
hub / github.com/dispatchrun/wzprof / newCPUProfiler

Function newCPUProfiler

cpu.go:58–67  ·  view source on GitHub ↗
(p *Profiling, options ...CPUProfilerOption)

Source from the content-addressed store, hash-verified

56}
57
58func newCPUProfiler(p *Profiling, options ...CPUProfilerOption) *CPUProfiler {
59 c := &CPUProfiler{
60 p: p,
61 time: nanotime,
62 }
63 for _, opt := range options {
64 opt(c)
65 }
66 return c
67}
68
69// StartProfile begins recording the CPU profile. The method returns a boolean
70// to indicate whether starting the profile succeeded (e.g. false is returned if

Callers 1

CPUProfilerMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected