]> Cypherpunks repositories - gostls13.git/commit
internal/sync: move sync.Mutex implementation into new package
authorMichael Anthony Knyszek <mknyszek@google.com>
Fri, 21 Jun 2024 17:01:23 +0000 (17:01 +0000)
committerGopher Robot <gobot@golang.org>
Mon, 18 Nov 2024 19:57:35 +0000 (19:57 +0000)
commit6c660052856feae2bf1f3fe44665b5da0002500d
treee6a6352be92a049654911bff35fc9c9ce0ce462c
parentb5906ac4b7b455714565fa0a8f53aea966f3fb6f
internal/sync: move sync.Mutex implementation into new package

This CL refactors sync.Mutex such that its implementation lives in the
new internal/sync package. The purpose of this change is to eventually
reverse the dependency edge between internal/concurrent and sync, such
that sync can depend on internal/concurrent (or really, its contents,
which will likely end up in internal/sync).

The only change made to the sync.Mutex code is the frame skip count for
mutex profiling, so that the internal/sync frames are omitted in the
profile.

Change-Id: Ib3603d30e8e71508c4ea883a584ae2e51ce40c3f
Reviewed-on: https://go-review.googlesource.com/c/go/+/594056
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: David Chase <drchase@google.com>
Auto-Submit: Michael Knyszek <mknyszek@google.com>
src/cmd/internal/objabi/pkgspecial.go
src/go/build/deps_test.go
src/internal/sync/mutex.go [new file with mode: 0644]
src/internal/sync/runtime.go [new file with mode: 0644]
src/runtime/mprof.go
src/runtime/panic.go
src/runtime/proc.go
src/runtime/sema.go
src/sync/mutex.go
src/sync/runtime.go
src/sync/rwmutex.go