aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/defs_openbsd_386.go
diff options
context:
space:
mode:
authorJoel Sing <joel@sing.id.au>2020-08-26 03:23:42 +1000
committerJoel Sing <joel@sing.id.au>2021-04-30 18:34:10 +0000
commit4893eee9dc307a234bff1aa441acf849111e1beb (patch)
tree29331e4d823f6fe5abc981671aafd591cd9044a1 /src/runtime/defs_openbsd_386.go
parentd9bfda81249f25959090b1493ac8e261dd4542f4 (diff)
downloadgo-4893eee9dc307a234bff1aa441acf849111e1beb.tar.gz
go-4893eee9dc307a234bff1aa441acf849111e1beb.zip
runtime: switch openbsd/386 to pthreads
This switches openbsd/386 to thread creation via pthreads, rather than doing direct system calls. Update #36435 Change-Id: I000a815fc0edd0272c3285954f3f007229bc60a0 Reviewed-on: https://go-review.googlesource.com/c/go/+/250577 Trust: Joel Sing <joel@sing.id.au> Reviewed-by: Cherry Zhang <cherryyz@google.com>
Diffstat (limited to 'src/runtime/defs_openbsd_386.go')
-rw-r--r--src/runtime/defs_openbsd_386.go9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/runtime/defs_openbsd_386.go b/src/runtime/defs_openbsd_386.go
index 35f2e53fcf..6a62261f5b 100644
--- a/src/runtime/defs_openbsd_386.go
+++ b/src/runtime/defs_openbsd_386.go
@@ -30,6 +30,8 @@ const (
_SA_RESTART = 0x2
_SA_ONSTACK = 0x1
+ _PTHREAD_CREATE_DETACHED = 0x1
+
_SIGHUP = 0x1
_SIGINT = 0x2
_SIGQUIT = 0x3
@@ -166,3 +168,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