Go version
Go toolchain at go1.23-20240626-RC01
Output of go env
in your module/workspace:
GO111MODULE=''
GOARCH='arm64'
GOBIN=''
GOCACHE='/Users/asinclair/Library/Caches/go-build'
GOENV='/Users/asinclair/Library/Application Support/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFLAGS=''
GOHOSTARCH='arm64'
GOHOSTOS='darwin'
GOINSECURE=''
GOMODCACHE='/Users/asinclair/go/pkg/mod'
GONOPROXY=''
GONOSUMDB=''
GOOS='darwin'
GOPATH='/Users/asinclair/go'
GOPRIVATE=''
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/Users/asinclair/sdk/gotip'
GOSUMDB='sum.golang.org'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/Users/asinclair/sdk/gotip/pkg/tool/darwin_arm64'
GOVCS=''
GOVERSION='devel go1.23-fc51e50 Wed Jul 17 15:08:04 2024 +0000'
GODEBUG=''
GOTELEMETRY='local'
GOTELEMETRYDIR='/Users/asinclair/Library/Application Support/go/telemetry'
GCCGO='gccgo'
GOARM64='v8.0'
AR='ar'
CC='clang'
CXX='clang++'
CGO_ENABLED='1'
GOMOD='/dev/null'
GOWORK=''
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
PKG_CONFIG='pkg-config'
GOGCCFLAGS='-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -ffile-prefix-map=/var/folders/sq/lttg4ysx3llf5s_t8_msn0gc009j2t/T/go-build1015358713=/tmp/go-build -gno-record-gcc-switches -fno-common'
What did you do?
Just run this: https://go.dev/play/p/xzGhahkjjJH?v=gotip
As far as I can tell it is due to this commit: https://github.com/golang/go/commit/beaf7f3282c2548267d3c894417cc4ecacc5d575
What did you see happen?
All userspace programs on my Mac seem to crash. E.g. Chrome, etc. My Wifi drops out before recovering. The desktop background goes grey.
What did you expect to see?
No crashing.
Comment From: ajsinclair
I don't suspect it's an OS bug but maybe we should continue guarding against such a bad outcome.
Comment From: gabyhelp
Related Issues and Documentation
- Heap corruption crash on darwin/arm64 #49865 (closed)
- affected/package: log #56622 (closed)
- Bugs-Report #62338 (closed)
- net: program cross-compiled for darwin/arm64 from linux/amd64 is SIGKILLed since CL 446178 #56599 (closed)
- go build #52634 (closed)
- sb #53220 (closed)
- runtime: race detector SIGABRT or SIGSEGV on macOS Monterey #49138 (closed)
- yaffaliu #56935 (closed)
- go #64466 (closed)
- clear #57553 (closed)
(Emoji vote if this was helpful or unhelpful; more detailed feedback welcome in this discussion.)
Comment From: seankhliao
cc @golang/runtime
Comment From: ianlancetaylor
This is happening because calling the kill
system call with a PID of -1 sends the signal to all processes for which you have permission to send a signal. Before the CL we had special cases for PID 0 and -1 that prevented this from happening. I think we should restore those special rules.
Comment From: gopherbot
Change https://go.dev/cl/599015 mentions this issue: os: don't try to signal PID 0 or -1 on Unix