aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/debug/garbage.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime/debug/garbage.go')
-rw-r--r--src/runtime/debug/garbage.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/runtime/debug/garbage.go b/src/runtime/debug/garbage.go
index 4d3ca79a81..8144497177 100644
--- a/src/runtime/debug/garbage.go
+++ b/src/runtime/debug/garbage.go
@@ -155,6 +155,12 @@ func SetPanicOnFault(enabled bool) bool {
// WriteHeapDump writes a description of the heap and the objects in
// it to the given file descriptor.
+//
+// WriteHeapDump suspends the execution of all goroutines until the heap
+// dump is completely written. Thus, the file descriptor must not be
+// connected to a pipe or socket whose other end is in the same Go
+// process; instead, use a temporary file or network socket.
+//
// The heap dump format is defined at https://golang.org/s/go15heapdump.
func WriteHeapDump(fd uintptr)