aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/trace.go
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2015-04-10 18:32:40 +0300
committerDmitry Vyukov <dvyukov@google.com>2015-04-10 17:39:06 +0000
commit089d363a9187fcefb2e6e9335a7ec2b74eeec003 (patch)
treeeb19bb0b4e8201799d75101adc8a0a903ad38655 /src/runtime/trace.go
parent53a8ee5011c2cca9f938af2ff2973ed8897aa597 (diff)
downloadgo-089d363a9187fcefb2e6e9335a7ec2b74eeec003.tar.xz
runtime: fix tracing of syscall exit
Fix tracing of syscall exit after: https://go-review.googlesource.com/#/c/7504/ Change-Id: Idcde2aa826d2b9a05d0a90a80242b6bfa78846ab Reviewed-on: https://go-review.googlesource.com/8728 Reviewed-by: Rick Hudson <rlh@golang.org> Run-TryBot: Dmitry Vyukov <dvyukov@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src/runtime/trace.go')
-rw-r--r--src/runtime/trace.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/runtime/trace.go b/src/runtime/trace.go
index 5146850770..a149799527 100644
--- a/src/runtime/trace.go
+++ b/src/runtime/trace.go
@@ -45,7 +45,7 @@ const (
traceEvGoBlockCond = 26 // goroutine blocks on Cond [timestamp, stack]
traceEvGoBlockNet = 27 // goroutine blocks on network [timestamp, stack]
traceEvGoSysCall = 28 // syscall enter [timestamp, stack]
- traceEvGoSysExit = 29 // syscall exit [timestamp, goroutine id]
+ traceEvGoSysExit = 29 // syscall exit [timestamp, goroutine id, real timestamp]
traceEvGoSysBlock = 30 // syscall blocks [timestamp]
traceEvGoWaiting = 31 // denotes that goroutine is blocked when tracing starts [goroutine id]
traceEvGoInSyscall = 32 // denotes that goroutine is in syscall when tracing starts [goroutine id]
@@ -797,8 +797,8 @@ func traceGoSysCall() {
traceEvent(traceEvGoSysCall, 4)
}
-func traceGoSysExit() {
- traceEvent(traceEvGoSysExit, -1, uint64(getg().m.curg.goid))
+func traceGoSysExit(ts int64) {
+ traceEvent(traceEvGoSysExit, -1, uint64(getg().m.curg.goid), uint64(ts)/traceTickDiv)
}
func traceGoSysBlock(pp *p) {