Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for pthread_attr_init1 (1.2 sec)

  1. src/runtime/cgo/gcc_stack_unix.c

    void
    x_cgo_getstackbound(uintptr bounds[2])
    {
    	pthread_attr_t attr;
    	void *addr;
    	size_t size;
    
    	// Needed before pthread_getattr_np, too, since before glibc 2.32
    	// it did not call pthread_attr_init in all cases (see #65625).
    	pthread_attr_init(&attr);
    #if defined(__GLIBC__) || (defined(__sun) && !defined(__illumos__))
    	// pthread_getattr_np is a GNU extension supported in glibc.
    	// Solaris is not glibc but does support pthread_getattr_np
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 24 03:44:11 UTC 2024
    - 1.5K bytes
    - Viewed (0)
  2. src/runtime/os_aix.go

    var tstart funcDescriptor
    
    func newosproc(mp *m) {
    	var (
    		attr pthread_attr
    		oset sigset
    		tid  pthread
    	)
    
    	if pthread_attr_init(&attr) != 0 {
    		throw("pthread_attr_init")
    	}
    
    	if pthread_attr_setstacksize(&attr, threadStackSize) != 0 {
    		throw("pthread_attr_getstacksize")
    	}
    
    	if pthread_attr_setdetachstate(&attr, _PTHREAD_CREATE_DETACHED) != 0 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:53:03 UTC 2024
    - 8.9K bytes
    - Viewed (0)
  3. src/internal/trace/testdata/testprog/cgo-callback.go

    #include <pthread.h>
    
    void go_callback();
    void go_callback2();
    
    static void *thr(void *arg) {
        go_callback();
        return 0;
    }
    
    static void foo() {
        pthread_t th;
        pthread_attr_t attr;
        pthread_attr_init(&attr);
        pthread_attr_setstacksize(&attr, 256 << 10);
        pthread_create(&th, &attr, thr, 0);
        pthread_join(th, 0);
    }
    
    static void bar() {
        go_callback2();
    }
    */
    import "C"
    
    import (
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 18:48:18 UTC 2024
    - 1.3K bytes
    - Viewed (0)
  4. src/runtime/os3_solaris.go

    //
    //go:nowritebarrier
    func newosproc(mp *m) {
    	var (
    		attr pthreadattr
    		oset sigset
    		tid  pthread
    		ret  int32
    		size uint64
    	)
    
    	if pthread_attr_init(&attr) != 0 {
    		throw("pthread_attr_init")
    	}
    	// Allocate a new 2MB stack.
    	if pthread_attr_setstack(&attr, 0, 0x200000) != 0 {
    		throw("pthread_attr_setstack")
    	}
    	// Read back the allocated stack.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:53:03 UTC 2024
    - 17.6K bytes
    - Viewed (0)
  5. src/runtime/cgo/gcc_signal_ios_arm64.c

    	sigfillset(&ign);
    	pthread_sigmask(SIG_SETMASK, &ign, &oset);
    
    	// Start a thread to handle exceptions.
    	uintptr_t port_set = (uintptr_t)mach_exception_handler_port_set;
    	pthread_attr_init(&attr);
    	pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED);
    	ret = _cgo_try_pthread_create(&thr, &attr, mach_exception_handler, (void*)port_set);
    
    	pthread_sigmask(SIG_SETMASK, &oset, nil);
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 21 21:04:22 UTC 2024
    - 6K bytes
    - Viewed (0)
  6. src/runtime/sys_darwin.go

    // and then call the underlying libc function.  They are defined in sys_darwin_$ARCH.s.
    
    //go:nosplit
    //go:cgo_unsafe_args
    func pthread_attr_init(attr *pthreadattr) int32 {
    	ret := libcCall(unsafe.Pointer(abi.FuncPCABI0(pthread_attr_init_trampoline)), unsafe.Pointer(&attr))
    	KeepAlive(attr)
    	return ret
    }
    func pthread_attr_init_trampoline()
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:17:26 UTC 2024
    - 23.9K bytes
    - Viewed (0)
Back to top