github.com/shogo82148/std@v1.22.1-0.20240327122250-4e474527810c/runtime/mcheckmark.go (about) 1 // Copyright 2020 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 // GC checkmarks 6 // 7 // In a concurrent garbage collector, one worries about failing to mark 8 // a live object due to mutations without write barriers or bugs in the 9 // collector implementation. As a sanity check, the GC has a 'checkmark' 10 // mode that retraverses the object graph with the world stopped, to make 11 // sure that everything that should be marked is marked. 12 13 package runtime