Skip to content

Commit 28b09d5

Browse files
seankhliaodr2chase
authored andcommitted
net/http/pprof: include Symbol in Index
Fixes #69897 Change-Id: I5887f34504b39018e16f269e087b43bc6a80964b Reviewed-on: https://go-review.googlesource.com/c/go/+/620455 LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Cherry Mui <cherryyz@google.com> Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
1 parent 6ea87f9 commit 28b09d5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/net/http/pprof/pprof.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,6 +367,7 @@ var profileDescriptions = map[string]string{
367367
"heap": "A sampling of memory allocations of live objects. You can specify the gc GET parameter to run GC before taking the heap sample.",
368368
"mutex": "Stack traces of holders of contended mutexes",
369369
"profile": "CPU profile. You can specify the duration in the seconds GET parameter. After you get the profile file, use the go tool pprof command to investigate the profile.",
370+
"symbol": "Maps given program counters to function names. Counters can be specifed in a GET raw query or POST body, multiple counters are separated by '+'.",
370371
"threadcreate": "Stack traces that led to the creation of new OS threads",
371372
"trace": "A trace of execution of the current program. You can specify the duration in the seconds GET parameter. After you get the trace file, use the go tool trace command to investigate the trace.",
372373
}
@@ -404,7 +405,7 @@ func Index(w http.ResponseWriter, r *http.Request) {
404405
}
405406

406407
// Adding other profiles exposed from within this package
407-
for _, p := range []string{"cmdline", "profile", "trace"} {
408+
for _, p := range []string{"cmdline", "profile", "symbol", "trace"} {
408409
profiles = append(profiles, profileEntry{
409410
Name: p,
410411
Href: p,

0 commit comments

Comments
 (0)