]> Cypherpunks repositories - gostls13.git/commit
runtime: preempt dedicated background mark workers for STW
authorMichael Anthony Knyszek <mknyszek@google.com>
Thu, 16 Jan 2020 21:39:42 +0000 (21:39 +0000)
committerMichael Knyszek <mknyszek@google.com>
Wed, 18 Mar 2020 17:59:09 +0000 (17:59 +0000)
commit79b43fa819bca31b5be2b9ed3014d8b7faf4c8cc
tree5c08b671de6735a4389314ecdd697958cc352aa0
parent6197104c14dc6e72a368f9b5d3d2a14381f5e456
runtime: preempt dedicated background mark workers for STW

Currently, dedicated background mark workers are essentially always
non-preemptible.

This change makes it so that dedicated background mark workers park if
their preemption flag is set and someone is trying to STW, allowing them
to do so.

This change prepares us for allowing a STW to happen (and happen
promptly) during GC marking in a follow-up change.

Updates #19812.

Change-Id: I67fb6085bf0f0aebd18ca500172767818a1f15e3
Reviewed-on: https://go-review.googlesource.com/c/go/+/215157
Run-TryBot: Michael Knyszek <mknyszek@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Reviewed-by: Austin Clements <austin@google.com>
src/runtime/mgcmark.go