Skip to content

Commit

Permalink
runtime/pprof: print newly added fields of runtime.MemStats
Browse files Browse the repository at this point in the history
in heap profile with debug mode

Change-Id: I3a80d03a4aa556614626067a8fd698b3b00f4290
Reviewed-on: https://go-review.googlesource.com/36962
Reviewed-by: Austin Clements <austin@google.com>
  • Loading branch information
hyangah committed Feb 15, 2017
1 parent 35a95df commit 8833af3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/runtime/pprof/pprof.go
Original file line number Diff line number Diff line change
Expand Up @@ -565,8 +565,12 @@ func writeHeap(w io.Writer, debug int) error {
fmt.Fprintf(w, "# OtherSys = %d\n", s.OtherSys)

fmt.Fprintf(w, "# NextGC = %d\n", s.NextGC)
fmt.Fprintf(w, "# LastGC = %d\n", s.LastGC)
fmt.Fprintf(w, "# PauseNs = %d\n", s.PauseNs)
fmt.Fprintf(w, "# PauseEnd = %d\n", s.PauseEnd)
fmt.Fprintf(w, "# NumGC = %d\n", s.NumGC)
fmt.Fprintf(w, "# NumForcedGC = %d\n", s.NumForcedGC)
fmt.Fprintf(w, "# GCCPUFraction = %v\n", s.GCCPUFraction)
fmt.Fprintf(w, "# DebugGC = %v\n", s.DebugGC)

tw.Flush()
Expand Down

0 comments on commit 8833af3

Please sign in to comment.