From: Keith Randall Date: Thu, 26 Jan 2023 22:37:53 +0000 (-0800) Subject: runtime: remove go118UseTimerCreateProfiler X-Git-Tag: go1.21rc1~1751 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=915af1b7ce23c5f0b83ed5afbbd952a4edf56daa;p=gostls13.git runtime: remove go118UseTimerCreateProfiler Change-Id: I37b15690fef6ca5354def834b1f6094e133a9fe4 Reviewed-on: https://go-review.googlesource.com/c/go/+/463736 Run-TryBot: Keith Randall Reviewed-by: Rhys Hiltner Auto-Submit: Keith Randall TryBot-Result: Gopher Robot Reviewed-by: Keith Randall Reviewed-by: Dmitri Shuralyov --- diff --git a/src/runtime/os_linux.go b/src/runtime/os_linux.go index 3ad1e3b8fc..37cd8e6482 100644 --- a/src/runtime/os_linux.go +++ b/src/runtime/os_linux.go @@ -558,9 +558,6 @@ func signalM(mp *m, sig int) { tgkill(getpid(), int(mp.procid), sig) } -// go118UseTimerCreateProfiler enables the per-thread CPU profiler. -const go118UseTimerCreateProfiler = true - // validSIGPROF compares this signal delivery's code against the signal sources // that the profiler uses, returning whether the delivery should be processed. // To be processed, a signal delivery from a known profiling mechanism should @@ -619,10 +616,6 @@ func setThreadCPUProfiler(hz int32) { mp := getg().m mp.profilehz = hz - if !go118UseTimerCreateProfiler { - return - } - // destroy any active timer if mp.profileTimerValid.Load() { timerid := mp.profileTimer