MCPcopy Index your code
hub / github.com/CovenantSQL/CovenantSQL / StopProfile

Function StopProfile

utils/profiler.go:59–70  ·  view source on GitHub ↗

StopProfile closes the CPU and memory profiles if they are running.

()

Source from the content-addressed store, hash-verified

57
58// StopProfile closes the CPU and memory profiles if they are running.
59func StopProfile() {
60 if prof.cpu != nil {
61 pprof.StopCPUProfile()
62 prof.cpu.Close()
63 log.Info("CPU profiling stopped")
64 }
65 if prof.mem != nil {
66 pprof.WriteHeapProfile(prof.mem)
67 prof.mem.Close()
68 log.Info("memory profiling stopped")
69 }
70}

Callers 3

mainFunction · 0.92
mainFunction · 0.92
TestStartStopProfileFunction · 0.85

Calls 2

InfoFunction · 0.92
CloseMethod · 0.65

Tested by 1

TestStartStopProfileFunction · 0.68