1 // Copyright 2023 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file.
5 //go:build !plan9 && !windows
10 #include "_cgo_export.h"
13 #define CHECKCALLS 100
15 static void* checkBindMThread(void* thread) {
17 for (i = 0; i < CHECKCALLS; i++) {
18 GoCheckBindM((uintptr_t)thread);
26 pthread_t s[CTHREADS];
28 for (i = 0; i < CTHREADS; i++) {
29 pthread_create(&s[i], NULL, checkBindMThread, &s[i]);
31 for (i = 0; i < CTHREADS; i++) {
32 pthread_join(s[i], NULL);