From 7d80a2ea18f48d309115bbe950422c54e31a14e8 Mon Sep 17 00:00:00 2001 From: Elias Naur Date: Wed, 19 Jul 2017 00:09:35 +0200 Subject: [PATCH] runtime: allow crash() to raise SIGABRT on darwin/arm64 To avoid gigantic core dumps, the runtime avoids raising SIGABRT on crashes on 64-bit Darwin systems. Mobile OS'es (probably) don't generate huge core dumps, so to aid crash reporters, allow SIGABRT on crashes on darwin/arm64. Change-Id: I4a29608f400967d76f9bd0643fea22244c2da9df Reviewed-on: https://go-review.googlesource.com/49770 Run-TryBot: Elias Naur Reviewed-by: Avelino Reviewed-by: Ian Lance Taylor --- src/runtime/signal_unix.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/runtime/signal_unix.go b/src/runtime/signal_unix.go index 539b165ba1..d9a18caa6f 100644 --- a/src/runtime/signal_unix.go +++ b/src/runtime/signal_unix.go @@ -8,7 +8,6 @@ package runtime import ( "runtime/internal/atomic" - "runtime/internal/sys" "unsafe" ) @@ -474,7 +473,7 @@ func crash() { // 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 sys.PtrSize == 8 { + if GOARCH == "amd64" { return } }