]> Cypherpunks repositories - gostls13.git/commit
runtime: merge timerRemoving into timerModifying
authorRuss Cox <rsc@golang.org>
Wed, 14 Feb 2024 16:56:58 +0000 (11:56 -0500)
committerRuss Cox <rsc@golang.org>
Wed, 28 Feb 2024 16:43:54 +0000 (16:43 +0000)
commit09bfea95cff2ae1fe5afba4049bfaedac7f31d76
tree16e77b402b79338046d7210d4ef6bd75f0c2874c
parentb2bd7ebafcd8588fadef6b73755ee98bc8889233
runtime: merge timerRemoving into timerModifying

timerRemoving is just a kind of "locked for modification",
so merge it into timerModifying. This does potentially remove
a fast path from deltimer, in that deltimer of timerRemoving
is a fast-path exit while deltimer of timerModifying has to
wait for the timer to settle. Since all the timerModifying
critical paths are bounded and short, this should not matter.

This is part of a larger simplification of the state set.

[This is one CL in a refactoring stack making very small changes
in each step, so that any subtle bugs that we miss can be more
easily pinpointed to a small change.]

Change-Id: I039bf6a5a041a158dc3d1af8127f28eed50fc540
Reviewed-on: https://go-review.googlesource.com/c/go/+/564120
Reviewed-by: Ian Lance Taylor <iant@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
src/runtime/time.go