diff options
| author | Michael Anthony Knyszek <mknyszek@google.com> | 2023-05-10 03:14:22 +0000 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2023-05-17 14:43:25 +0000 |
| commit | c890d40d0db00a6a91fd48acee024f0478f10ce4 (patch) | |
| tree | 218bbecae5dc4768bc9cfabd3cf1836e00718644 /src/runtime/proc.go | |
| parent | 54031132c87931d7a5844a1ce05e637b03703c38 (diff) | |
| download | go-c890d40d0db00a6a91fd48acee024f0478f10ce4.tar.xz | |
runtime: factor our oneNewExtraM trace code
In the interest of further cleaning up the trace.go API, move the trace
logic in oneNewExtraM into its own function.
Change-Id: I5cf478cb8cd0d301ee3b068347ed48ce768b8882
Reviewed-on: https://go-review.googlesource.com/c/go/+/494186
Reviewed-by: Michael Pratt <mpratt@google.com>
Run-TryBot: Michael Knyszek <mknyszek@google.com>
Auto-Submit: Michael Knyszek <mknyszek@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Diffstat (limited to 'src/runtime/proc.go')
| -rw-r--r-- | src/runtime/proc.go | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/runtime/proc.go b/src/runtime/proc.go index 2c8750a5fe..b5e1c3e3b1 100644 --- a/src/runtime/proc.go +++ b/src/runtime/proc.go @@ -2004,12 +2004,7 @@ func oneNewExtraM() { gp.racectx = racegostart(abi.FuncPCABIInternal(newextram) + sys.PCQuantum) } if traceEnabled() { - // Trigger two trace events for the locked g in the extra m, - // since the next event of the g will be traceEvGoSysExit in exitsyscall, - // while calling from C thread to Go. - traceGoCreate(gp, 0) // no start pc - gp.traceseq++ - traceEvent(traceEvGoInSyscall, -1, gp.goid) + traceOneNewExtraM(gp) } // put on allg for garbage collector allgadd(gp) |
