Skip to content

Commit

Permalink
runtime: permit core dumps in darwin-amd64
Browse files Browse the repository at this point in the history
Previously we did not permit them as Go programs generated enormous
core dumps on macOS. However, according to an investigation in golang#59446,
they are OK now.

For golang#59446

Change-Id: I1d7a3f500a6bc525aa6de8dfa8a1d8dbb15feadc
Reviewed-on: https://go-review.googlesource.com/c/go/+/483015
TryBot-Result: Gopher Robot <[email protected]>
Run-TryBot: Ian Lance Taylor <[email protected]>
Reviewed-by: Michael Knyszek <[email protected]>
Reviewed-by: Michael Pratt <[email protected]>
  • Loading branch information
ianlancetaylor authored and mknyszek committed Apr 7, 2023
1 parent a3df6c0 commit d7d235c
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions src/runtime/signal_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -973,16 +973,6 @@ func raisebadsignal(sig uint32, c *sigctxt) {

//go:nosplit
func crash() {
// OS X core dumps are linear dumps of the mapped memory,
// from the first virtual byte to the last, with zeros in the gaps.
// Because of the way we arrange the address space on 64-bit systems,
// this means the OS X core file will be >128 GB and even on a zippy
// workstation can take OS X well over an hour to write (uninterruptible).
// Save users from making that mistake.
if GOOS == "darwin" && GOARCH == "amd64" {
return
}

dieFromSignal(_SIGABRT)
}

Expand Down

0 comments on commit d7d235c

Please sign in to comment.