MCPcopy Create free account
hub / github.com/google/pprof / busyLoop

Function busyLoop

internal/report/testdata/sample/sample.go:43–55  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

41}
42
43func busyLoop() {
44 m := make(map[int]int)
45 for i := 0; i < 1000000; i++ {
46 m[i] = i + 10
47 }
48 var sum float64
49 for i := 0; i < 100; i++ {
50 for _, v := range m {
51 sum += math.Abs(float64(v))
52 }
53 }
54 fmt.Println("Sum", sum)
55}

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…