Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 77 for unlocked (0.88 sec)

  1. src/cmd/go/internal/lockedfile/internal/filelock/filelock_test.go

    		// silently unlocked. So a second RLock must block instead of proceeding.
    		lockF2 := mustBlock(t, "RLock", f2)
    		unlock(t, f)
    		lockF2(t)
    	default:
    		rLock(t, f2)
    		doUnlockTF = true
    	}
    
    	other := mustOpen(t, f.Name())
    	defer other.Close()
    	lockOther := mustBlock(t, "Lock", other)
    
    	unlock(t, f2)
    	if doUnlockTF {
    		unlock(t, f)
    	}
    	lockOther(t)
    	unlock(t, other)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 06 22:37:50 UTC 2023
    - 4K bytes
    - Viewed (0)
  2. src/cmd/vendor/golang.org/x/telemetry/internal/counter/counter.go

    	}
    	if n == 0 {
    		return
    	}
    	c.file.register(c)
    
    	state := c.state.load()
    	for ; ; state = c.state.load() {
    		switch {
    		case !state.locked() && state.havePtr():
    			if !c.state.update(&state, state.incReader()) {
    				continue
    			}
    			// Counter unlocked or counter shared; has an initialized count pointer; acquired shared lock.
    			if c.ptr.count == nil {
    				for !c.state.update(&state, state.addExtra(uint64(n))) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 04 16:19:04 UTC 2024
    - 10.3K bytes
    - Viewed (0)
  3. src/cmd/go/internal/lockedfile/lockedfile_test.go

    		t.Logf("unlock2()")
    		unlock2()
    	})
    
    	t.Logf("unlock()")
    	unlock()
    	wait(t)
    }
    
    func TestReadWaitsForLock(t *testing.T) {
    	t.Parallel()
    
    	dir, remove := mustTempDir(t)
    	defer remove()
    
    	path := filepath.Join(dir, "timestamp.txt")
    
    	f, err := lockedfile.Create(path)
    	if err != nil {
    		t.Fatalf("Create: %v", err)
    	}
    	defer f.Close()
    
    	const (
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Sep 05 23:35:29 UTC 2023
    - 5.7K bytes
    - Viewed (0)
  4. src/cmd/go/internal/lockedfile/internal/filelock/filelock_fcntl.go

    	// 	P.1 unlocks file A.
    	// 	Q.3 unblocks and locks file A.
    	// 	Q.3 unlocks files A and B.
    	// 	P.2 wakes up and locks file B.
    	// 	P.2 unlocks file B.
    	//
    	// We know that the retry loop will not introduce a *spurious* livelock
    	// because, according to the POSIX specification, EDEADLK is only to be
    	// returned when “the lock is blocked by a lock from another process”.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 17 02:24:35 UTC 2023
    - 5.5K bytes
    - Viewed (0)
  5. src/cmd/cgo/internal/test/sigprocmask.go

    */
    import "C"
    import (
    	"os"
    	"os/signal"
    	"syscall"
    	"testing"
    )
    
    var blocked bool
    
    //export IntoGoAndBack
    func IntoGoAndBack() {
    	// Verify that SIGIO stays blocked on the C thread
    	// even when unblocked for signal.Notify().
    	signal.Notify(make(chan os.Signal), syscall.SIGIO)
    	blocked = C.CheckBlocked() != 0
    }
    
    func testSigprocmask(t *testing.T) {
    	if r := C.RunSigThread(); r != 0 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 12:00:02 UTC 2023
    - 808 bytes
    - Viewed (0)
  6. src/cmd/go/internal/lockedfile/lockedfile_plan9.go

    //
    //   - "open/create -- file is locked" (cwfs, kfs)
    //   - "exclusive lock" (fossil)
    //   - "exclusive use file already open" (ramfs)
    var lockedErrStrings = [...]string{
    	"file is locked",
    	"exclusive lock",
    	"exclusive use file already open",
    }
    
    // Even though plan9 doesn't support the Lock/RLock/Unlock functions to
    // manipulate already-open files, IsLocked is still meaningful: os.OpenFile
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 11 16:34:30 UTC 2022
    - 2.5K bytes
    - Viewed (0)
  7. src/cmd/trace/gstate.go

    // and orthogonal to syscallEnd; both must be called if the syscall blocked. This sets up an instant
    // to emit a flow event from, indicating explicitly that this goroutine was unblocked by the system.
    func (gs *gState[R]) blockedSyscallEnd(ts trace.Time, stack trace.Stack, ctx *traceContext) {
    	name := "exit blocked syscall"
    	gs.setStartCause(ts, name, trace.SyscallP, stack)
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 18:48:18 UTC 2024
    - 11.9K bytes
    - Viewed (0)
  8. src/cmd/trace/goroutinegen.go

    	}
    
    	if from == trace.GoWaiting {
    		// Goroutine unblocked.
    		gs.unblock(ev.Time(), ev.Stack(), ev.Goroutine(), ctx)
    	}
    	if from == trace.GoNotExist && to == trace.GoRunnable {
    		// Goroutine was created.
    		gs.created(ev.Time(), ev.Goroutine(), ev.Stack())
    	}
    	if from == trace.GoSyscall && to != trace.GoRunning {
    		// Exiting blocked syscall.
    		gs.syscallEnd(ev.Time(), true, ctx)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 18:48:18 UTC 2024
    - 4.6K bytes
    - Viewed (0)
  9. src/cmd/trace/threadgen.go

    		if from == trace.GoUndetermined {
    			// Back-date the event to the start of the trace.
    			start = ctx.startTime
    		}
    		gs.start(start, ev.Thread(), ctx)
    	}
    
    	if from == trace.GoWaiting {
    		// Goroutine was unblocked.
    		gs.unblock(ev.Time(), ev.Stack(), ev.Thread(), ctx)
    	}
    	if from == trace.GoNotExist && to == trace.GoRunnable {
    		// Goroutine was created.
    		gs.created(ev.Time(), ev.Thread(), ev.Stack())
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 18:48:18 UTC 2024
    - 5.7K bytes
    - Viewed (0)
  10. src/cmd/vendor/golang.org/x/text/unicode/norm/composition.go

    		// is safe.
    		if ii.combinesBackward() {
    			cccB := b[k-1].ccc
    			cccC := ii.ccc
    			blocked := false // b[i] blocked by starter or greater or equal CCC?
    			if cccB == 0 {
    				s = k - 1
    			} else {
    				blocked = s != k-1 && cccB >= cccC
    			}
    			if !blocked {
    				combined := combine(rb.runeAt(s), rb.runeAt(i))
    				if combined != 0 {
    					rb.assignRune(s, combined)
    					continue
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 24 13:01:26 UTC 2024
    - 14.1K bytes
    - Viewed (0)
Back to top