diff options
| author | Austin Clements <austin@google.com> | 2023-04-19 13:21:02 -0400 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2023-04-21 19:28:53 +0000 |
| commit | 03ad1f1a340841e7c60ee635ff894fe19cd99506 (patch) | |
| tree | 9b137fb603fe70d99eba31aba2d5747bc71e6fa6 /src/runtime/stack.go | |
| parent | 7843ca83e7c8229f4fdca22949428a2418f45138 (diff) | |
| download | go-03ad1f1a340841e7c60ee635ff894fe19cd99506.tar.xz | |
internal/abi, runtime, cmd: merge StackSmall, StackBig consts into internal/abi
For #59670.
Change-Id: I91448363be2fc678964ce119d85cd5fae34a14da
Reviewed-on: https://go-review.googlesource.com/c/go/+/486975
Reviewed-by: Cherry Mui <cherryyz@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Austin Clements <austin@google.com>
Auto-Submit: Austin Clements <austin@google.com>
Diffstat (limited to 'src/runtime/stack.go')
| -rw-r--r-- | src/runtime/stack.go | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/src/runtime/stack.go b/src/runtime/stack.go index a1095382d3..6d75301556 100644 --- a/src/runtime/stack.go +++ b/src/runtime/stack.go @@ -85,13 +85,6 @@ const ( _FixedStack6 = _FixedStack5 | (_FixedStack5 >> 16) _FixedStack = _FixedStack6 + 1 - // Functions that need frames bigger than this use an extra - // instruction to do the stack split check, to avoid overflow - // in case SP - framesize wraps below zero. - // This value can be no bigger than the size of the unmapped - // space at zero. - _StackBig = 4096 - // The stack guard is a pointer this many bytes above the // bottom of the stack. // @@ -101,15 +94,10 @@ const ( // This arithmetic must match that in cmd/internal/objabi/stack.go:StackLimit. _StackGuard = 928*sys.StackGuardMultiplier + _StackSystem - // After a stack split check the SP is allowed to be this - // many bytes below the stack guard. This saves an instruction - // in the checking sequence for tiny frames. - _StackSmall = 128 - // The maximum number of bytes that a chain of NOSPLIT // functions can use. // This arithmetic must match that in cmd/internal/objabi/stack.go:StackLimit. - _StackLimit = _StackGuard - _StackSystem - _StackSmall + _StackLimit = _StackGuard - _StackSystem - abi.StackSmall ) const ( |
