mirror of
https://github.com/golang/go
synced 2024-11-15 05:20:21 -07:00
runtime: delete dead code in the tracer
This code was just missed during the cleanup. There's maybe some merit to keeping OneNewExtraM, but it would still be fairly optimistic. It's trivial to bring back, so delete it for now. Change-Id: I2d033c6daae787e0e8d6b92524f3e59610e2599f Reviewed-on: https://go-review.googlesource.com/c/go/+/583375 Reviewed-by: Carlos Amedee <carlos@golang.org> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
This commit is contained in:
parent
5a181c5042
commit
be29a02161
@ -2343,11 +2343,6 @@ func oneNewExtraM() {
|
|||||||
if raceenabled {
|
if raceenabled {
|
||||||
gp.racectx = racegostart(abi.FuncPCABIInternal(newextram) + sys.PCQuantum)
|
gp.racectx = racegostart(abi.FuncPCABIInternal(newextram) + sys.PCQuantum)
|
||||||
}
|
}
|
||||||
trace := traceAcquire()
|
|
||||||
if trace.ok() {
|
|
||||||
trace.OneNewExtraM(gp)
|
|
||||||
traceRelease(trace)
|
|
||||||
}
|
|
||||||
// put on allg for garbage collector
|
// put on allg for garbage collector
|
||||||
allgadd(gp)
|
allgadd(gp)
|
||||||
|
|
||||||
@ -5489,7 +5484,6 @@ func (pp *p) destroy() {
|
|||||||
freemcache(pp.mcache)
|
freemcache(pp.mcache)
|
||||||
pp.mcache = nil
|
pp.mcache = nil
|
||||||
gfpurge(pp)
|
gfpurge(pp)
|
||||||
traceProcFree(pp)
|
|
||||||
if raceenabled {
|
if raceenabled {
|
||||||
if pp.timers.raceCtx != 0 {
|
if pp.timers.raceCtx != 0 {
|
||||||
// The race detector code uses a callback to fetch
|
// The race detector code uses a callback to fetch
|
||||||
|
@ -560,11 +560,6 @@ func (tl traceLocker) HeapGoal() {
|
|||||||
tl.eventWriter(traceGoRunning, traceProcRunning).commit(traceEvHeapGoal, traceArg(heapGoal))
|
tl.eventWriter(traceGoRunning, traceProcRunning).commit(traceEvHeapGoal, traceArg(heapGoal))
|
||||||
}
|
}
|
||||||
|
|
||||||
// OneNewExtraM is a no-op in the new tracer. This is worth keeping around though because
|
|
||||||
// it's a good place to insert a thread-level event about the new extra M.
|
|
||||||
func (tl traceLocker) OneNewExtraM(_ *g) {
|
|
||||||
}
|
|
||||||
|
|
||||||
// GoCreateSyscall indicates that a goroutine has transitioned from dead to GoSyscall.
|
// GoCreateSyscall indicates that a goroutine has transitioned from dead to GoSyscall.
|
||||||
//
|
//
|
||||||
// Unlike GoCreate, the caller must be running on gp.
|
// Unlike GoCreate, the caller must be running on gp.
|
||||||
@ -657,14 +652,6 @@ func trace_userLog(id uint64, category, message string) {
|
|||||||
traceRelease(tl)
|
traceRelease(tl)
|
||||||
}
|
}
|
||||||
|
|
||||||
// traceProcFree is called when a P is destroyed.
|
|
||||||
//
|
|
||||||
// This must run on the system stack to match the old tracer.
|
|
||||||
//
|
|
||||||
//go:systemstack
|
|
||||||
func traceProcFree(_ *p) {
|
|
||||||
}
|
|
||||||
|
|
||||||
// traceThreadDestroy is called when a thread is removed from
|
// traceThreadDestroy is called when a thread is removed from
|
||||||
// sched.freem.
|
// sched.freem.
|
||||||
//
|
//
|
||||||
@ -703,10 +690,3 @@ func traceThreadDestroy(mp *m) {
|
|||||||
throw("bad use of trace.seqlock")
|
throw("bad use of trace.seqlock")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Not used in the new tracer; solely for compatibility with the old tracer.
|
|
||||||
// nosplit because it's called from exitsyscall without a P.
|
|
||||||
//
|
|
||||||
//go:nosplit
|
|
||||||
func (_ traceLocker) RecordSyscallExitedTime(_ *g, _ *p) {
|
|
||||||
}
|
|
||||||
|
Loading…
Reference in New Issue
Block a user