Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 50 for Setg (0.04 sec)

  1. src/runtime/export_unix_test.go

    func WaitForSigusr1(r, w int32, ready func(mp *M)) (int64, int64) {
    	lockOSThread()
    	// Make sure we can receive SIGUSR1.
    	unblocksig(_SIGUSR1)
    
    	waitForSigusr1.rdpipe = r
    	waitForSigusr1.wrpipe = w
    
    	mp := getg().m
    	testSigusr1 = waitForSigusr1Callback
    	ready(mp)
    
    	// Wait for the signal. We use a pipe rather than a note
    	// because write is always async-signal-safe.
    	entersyscallblock()
    	var b byte
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat May 20 21:27:51 UTC 2023
    - 2.3K bytes
    - Viewed (0)
  2. src/runtime/os_dragonfly.go

    // Called to initialize a new m (including the bootstrap m).
    // Called on the new thread, cannot allocate memory.
    func minit() {
    	getg().m.procid = uint64(lwp_gettid())
    	minitSignals()
    }
    
    // Called from dropm to undo the effect of an minit.
    //
    //go:nosplit
    func unminit() {
    	unminitSignals()
    	getg().m.procid = 0
    }
    
    // Called from exitm, but not from drop, to undo the effect of thread-owned
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Dec 05 20:34:30 UTC 2023
    - 7.1K bytes
    - Viewed (0)
  3. src/runtime/cgo.go

    // so it emits the test and keeps the call, giving the desired
    // escape analysis result. The test is cheaper than the call.
    var cgoAlwaysFalse bool
    
    var cgo_yield = &_cgo_yield
    
    func cgoNoCallback(v bool) {
    	g := getg()
    	if g.nocgocallback && v {
    		panic("runtime: unexpected setting cgoNoCallback")
    	}
    	g.nocgocallback = v
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:16:47 UTC 2024
    - 3.1K bytes
    - Viewed (0)
  4. src/runtime/mcheckmark.go

    		print("runtime: found obj at *(", hex(base), "+", hex(off), ")\n")
    
    		// Dump the source (base) object
    		gcDumpObject("base", base, off)
    
    		// Dump the object
    		gcDumpObject("obj", obj, ^uintptr(0))
    
    		getg().m.traceback = 2
    		throw("checkmark found unmarked object")
    	}
    
    	ai := arenaIndex(obj)
    	arena := mheap_.arenas[ai.l1()][ai.l2()]
    	arenaWord := (obj / heapArenaBytes / 8) % uintptr(len(arena.checkmarks.b))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:53:03 UTC 2024
    - 2.8K bytes
    - Viewed (0)
  5. src/runtime/atomic_pointer.go

    // Do not remove or change the type signature.
    // See go.dev/issue/67401.
    //
    //go:linkname atomicwb
    //go:nosplit
    func atomicwb(ptr *unsafe.Pointer, new unsafe.Pointer) {
    	slot := (*uintptr)(unsafe.Pointer(ptr))
    	buf := getg().m.p.ptr().wbBuf.get2()
    	buf[0] = *slot
    	buf[1] = uintptr(new)
    }
    
    // atomicstorep performs *ptr = new atomically and invokes a write barrier.
    //
    //go:nosplit
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 16:25:21 UTC 2024
    - 4K bytes
    - Viewed (0)
  6. src/runtime/netpoll_windows.go

    func netpoll(delay int64) (gList, int32) {
    	if iocphandle == _INVALID_HANDLE_VALUE {
    		return gList{}, 0
    	}
    
    	var entries [64]overlappedEntry
    	var wait uint32
    	var toRun gList
    	mp := getg().m
    
    	if delay >= 1e15 {
    		// An arbitrary cap on how long to wait for a timer.
    		// 1e15 ns == ~11.5 days.
    		delay = 1e15
    	}
    
    	if delay > 0 && mp.waitIocpHandle != 0 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Mar 26 19:58:28 UTC 2024
    - 9.4K bytes
    - Viewed (0)
  7. src/internal/trace/testdata/testprog/cpu-profile.go

    	}
    	// Examine the CPU profiler's view. Filter it to only include samples from
    	// the single test goroutine. Use labels to execute that filter: they should
    	// apply to all work done while that goroutine is getg().m.curg, and they
    	// should apply to no other goroutines.
    	pprofStacks := make(map[string]int)
    	for _, s := range prof.Sample {
    		if s.Label["tracing"] != nil {
    			var fns []string
    			var leaf string
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 18:48:18 UTC 2024
    - 3.8K bytes
    - Viewed (0)
  8. src/runtime/checkptr.go

    //   - github.com/bytedance/sonic
    //
    // Do not remove or change the type signature.
    // See go.dev/issue/67401.
    //
    //go:linkname checkptrBase
    func checkptrBase(p unsafe.Pointer) uintptr {
    	// stack
    	if gp := getg(); gp.stack.lo <= uintptr(p) && uintptr(p) < gp.stack.hi {
    		// TODO(mdempsky): Walk the stack to identify the
    		// specific stack frame or even stack object that p
    		// points into.
    		//
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 00:18:55 UTC 2024
    - 3.6K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/ssa/regalloc_test.go

    	checkFunc(f.f)
    }
    
    // Test to make sure G register is never reloaded from spill (spill of G is okay)
    // See #25504
    func TestNoGetgLoadReg(t *testing.T) {
    	/*
    		Original:
    		func fff3(i int) *g {
    			gee := getg()
    			if i == 0 {
    				fff()
    			}
    			return gee // here
    		}
    	*/
    	c := testConfigARM64(t)
    	f := c.Fun("b1",
    		Bloc("b1",
    			Valu("v1", OpInitMem, types.TypeMem, 0, nil),
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Sep 08 19:09:14 UTC 2023
    - 6.3K bytes
    - Viewed (0)
  10. src/runtime/cgocheck.go

    	}
    	if !cgoIsGoPointer(src) {
    		return
    	}
    	if cgoIsGoPointer(unsafe.Pointer(dst)) {
    		return
    	}
    
    	// If we are running on the system stack then dst might be an
    	// address on the stack, which is OK.
    	gp := getg()
    	if gp == gp.m.g0 || gp == gp.m.gsignal {
    		return
    	}
    
    	// Allocating memory can write to various mfixalloc structs
    	// that look like they are non-Go memory.
    	if gp.m.mallocing != 0 {
    		return
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 09 04:07:57 UTC 2024
    - 7.6K bytes
    - Viewed (0)
Back to top