- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 8,955 for Wake (0.04 sec)
-
pkg/util/goroutinemap/goroutinemap.go
} // NewGoRoutineMap returns a new instance of GoRoutineMap. func NewGoRoutineMap(exponentialBackOffOnError bool) GoRoutineMap { g := &goRoutineMap{ operations: make(map[string]operation), exponentialBackOffOnError: exponentialBackOffOnError, } g.cond = sync.NewCond(&g.lock) return g } type goRoutineMap struct { operations map[string]operation
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat May 16 11:54:27 UTC 2020 - 6.8K bytes - Viewed (0) -
src/runtime/lock_futex.go
// if *addr == val { sleep } // Might be woken up spuriously; that's allowed. // Don't sleep longer than ns; ns < 0 means forever. // // futexwakeup(addr *uint32, cnt uint32) // If any procs are sleeping on addr, wake up at most cnt. const ( mutex_unlocked = 0 mutex_locked = 1 mutex_sleeping = 2 active_spin = 4 active_spin_cnt = 30 passive_spin = 1 )
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 17:57:34 UTC 2024 - 5.4K bytes - Viewed (0) -
src/runtime/netpoll_kqueue.go
// is closed the write end will not get a // _EVFILT_WRITE event, but will get a // _EVFILT_READ event with EV_EOF set. // Note that setting 'w' here just means that we // will wake up a goroutine waiting to write; // that goroutine will try the write again, // and the appropriate thing will happen based // on what that write returns (success, EPIPE, EAGAIN). if ev.flags&_EV_EOF != 0 {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 12 21:17:22 UTC 2024 - 4.6K bytes - Viewed (0) -
src/runtime/rwmutex.go
r := rw.readerCount.Add(-rwmutexMaxReaders) + rwmutexMaxReaders // Wait for any active readers to complete. lock(&rw.rLock) if r != 0 && rw.readerWait.Add(r) != 0 { // Wait for reader to wake us up. systemstack(func() { rw.writer.set(m) unlock(&rw.rLock) notesleep(&m.park) noteclear(&m.park) }) } else { unlock(&rw.rLock) } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Apr 22 14:29:04 UTC 2024 - 5K bytes - Viewed (0) -
src/runtime/export_debug_test.go
h.debugCallReturn(ctxt) case 2: // Function panicked. Copy panic out. h.debugCallPanicOut(ctxt) case 8: // Call isn't safe. Get the reason. h.debugCallUnsafe(ctxt) // Don't wake h.done. We need to transition to status 16 first. case 16: h.restoreSigContext(ctxt) // Done notewakeup(&h.done) default: h.err = plainError("unexpected debugCallV2 status") notewakeup(&h.done)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 17 15:41:45 UTC 2024 - 5.1K bytes - Viewed (0) -
src/runtime/proc_test.go
defer runtime.GOMAXPROCS(runtime.GOMAXPROCS(1)) done := make(chan bool) hogChan, lightChan := make(chan bool), make(chan bool) hogCount, lightCount := 0, 0 run := func(limit int, counter *int, wake chan bool) { for { select { case <-done: return case <-wake: for i := 0; i < limit; i++ { *counter++ } wake <- true } } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jun 14 00:03:57 UTC 2023 - 25.8K bytes - Viewed (0) -
src/time/sleep_test.go
func TestAfterFunc(t *testing.T) { i := 10 c := make(chan bool) var f func() f = func() { i-- if i >= 0 { AfterFunc(0, f) Sleep(1 * Second) } else { c <- true } } AfterFunc(0, f) <-c } func TestTickerStress(t *testing.T) { var stop atomic.Bool go func() { for !stop.Load() { runtime.GC() // Yield so that the OS can wake up the timer thread,
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Mar 22 16:33:57 UTC 2024 - 22.5K bytes - Viewed (0) -
src/runtime/mgcscavenge.go
func (s *scavengerState) ready() { s.sysmonWake.Store(1) } // wake immediately unparks the scavenger if necessary. // // Safe to run without a P. func (s *scavengerState) wake() { lock(&s.lock) if s.parked { // Unset sysmonWake, since the scavenger is now being awoken. s.sysmonWake.Store(0) // s.parked is unset to prevent a double wake-up. s.parked = false
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 08 17:48:45 UTC 2024 - 52.3K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/InterruptibleTask.java
@Override public final void run() { /* * Set runner thread before checking isDone(). If we were to check isDone() first, the task * might be cancelled before we set the runner thread. That would make it impossible to * interrupt, yet it will still run, since interruptTask will leave the runner value null, * allowing the CAS below to succeed. */ Thread currentThread = Thread.currentThread();
Registered: Wed Jun 12 16:38:11 UTC 2024 - Last Modified: Fri Sep 29 21:34:48 UTC 2023 - 9.9K bytes - Viewed (0) -
pkg/cache/ttlCache.go
return c } func (c *ttlCache) evicter(evictionInterval time.Duration) { // Wake up once in a while and evict stale items ticker := time.NewTicker(evictionInterval) for { select { case now := <-ticker.C: c.evictExpired(now) case <-c.stopEvicter: ticker.Stop() c.evicterTerminated.Done() // record this for the sake of unit tests return } } }
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue May 23 17:08:31 UTC 2023 - 7.8K bytes - Viewed (0)