]> Cypherpunks.ru repositories - gostls13.git/commit
runtime: add definitions for SetGoroutineLabels and Do
authorMichael Matloob <matloob@golang.org>
Fri, 9 Dec 2016 21:00:02 +0000 (16:00 -0500)
committerMichael Matloob <matloob@golang.org>
Mon, 6 Feb 2017 20:29:37 +0000 (20:29 +0000)
commit62956897c1743ee7e79895496180f84432f21d0a
treecaf20e695e4c685d2b39c59cabbbab57bca582c3
parentbc548d71b9634341c514dcef10ce8141f330d95c
runtime: add definitions for SetGoroutineLabels and Do

This change defines runtime/pprof.SetGoroutineLabels and runtime/pprof.Do, which
are used to set profiler labels on goroutines. The change defines functions
in the runtime for setting and getting profile labels, and sets and unsets
profile labels when goroutines are created and deleted. The change also adds
the package runtime/internal/proflabel, which defines the structure the runtime
uses to store profile labels.

Change-Id: I747a4400141f89b6e8160dab6aa94ca9f0d4c94d
Reviewed-on: https://go-review.googlesource.com/34198
Run-TryBot: Michael Matloob <matloob@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Russ Cox <rsc@golang.org>
Reviewed-on: https://go-review.googlesource.com/35010
src/cmd/dist/deps.go
src/runtime/pprof/label.go
src/runtime/pprof/runtime.go [new file with mode: 0644]
src/runtime/pprof/runtime_test.go [new file with mode: 0644]
src/runtime/proc.go
src/runtime/proflabel.go [new file with mode: 0644]
src/runtime/runtime2.go