aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/sys_linux_ppc64x.s
diff options
context:
space:
mode:
authorShenghou Ma <minux@golang.org>2015-04-22 18:03:18 -0400
committerMinux Ma <minux@golang.org>2015-04-22 23:21:25 +0000
commitedc53e1f144fe5d1be8c787992ea6e9d9067ebf6 (patch)
tree273fa8dd4097a8a3f4dd3ac7d2b3076d91880ca2 /src/runtime/sys_linux_ppc64x.s
parent43618e62ca387faf2272308a46fed9378fa36a87 (diff)
downloadgo-edc53e1f144fe5d1be8c787992ea6e9d9067ebf6.tar.gz
go-edc53e1f144fe5d1be8c787992ea6e9d9067ebf6.zip
runtime: fix build after CL 9164 on Linux
There is an assumption that the function executed in child thread created by runtime.close should not return. And different systems enforce that differently: some exit that thread, some exit the whole process. The test TestNewOSProc0 introduced in CL 9161 breaks that assumption, so we need to adjust the code to only exit the thread should the called function return. Change-Id: Id631cb2f02ec6fbd765508377a79f3f96c6a2ed6 Reviewed-on: https://go-review.googlesource.com/9246 Reviewed-by: Dave Cheney <dave@cheney.net>
Diffstat (limited to 'src/runtime/sys_linux_ppc64x.s')
-rw-r--r--src/runtime/sys_linux_ppc64x.s4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/runtime/sys_linux_ppc64x.s b/src/runtime/sys_linux_ppc64x.s
index ff397f003b..44a22c9c77 100644
--- a/src/runtime/sys_linux_ppc64x.s
+++ b/src/runtime/sys_linux_ppc64x.s
@@ -346,9 +346,9 @@ nog:
MOVD R12, CTR
BL (CTR)
- // It shouldn't return. If it does, exit
+ // It shouldn't return. If it does, exit that thread.
MOVW $111, R3
- SYSCALL $SYS_exit_group
+ SYSCALL $SYS_exit
BR -2(PC) // keep exiting
TEXT runtime·sigaltstack(SB),NOSPLIT,$-8