1
0
mirror of https://github.com/golang/go synced 2024-11-17 00:24:48 -07:00

runtime: fix some comments

This commit is contained in:
Jes Cok 2023-10-10 00:28:59 +08:00
parent 7fcc626b57
commit e2b4e5326a

View File

@ -690,7 +690,7 @@ func gcStart(trigger gcTrigger) {
finishsweep_m() finishsweep_m()
}) })
// clearpools before we start the GC. If we wait they memory will not be // clearpools before we start the GC. If we wait the memory will not be
// reclaimed until the next GC cycle. // reclaimed until the next GC cycle.
clearpools() clearpools()
@ -722,11 +722,11 @@ func gcStart(trigger gcTrigger) {
// enabled because they must be enabled before // enabled because they must be enabled before
// any non-leaf heap objects are marked. Since // any non-leaf heap objects are marked. Since
// allocations are blocked until assists can // allocations are blocked until assists can
// happen, we want enable assists as early as // happen, we want to enable assists as early as
// possible. // possible.
setGCPhase(_GCmark) setGCPhase(_GCmark)
gcBgMarkPrepare() // Must happen before assist enable. gcBgMarkPrepare() // Must happen before assists are enabled.
gcMarkRootPrepare() gcMarkRootPrepare()
// Mark all active tinyalloc blocks. Since we're // Mark all active tinyalloc blocks. Since we're