diff options
| author | Michael Anthony Knyszek <mknyszek@google.com> | 2025-07-24 21:38:37 +0000 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2025-08-15 12:59:55 -0700 |
| commit | 78a3968c2c9f2d6e8eb6dc263b4a2517c72d71be (patch) | |
| tree | 72779d9bbc9c6290920a0ce2455170dac27bcf9f /src/runtime/runtime2.go | |
| parent | ab8121a407280bf39bdd401699476feb39ccd0f7 (diff) | |
| download | go-78a3968c2c9f2d6e8eb6dc263b4a2517c72d71be.tar.xz | |
runtime/metrics: add metric for current Go-owned thread count
Fixes #15490.
Change-Id: I6ce9edc46398030ff639e22d4ca4adebccdfe1b7
Reviewed-on: https://go-review.googlesource.com/c/go/+/690399
Auto-Submit: Michael Knyszek <mknyszek@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Michael Pratt <mpratt@google.com>
Diffstat (limited to 'src/runtime/runtime2.go')
| -rw-r--r-- | src/runtime/runtime2.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/runtime/runtime2.go b/src/runtime/runtime2.go index a80a34a18e..042c3137cd 100644 --- a/src/runtime/runtime2.go +++ b/src/runtime/runtime2.go @@ -1225,7 +1225,9 @@ var isIdleInSynctest = [len(waitReasonStrings)]bool{ } var ( - allm *m + // Linked-list of all Ms. Written under sched.lock, read atomically. + allm *m + gomaxprocs int32 numCPUStartup int32 forcegc forcegcstate |
