]> Cypherpunks.ru repositories - gostls13.git/commit
runtime: handle nil gp in cpuprof
authorRuss Cox <rsc@golang.org>
Wed, 27 Jan 2021 16:00:21 +0000 (11:00 -0500)
committerRuss Cox <rsc@golang.org>
Fri, 19 Feb 2021 00:01:52 +0000 (00:01 +0000)
commitc80da0a33a240469892a0b0713f09607efb28752
tree95560d4243b2e7940b24ee07660faad80e2bc790
parenta78879ac67d62c4919492fcb5e05c8b21058217d
runtime: handle nil gp in cpuprof

This can happen on Windows when recording profile samples for system threads.

This CL is part of a stack adding windows/arm64
support (#36439), intended to land in the Go 1.17 cycle.
This CL is, however, not windows/arm64-specific.
It is cleanup meant to make the port (and future ports) easier.

Change-Id: I5a7ba32b1900a69f3b7acada9cb6cf8396d8a03f
Reviewed-on: https://go-review.googlesource.com/c/go/+/288797
Trust: Russ Cox <rsc@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/runtime/cpuprof.go