]> Cypherpunks repositories - gostls13.git/commit
runtime: run concurrent mark phase on regular stack
authorAustin Clements <austin@google.com>
Wed, 18 Mar 2015 15:22:12 +0000 (11:22 -0400)
committerAustin Clements <austin@google.com>
Thu, 19 Mar 2015 15:55:12 +0000 (15:55 +0000)
commitfa2f9c2c0923edf539cdcce82473e7131826d677
tree3b13fa684db64e3c85d6a202b7eaeb8c6cfd4437
parentbef356b28281b8ff4a585d857a881783926cabb1
runtime: run concurrent mark phase on regular stack

Currently, the GC's concurrent mark phase runs on the system
stack. There's no need to do this, and running it this way ties up the
entire M and P running the GC by preventing the scheduler from
preempting the GC even during concurrent mark.

Fix this by running concurrent mark on the regular G stack. It's still
non-preemptible because we also set preemptoff around the whole GC
process, but this moves us closer to making it preemptible.

Change-Id: Ia9f1245e299b8c5c513a4b1e3ef13eaa35ac5e73
Reviewed-on: https://go-review.googlesource.com/7730
Reviewed-by: Rick Hudson <rlh@golang.org>
src/runtime/mgc.go