aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/sys_freebsd_amd64.s
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2015-07-24 16:16:39 -0700
committerIan Lance Taylor <iant@golang.org>2015-07-27 16:58:53 +0000
commitf0876a1a940b67b3f6029dfd0b6a06348792dc04 (patch)
treeffb63478297c852a1e7c55e95b204cbaa7b6f0dc /src/runtime/sys_freebsd_amd64.s
parenta2cf0568e853a22a50110e43d5185a096f3145c6 (diff)
downloadgo-f0876a1a940b67b3f6029dfd0b6a06348792dc04.tar.gz
go-f0876a1a940b67b3f6029dfd0b6a06348792dc04.zip
runtime: log all thread stack traces during GODEBUG=crash on Unix
This extends https://golang.org/cl/2811, which only applied to Darwin and GNU/Linux, to all Unix systems. Fixes #9591. Change-Id: Iec3fb438564ba2924b15b447c0480f87c0bfd009 Reviewed-on: https://go-review.googlesource.com/12661 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Russ Cox <rsc@golang.org>
Diffstat (limited to 'src/runtime/sys_freebsd_amd64.s')
-rw-r--r--src/runtime/sys_freebsd_amd64.s11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/runtime/sys_freebsd_amd64.s b/src/runtime/sys_freebsd_amd64.s
index 8ef04588c3..b1c67c7dfc 100644
--- a/src/runtime/sys_freebsd_amd64.s
+++ b/src/runtime/sys_freebsd_amd64.s
@@ -123,6 +123,17 @@ TEXT runtime·raise(SB),NOSPLIT,$16
SYSCALL
RET
+TEXT runtime·raiseproc(SB),NOSPLIT,$0
+ // getpid
+ MOVL $20, AX
+ SYSCALL
+ // kill(self, sig)
+ MOVQ AX, DI // arg 1 pid
+ MOVL sig+0(FP), SI // arg 2 sig
+ MOVL $37, AX
+ SYSCALL
+ RET
+
TEXT runtime·setitimer(SB), NOSPLIT, $-8
MOVL mode+0(FP), DI
MOVQ new+8(FP), SI