runtime: shrink signal stacks with AT_MINSIGSTKSZ #54088
Labels
compiler/runtime
Issues related to the Go compiler and/or runtime.
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone
A new auxiliary vector,
AT_MINSIGSTKSZ
was added for arm64 in Linux 4.18, amd64 in Linux 5.14, and ppc64 in Linux 5.19.AT_MINSIGSTKSZ
reports the size of a signal frame, and thus the absolute minimum amount of space required to receive a signal, though additional space is of course required for userspace stack usage.Currently we hard-code our signal stacks to 32KB. With
AT_MINSIGSTKSZ
, I think we could adjust this to something likeAT_MINSIGSTKSZ + _StackFixed
, which would almost certainly reduce the signal stack size on all systems (AT_MINSIGSTKSZ
is 3632 bytes on my Skylake machine).cc @aclements @cherrymui
The text was updated successfully, but these errors were encountered: