Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 21 for pthread_join (0.39 sec)

  1. src/cmd/cgo/internal/test/cthread_unix.c

    	int i;
    	pthread_t thread_id[MaxThread];
    	
    	if(nthread > MaxThread)
    		nthread = MaxThread;
    	for(i=0; i<nthread; i++)
    		pthread_create(&thread_id[i], 0, addThread, &max);
    	for(i=0; i<nthread; i++)
    		pthread_join(thread_id[i], 0);		
    }
    
    static void*
    goDummyCallbackThread(void* p)
    {
    	int i, max;
    
    	max = *(int*)p;
    	for(i=0; i<max; i++)
    		goDummy();
    	return NULL;
    }
    
    int
    callGoInCThread(int max)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 17 21:53:11 UTC 2023
    - 1K bytes
    - Viewed (0)
  2. src/cmd/cgo/internal/testcarchive/testdata/main4.c

    		exit(EXIT_FAILURE);
    	}
    
    	i = pthread_join(tid, NULL);
    	if (i != 0) {
    		fprintf(stderr, "pthread_join: %s\n", strerror(i));
    		exit(EXIT_FAILURE);
    	}
    
    	i = pthread_create(&tid, NULL, thread2, NULL);
    	if (i != 0) {
    		fprintf(stderr, "pthread_create: %s\n", strerror(i));
    		exit(EXIT_FAILURE);
    	}
    
    	i = pthread_join(tid, NULL);
    	if (i != 0) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 11:59:56 UTC 2023
    - 4.5K bytes
    - Viewed (0)
  3. src/runtime/testdata/testprogcgo/racesig.go

    		pthread_create(&m[i], NULL, mallocThread, NULL);
    	}
    	for (i = 0; i < SIGNALERS; i++) {
    		pthread_create(&s[i], NULL, signalThread, &m[0]);
    	}
    	for (i = 0; i < SIGNALERS; i++) {
    		pthread_join(s[i], NULL);
    	}
    	for (i = 0; i < ALLOCERS; i++) {
    		pthread_join(m[i], NULL);
    	}
    }
    */
    import "C"
    
    import (
    	"fmt"
    )
    
    func init() {
    	register("CgoRaceSignal", CgoRaceSignal)
    }
    
    func CgoRaceSignal() {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 01:46:05 UTC 2023
    - 1.7K bytes
    - Viewed (0)
  4. src/runtime/race/race_darwin_amd64.go

    //go:cgo_import_dynamic pthread_getspecific pthread_getspecific ""
    //go:cgo_import_dynamic pthread_introspection_hook_install pthread_introspection_hook_install ""
    //go:cgo_import_dynamic pthread_join pthread_join ""
    //go:cgo_import_dynamic pthread_self pthread_self ""
    //go:cgo_import_dynamic pthread_sigmask pthread_sigmask ""
    //go:cgo_import_dynamic pthread_threadid_np pthread_threadid_np ""
    //go:cgo_import_dynamic read read ""
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 16 19:29:22 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  5. src/runtime/race/race_darwin_arm64.go

    //go:cgo_import_dynamic pthread_getspecific pthread_getspecific ""
    //go:cgo_import_dynamic pthread_introspection_hook_install pthread_introspection_hook_install ""
    //go:cgo_import_dynamic pthread_join pthread_join ""
    //go:cgo_import_dynamic pthread_self pthread_self ""
    //go:cgo_import_dynamic pthread_sigmask pthread_sigmask ""
    //go:cgo_import_dynamic pthread_threadid_np pthread_threadid_np ""
    //go:cgo_import_dynamic read read ""
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 16 19:29:22 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  6. src/runtime/testdata/testprogcgo/bindm.c

    	return NULL;
    }
    
    void CheckBindM() {
    	int i;
    	pthread_t s[CTHREADS];
    
    	for (i = 0; i < CTHREADS; i++) {
    		pthread_create(&s[i], NULL, checkBindMThread, &s[i]);
    	}
    	for (i = 0; i < CTHREADS; i++) {
    		pthread_join(s[i], NULL);
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 17 21:53:11 UTC 2023
    - 692 bytes
    - Viewed (0)
  7. src/runtime/testdata/testprogcgo/trace_unix.c

    	goCalledFromCThread();
    	return NULL;
    }
    
    void cCalledFromGo(void) {
    	goCalledFromC();
    
    	pthread_t thread;
    	assert(pthread_create(&thread, NULL, cCalledFromCThread, NULL) == 0);
    	assert(pthread_join(thread, NULL) == 0);
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 30 19:18:12 UTC 2023
    - 688 bytes
    - Viewed (0)
  8. src/cmd/cgo/internal/test/issue6997_linux.c

    	while(1) {
    		sleep(1);
    	}
    }
    
    int StartThread() {
    	return pthread_create(&thread, NULL, &threadfunc, NULL);
    }
    
    int CancelThread() {
    	void *r;
    	pthread_cancel(thread);
    	pthread_join(thread, &r);
    	return (r == PTHREAD_CANCELED);
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 12:00:02 UTC 2023
    - 536 bytes
    - Viewed (0)
  9. src/runtime/testdata/testprogcgo/stackswitch.c

    }
    
    void callStackSwitchCallbackFromThread(void) {
    	pthread_t thread;
    	assert(pthread_create(&thread, NULL, stackSwitchThread, NULL) == 0);
    	assert(pthread_join(thread, NULL) == 0);
    
    	assert(pthread_create(&thread, NULL, stackSwitchThread2, NULL) == 0);
    	assert(pthread_join(thread, NULL) == 0);
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 26 15:17:33 UTC 2023
    - 3.9K bytes
    - Viewed (0)
  10. src/cmd/cgo/internal/testsanitizers/testdata/tsan15.go

    		if (r < 0)
    			break;
    	}
    	return 0;
    }
    
    static void foo() {
    	pthread_t *th = malloc(sizeof(pthread_t));
    	pthread_t th2;
    	pthread_create(th, 0, thr, 0);
    	pthread_create(&th2, 0, sendthr, th);
    	pthread_join(*th, 0);
    }
    */
    import "C"
    
    import (
    	"time"
    )
    
    //export go_callback
    func go_callback() {}
    
    func main() {
    	go func() {
    		for {
    			C.foo()
    		}
    	}()
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 06 21:14:49 UTC 2024
    - 968 bytes
    - Viewed (0)
Back to top