aboutsummaryrefslogtreecommitdiff
path: root/api
diff options
context:
space:
mode:
authorCherry Mui <cherryyz@google.com>2023-11-29 19:17:22 -0500
committerCherry Mui <cherryyz@google.com>2024-01-31 14:20:56 +0000
commit13766fe7d89c44bb45cfb33591b137553bda7c7d (patch)
tree153d09ea95d0a6e5ab9df01000d0a05ac00f4b4a /api
parentb32ec6c961182e5bca6ae8420d6aa1204d7d2821 (diff)
downloadgo-13766fe7d89c44bb45cfb33591b137553bda7c7d.tar.gz
go-13766fe7d89c44bb45cfb33591b137553bda7c7d.zip
runtime: preempt more aggressively when panicking
When we are crashing from an unrecovered panic, we freeze the world, and print stack traces for all goroutines if GOTRACEBACK is set to a high enough level. Freezing the world is best effort, so there could still be goroutines that are not preempted, and so its stack trace is unavailable and printed as "goroutine running on other thread". As we're crashing and not resuming execution on preempted goroutines, we can make preemption more aggressive, preempting cases that are not safe for resumption or stack scanning. This may make goroutines more likely to be preempted in freezing the world and have their stacks available. Change-Id: Ie16269e2a05e007efa61368b695addc28d7a97ee Reviewed-on: https://go-review.googlesource.com/c/go/+/546135 LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Michael Pratt <mpratt@google.com> Reviewed-by: Mauri de Souza Meneguzzo <mauri870@gmail.com>
Diffstat (limited to 'api')
0 files changed, 0 insertions, 0 deletions