Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 16 for nondeterministic (0.2 sec)

  1. src/sort/sort_test.go

    func (t *nonDeterministicTestingData) Less(i, j int) bool {
    	if i < 0 || j < 0 || i >= t.Len() || j >= t.Len() {
    		panic("nondeterministic comparison out of bounds")
    	}
    	return t.r.Float32() < 0.5
    }
    func (t *nonDeterministicTestingData) Swap(i, j int) {
    	if i < 0 || j < 0 || i >= t.Len() || j >= t.Len() {
    		panic("nondeterministic comparison out of bounds")
    	}
    }
    
    func TestNonDeterministicComparison(t *testing.T) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 07 19:41:04 UTC 2024
    - 16.9K bytes
    - Viewed (0)
  2. pilot/pkg/config/kube/ingress/controller.go

    func sortIngressByCreationTime(ingr []*knetworking.Ingress) []*knetworking.Ingress {
    	sort.Slice(ingr, func(i, j int) bool {
    		// If creation time is the same, then behavior is nondeterministic. In this case, we can
    		// pick an arbitrary but consistent ordering based on name and namespace, which is unique.
    		// CreationTimestamp is stored in seconds, so this is not uncommon.
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon May 06 03:53:05 UTC 2024
    - 11.9K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/pkginit/initAsanGlobals.go

    // globals.
    // And the key is the object name. For example, in package p, a global foo would be in this
    // map as "foo".
    // Consider range over maps is nondeterministic, make a slice to hold all the values in the
    // InstrumentGlobalsMap and iterate over the InstrumentGlobalsSlice.
    var InstrumentGlobalsMap = make(map[string]ir.Node)
    var InstrumentGlobalsSlice = make([]ir.Node, 0, 0)
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Aug 17 19:36:24 UTC 2023
    - 8.7K bytes
    - Viewed (0)
  4. src/cmd/go/internal/modget/query.go

    // call to f for the given path has completed on return.
    //
    // pathOnce is safe for concurrent use by multiple goroutines, but note that
    // multiple concurrent calls will result in the sets being added in
    // nondeterministic order.
    func (q *query) pathOnce(path string, f func() pathSet) {
    	if _, dup := q.pathSeen.LoadOrStore(path, nil); dup {
    		return
    	}
    
    	cs := f()
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Nov 27 15:48:25 UTC 2023
    - 11.2K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/cache/PopulatedCachesTest.java

        // of the values gets evicted. With weak keys, we use identity equality, which means using
        // System.identityHashCode, which means the assignment of keys to segments is nondeterministic,
        // so more than (maximumSize / #segments) keys could get assigned to the same segment, which
        // would cause one to be evicted.
        return new CacheBuilderFactory()
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Sep 06 17:04:31 UTC 2023
    - 15K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/ssa/stackalloc.go

    	} else {
    		s.names = make([]LocalSlot, n)
    	}
    	names := s.names
    	empty := LocalSlot{}
    	for _, name := range f.Names {
    		// Note: not "range f.NamedValues" above, because
    		// that would be nondeterministic.
    		for _, v := range f.NamedValues[*name] {
    			if v.Op == OpArgIntReg || v.Op == OpArgFloatReg {
    				aux := v.Aux.(*AuxNameOffset)
    				// Never let an arg be bound to a differently named thing.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Feb 29 21:29:41 UTC 2024
    - 12.6K bytes
    - Viewed (0)
  7. pilot/pkg/model/config.go

    func sortByCreationComparator(configs []config.Config) func(i, j int) bool {
    	return func(i, j int) bool {
    		// If creation time is the same, then behavior is nondeterministic. In this case, we can
    		// pick an arbitrary but consistent ordering based on name and namespace, which is unique.
    		// CreationTimestamp is stored in seconds, so this is not uncommon.
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Feb 28 08:51:03 UTC 2024
    - 13.1K bytes
    - Viewed (0)
  8. src/testing/sub_test.go

    		for i := 0; i < 2; i++ {
    			i := i
    			go func() {
    				t.Cleanup(func() {
    					// Although the calls to Cleanup are concurrent, the functions passed
    					// to Cleanup should be called sequentially, in some nondeterministic
    					// order based on when the Cleanup calls happened to be scheduled.
    					// So these assignments to the cleanups variable should not race.
    					cleanups |= 1 << i
    				})
    				wg.Done()
    			}()
    		}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Dec 01 21:27:08 UTC 2023
    - 23.8K bytes
    - Viewed (0)
  9. guava/src/com/google/common/collect/Streams.java

       * href="http://gee.cs.oswego.edu/dl/html/StreamParallelGuidance.html">efficiently splittable</a>
       * streams.
       *
       * <p>If the stream has nondeterministic order, this has equivalent semantics to {@link
       * Stream#findAny} (which you might as well use).
       *
       * @see Stream#findFirst()
       * @throws NullPointerException if the last element of the stream is null
       */
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Thu Feb 22 21:19:52 UTC 2024
    - 36.5K bytes
    - Viewed (0)
  10. src/cmd/go/internal/modget/get.go

    			})
    		}
    		return versionOk
    	}
    
    	r.loadPackages(ctx, []string{"all"}, findPackage)
    
    	// Since we built up the candidate lists concurrently, they may be in a
    	// nondeterministic order. We want 'go get' to be fully deterministic,
    	// including in which errors it chooses to report, so sort the candidates
    	// into a deterministic-but-arbitrary order.
    	for _, q := range r.patternAllQueries {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 07 18:26:32 UTC 2024
    - 66.5K bytes
    - Viewed (0)
Back to top