]> Cypherpunks repositories - gostls13.git/commit
runtime: move pcvalue cache to M
authorAustin Clements <austin@google.com>
Tue, 1 Aug 2023 17:54:32 +0000 (13:54 -0400)
committerGopher Robot <gobot@golang.org>
Mon, 21 Aug 2023 21:05:54 +0000 (21:05 +0000)
commit4a8373c553e8a3b15177f74ac12240bbe320a7ca
tree0c4b51e34cd7cf8be11d17732327e3ccb07ec49a
parent0b47b94a6275b0d0830e5ce7a03aaa99430f7f76
runtime: move pcvalue cache to M

Currently, the pcvalue cache is stack allocated for each operation
that needs to look up a lot of pcvalues. It's not always clear where
to put it, a lot of the time we just pass a nil cache, it doesn't get
reused across operations, and we put a surprising amount of effort
into threading these caches around.

This CL moves it to the M, where it can be long-lived and used by all
pcvalue lookups, and we don't have to carefully thread it across
operations.

This is a re-roll of CL 515276 with a fix for reentrant use of the
pcvalue cache from the signal handler.

Change-Id: Id94c0c0fb3004d1fda1b196790eebd949c621f28
Reviewed-on: https://go-review.googlesource.com/c/go/+/520063
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Austin Clements <austin@google.com>
Auto-Submit: Austin Clements <austin@google.com>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
src/runtime/runtime2.go
src/runtime/symtab.go