mirror of
https://github.com/golang/go
synced 2024-11-14 08:40:27 -07:00
runtime: rename gcController.findRunnable to findRunnableGCWorker
This avoids confusion with the main findrunnable in the scheduler. Change-Id: I8cf40657557a8610a2fe5a2f74598518256ca7f0 Reviewed-on: https://go-review.googlesource.com/9305 Reviewed-by: Rick Hudson <rlh@golang.org>
This commit is contained in:
parent
bb6320535d
commit
1b01910c06
@ -464,9 +464,9 @@ func (c *gcControllerState) endCycle() {
|
|||||||
c.workRatioAvg = workRatioWeight*workRatio + (1-workRatioWeight)*c.workRatioAvg
|
c.workRatioAvg = workRatioWeight*workRatio + (1-workRatioWeight)*c.workRatioAvg
|
||||||
}
|
}
|
||||||
|
|
||||||
// findRunnable returns the background mark worker for _p_ if it
|
// findRunnableGCWorker returns the background mark worker for _p_ if it
|
||||||
// should be run. This must only be called when gcBlackenEnabled != 0.
|
// should be run. This must only be called when gcBlackenEnabled != 0.
|
||||||
func (c *gcControllerState) findRunnable(_p_ *p) *g {
|
func (c *gcControllerState) findRunnableGCWorker(_p_ *p) *g {
|
||||||
if gcBlackenEnabled == 0 {
|
if gcBlackenEnabled == 0 {
|
||||||
throw("gcControllerState.findRunnable: blackening not enabled")
|
throw("gcControllerState.findRunnable: blackening not enabled")
|
||||||
}
|
}
|
||||||
|
@ -1598,7 +1598,7 @@ top:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if gp == nil && gcBlackenEnabled != 0 {
|
if gp == nil && gcBlackenEnabled != 0 {
|
||||||
gp = gcController.findRunnable(_g_.m.p.ptr())
|
gp = gcController.findRunnableGCWorker(_g_.m.p.ptr())
|
||||||
if gp != nil {
|
if gp != nil {
|
||||||
resetspinning()
|
resetspinning()
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user