]> Cypherpunks.ru repositories - gostls13.git/commit
runtime: enable framepointer on all arm64
authorRuss Cox <rsc@golang.org>
Wed, 27 Jan 2021 16:34:42 +0000 (11:34 -0500)
committerRuss Cox <rsc@golang.org>
Fri, 19 Feb 2021 00:04:22 +0000 (00:04 +0000)
commit09e059afb1270498f416f5b5c75a6a5683b6d1da
treecec3165dd2d1b93fb9a3a95188faca0433aca990
parentb19e7b518e564cd309d3eb68dfd2da8839a7433b
runtime: enable framepointer on all arm64

Frame pointers were already enabled on linux, darwin, ios,
but not freebsd, android, openbsd, netbsd.

But the space was reserved on all platforms, leading to
two different arm64 framepointer conditions in different
parts of the code, one of which had no name
(framepointer_enabled || GOARCH == "arm64",
which might have been "framepointer_space_reserved").

So on the disabled systems, the stack layouts were still
set up for frame pointers and the only difference was not
actually maintaining the FP register in the generated code.

Reduce complexity by just enabling the frame pointer
completely on all the arm64 systems.

This commit passes on freebsd, android, netbsd.
I have not been able to try it on openbsd.

This CL is part of a stack adding windows/arm64
support (#36439), intended to land in the Go 1.17 cycle.
This CL is, however, not windows/arm64-specific.
It is cleanup meant to make the port (and future ports) easier.

Change-Id: I83bd23369d24b76db4c6a648fa74f6917819a093
Reviewed-on: https://go-review.googlesource.com/c/go/+/288814
Trust: Russ Cox <rsc@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
src/cmd/compile/internal/dwarfgen/dwarf.go
src/cmd/compile/internal/ssagen/pgen.go
src/cmd/internal/obj/arm64/a.out.go
src/cmd/internal/obj/arm64/obj7.go
src/cmd/internal/objabi/util.go
src/runtime/runtime2.go
src/runtime/traceback.go