diff options
author | Ian Lance Taylor <iant@golang.org> | 2021-06-10 12:37:34 -0700 |
---|---|---|
committer | Ian Lance Taylor <iant@golang.org> | 2021-06-10 14:41:23 -0700 |
commit | ee52bf609bac45b3c251858a69071262f46ee89c (patch) | |
tree | 4c079eab4884dc9c32e6f62fe9e2f0ff0d784306 /libgo/go/runtime/runtime2.go | |
parent | 00d07ec6e12451acc7a290cd93be03bed50cb666 (diff) | |
download | gcc-ee52bf609bac45b3c251858a69071262f46ee89c.zip gcc-ee52bf609bac45b3c251858a69071262f46ee89c.tar.gz gcc-ee52bf609bac45b3c251858a69071262f46ee89c.tar.bz2 |
libgo: update to Go1.16.5 release
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/326772
Diffstat (limited to 'libgo/go/runtime/runtime2.go')
-rw-r--r-- | libgo/go/runtime/runtime2.go | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/libgo/go/runtime/runtime2.go b/libgo/go/runtime/runtime2.go index 4b13cfc..1879b82 100644 --- a/libgo/go/runtime/runtime2.go +++ b/libgo/go/runtime/runtime2.go @@ -584,10 +584,13 @@ type m struct { syscalltick uint32 freelink *m // on sched.freem - // mFixup is used to synchronize OS related m state (credentials etc) - // use mutex to access. + // mFixup is used to synchronize OS related m state + // (credentials etc) use mutex to access. To avoid deadlocks + // an atomic.Load() of used being zero in mDoFixupFn() + // guarantees fn is nil. mFixup struct { lock mutex + used uint32 fn func(bool) bool } |