Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for acquireTime (0.13 sec)

  1. src/runtime/sema.go

    		return
    	}
    	s, t0, tailtime := root.dequeue(addr)
    	if s != nil {
    		root.nwait.Add(-1)
    	}
    	unlock(&root.lock)
    	if s != nil { // May be slow or even yield, so unlock first
    		acquiretime := s.acquiretime
    		if acquiretime != 0 {
    			// Charge contention that this (delayed) unlock caused.
    			// If there are N more goroutines waiting beyond the
    			// one that's waking up, charge their delay as well, so that
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 17:58:53 UTC 2024
    - 19K bytes
    - Viewed (0)
  2. src/runtime/runtime2.go

    	// For channels, waitlink is only accessed by g.
    	// For semaphores, all fields (including the ones above)
    	// are only accessed when holding a semaRoot lock.
    
    	acquiretime int64
    	releasetime int64
    	ticket      uint32
    
    	// isSelect indicates g is participating in a select, so
    	// g.selectDone must be CAS'd to win the wake-up race.
    	isSelect bool
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 17:57:37 UTC 2024
    - 47.9K bytes
    - Viewed (0)
  3. src/runtime/export_test.go

    type SemTable struct {
    	semTable
    }
    
    // Enqueue simulates enqueuing a waiter for a semaphore (or lock) at addr.
    func (t *SemTable) Enqueue(addr *uint32) {
    	s := acquireSudog()
    	s.releasetime = 0
    	s.acquiretime = 0
    	s.ticket = 0
    	t.semTable.rootFor(addr).queue(addr, s, false)
    }
    
    // Dequeue simulates dequeuing a waiter for a semaphore (or lock) at addr.
    //
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 17:50:53 UTC 2024
    - 46.1K bytes
    - Viewed (0)
Back to top