aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/defs_openbsd_amd64.go
diff options
context:
space:
mode:
authorJoel Sing <joel@sing.id.au>2020-08-24 03:13:54 +1000
committerJoel Sing <joel@sing.id.au>2021-01-19 12:49:13 +0000
commitd047c91a6c0f22af00d1c1e770a9d85201392656 (patch)
treedcd9610ea13b12d5490960e2023a8b237de9d27a /src/runtime/defs_openbsd_amd64.go
parent61debffd977889cd3f7f63b4f71d5a8ef1fc604e (diff)
downloadgo-d047c91a6c0f22af00d1c1e770a9d85201392656.tar.gz
go-d047c91a6c0f22af00d1c1e770a9d85201392656.zip
cmd/link,runtime: switch openbsd/amd64 to pthreads
This switches openbsd/amd64 to thread creation via pthreads, rather than doing direct system calls. Update #36435 Change-Id: I1105d5c392aa3e4c445d99c8cb80b927712e3529 Reviewed-on: https://go-review.googlesource.com/c/go/+/250180 Trust: Joel Sing <joel@sing.id.au> Run-TryBot: Joel Sing <joel@sing.id.au> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com>
Diffstat (limited to 'src/runtime/defs_openbsd_amd64.go')
-rw-r--r--src/runtime/defs_openbsd_amd64.go9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/runtime/defs_openbsd_amd64.go b/src/runtime/defs_openbsd_amd64.go
index c187a98ae0..01ca934cea 100644
--- a/src/runtime/defs_openbsd_amd64.go
+++ b/src/runtime/defs_openbsd_amd64.go
@@ -30,6 +30,8 @@ const (
_SA_RESTART = 0x2
_SA_ONSTACK = 0x1
+ _PTHREAD_CREATE_DETACHED = 0x1
+
_SIGHUP = 0x1
_SIGINT = 0x2
_SIGQUIT = 0x3
@@ -177,3 +179,10 @@ type keventt struct {
data int64
udata *byte
}
+
+type pthread uintptr
+type pthreadattr uintptr
+type pthreadcond uintptr
+type pthreadcondattr uintptr
+type pthreadmutex uintptr
+type pthreadmutexattr uintptr