]> Cypherpunks repositories - gostls13.git/commit
runtime: allocate crash stack via stackalloc
authorJoel Sing <joel@sing.id.au>
Mon, 30 Oct 2023 13:27:58 +0000 (00:27 +1100)
committerCherry Mui <cherryyz@google.com>
Tue, 31 Oct 2023 16:28:14 +0000 (16:28 +0000)
commite293c4b509de6e7ceaeabb0c8d9f2a4d3d3b4e6d
tree5e477f1ba37f71c405e69bc5578dafb2bf879e02
parentb7a66be69c5857105c4b357d87bb76da87b1dbed
runtime: allocate crash stack via stackalloc

On some platforms (notably OpenBSD), stacks must be specifically allocated
and marked as being stack memory. Allocate the crash stack using stackalloc,
which ensures these requirements are met, rather than using a global Go
variable.

Fixes #63794

Change-Id: I6513575797dd69ff0a36f3bfd4e5fc3bd95cbf50
Reviewed-on: https://go-review.googlesource.com/c/go/+/538457
Run-TryBot: Joel Sing <joel@sing.id.au>
Reviewed-by: Bryan Mills <bcmills@google.com>
Reviewed-by: Mauri de Souza Meneguzzo <mauri870@gmail.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
src/runtime/proc.go