1
0
mirror of https://github.com/golang/go synced 2024-11-19 02:14:43 -07:00

runtime: remove unnecessary gcworkdone resetting loop

The loop in gcMark is redundant with the gcworkdone resetting
performed by markroot, which called a few lines later in gcMark.

Change-Id: Ie0a826a614ecfa79e6e6b866e8d1de40ba515856
Reviewed-on: https://go-review.googlesource.com/5880
Reviewed-by: Russ Cox <rsc@golang.org>
Reviewed-by: Rick Hudson <rlh@golang.org>
This commit is contained in:
Austin Clements 2015-02-24 22:05:26 -05:00
parent 7abdc90fe3
commit 37b8597178

View File

@ -455,12 +455,6 @@ func gcMark(start_time int64) {
work.ndone = 0
work.nproc = uint32(gcprocs())
// World is stopped so allglen will not change.
for i := uintptr(0); i < allglen; i++ {
gp := allgs[i]
gp.gcworkdone = false // set to true in gcphasework
}
if trace.enabled {
traceGCScanStart()
}