Skip to content

Commit

Permalink
runtime: remove redudant tryWakeP component
Browse files Browse the repository at this point in the history
Here tryWakeP can't already be true, so there is no need to combine the
values.

This CL should have no functional changes.

For #43997.
For #44313.

Change-Id: I640c7bb88a5f70c8d22f89f0b5b146b3f60c0136
Reviewed-on: https://go-review.googlesource.com/c/go/+/307911
Trust: Michael Pratt <mpratt@google.com>
Run-TryBot: Michael Pratt <mpratt@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
  • Loading branch information
prattmic committed Apr 16, 2021
1 parent f6e7fe2 commit 800fb11
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/runtime/proc.go
Expand Up @@ -3136,7 +3136,9 @@ top:
}
if gp == nil && gcBlackenEnabled != 0 {
gp = gcController.findRunnableGCWorker(_g_.m.p.ptr())
tryWakeP = tryWakeP || gp != nil
if gp != nil {
tryWakeP = true
}
}
if gp == nil {
// Check the global runnable queue once in a while to ensure fairness.
Expand Down

0 comments on commit 800fb11

Please sign in to comment.