]> Cypherpunks repositories - gostls13.git/commitdiff
runtime: fix comments referring to trace functions in runtime/pprof
authorAustin Clements <austin@google.com>
Wed, 22 Jul 2015 15:54:41 +0000 (11:54 -0400)
committerAustin Clements <austin@google.com>
Wed, 22 Jul 2015 18:33:38 +0000 (18:33 +0000)
ae1ea2a moved trace-related functions from runtime/pprof to
runtime/trace, but missed a doc comment and a code comment. Update
these to reflect the move.

Change-Id: I6e1e8861e5ede465c08a2e3f80b976145a8b32d8
Reviewed-on: https://go-review.googlesource.com/12525
Reviewed-by: Dmitry Vyukov <dvyukov@google.com>
src/runtime/trace.go

index 25fcfe13c2b222bba1682c0fe8b6589836cc503f..8cd95893a0ac83ce93a241f69e79ad9a698b7e39 100644 (file)
@@ -127,7 +127,7 @@ type traceBuf struct {
 // StartTrace enables tracing for the current process.
 // While tracing, the data will be buffered and available via ReadTrace.
 // StartTrace returns an error if tracing is already enabled.
-// Most clients should use the runtime/pprof package or the testing package's
+// Most clients should use the runtime/trace package or the testing package's
 // -test.trace flag instead of calling StartTrace directly.
 func StartTrace() error {
        // Stop the world, so that we can take a consistent snapshot
@@ -347,7 +347,7 @@ func ReadTrace() []byte {
                if raceenabled {
                        // Model synchronization on trace.shutdownSema, which race
                        // detector does not see. This is required to avoid false
-                       // race reports on writer passed to pprof.StartTrace.
+                       // race reports on writer passed to trace.Start.
                        racerelease(unsafe.Pointer(&trace.shutdownSema))
                }
                // trace.enabled is already reset, so can call traceable functions.