Skip to content

Commit bce7aec

Browse files
psilva261randall77
authored andcommitted
runtime/trace: disable frame pointer unwinding on plan9
Fixes #60254 Change-Id: Ifd9e517a9479e5cd63fd3622b2556989d5f84eb9 Reviewed-on: https://go-review.googlesource.com/c/go/+/499036 Reviewed-by: Austin Clements <[email protected]> Reviewed-by: Keith Randall <[email protected]> Reviewed-by: Keith Randall <[email protected]> Run-TryBot: Keith Randall <[email protected]> TryBot-Bypass: Keith Randall <[email protected]>
1 parent d9b87d7 commit bce7aec

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/runtime/trace.go

+3-1
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ package runtime
1515
import (
1616
"internal/abi"
1717
"internal/goarch"
18+
"internal/goos"
1819
"runtime/internal/atomic"
1920
"runtime/internal/sys"
2021
"unsafe"
@@ -993,8 +994,9 @@ func traceStackID(mp *m, pcBuf []uintptr, skip int) uint64 {
993994

994995
// tracefpunwindoff returns true if frame pointer unwinding for the tracer is
995996
// disabled via GODEBUG or not supported by the architecture.
997+
// TODO(#60254): support frame pointer unwinding on plan9/amd64.
996998
func tracefpunwindoff() bool {
997-
return debug.tracefpunwindoff != 0 || (goarch.ArchFamily != goarch.AMD64 && goarch.ArchFamily != goarch.ARM64)
999+
return debug.tracefpunwindoff != 0 || (goarch.ArchFamily != goarch.AMD64 && goarch.ArchFamily != goarch.ARM64) || goos.IsPlan9 == 1
9981000
}
9991001

10001002
// fpTracebackPCs populates pcBuf with the return addresses for each frame and

0 commit comments

Comments
 (0)