Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 86 for index (0.11 sec)

  1. src/bytes/bytes_test.go

    }
    
    func bmIndexRuneASCII(index func([]byte, rune) int) func(b *testing.B, n int) {
    	return func(b *testing.B, n int) {
    		buf := bmbuf[0:n]
    		buf[n-1] = 'x'
    		for i := 0; i < b.N; i++ {
    			j := index(buf, 'x')
    			if j != n-1 {
    				b.Fatal("bad index", j)
    			}
    		}
    		buf[n-1] = '\x00'
    	}
    }
    
    func bmIndexRune(index func([]byte, rune) int) func(b *testing.B, n int) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 03 12:58:37 UTC 2024
    - 56.5K bytes
    - Viewed (0)
  2. src/reflect/type.go

    				}
    				nextCount[styp] = 1
    				if count[t] > 1 {
    					nextCount[styp] = 2 // exact multiple doesn't matter
    				}
    				var index []int
    				index = append(index, scan.index...)
    				index = append(index, i)
    				next = append(next, fieldScan{styp, index})
    			}
    		}
    		if ok {
    			break
    		}
    	}
    	return
    }
    
    // FieldByName returns the struct field with the given name
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 17:58:53 UTC 2024
    - 85.5K bytes
    - Viewed (0)
  3. src/strings/strings_test.go

    		b.Fatalf("wrong index: expected 17, got=%d", got)
    	}
    	for i := 0; i < b.N; i++ {
    		IndexRune(benchmarkString, 'v')
    	}
    }
    
    func BenchmarkIndex(b *testing.B) {
    	if got := Index(benchmarkString, "v"); got != 17 {
    		b.Fatalf("wrong index: expected 17, got=%d", got)
    	}
    	for i := 0; i < b.N; i++ {
    		Index(benchmarkString, "v")
    	}
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 03 12:58:37 UTC 2024
    - 53K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/syntax/parser.go

    			p.xnest++
    			t := new(SliceExpr)
    			t.pos = pos
    			t.X = x
    			t.Index[0] = i
    			if p.tok != _Colon && p.tok != _Rbrack {
    				// x[i:j...
    				t.Index[1] = p.expr()
    			}
    			if p.tok == _Colon {
    				t.Full = true
    				// x[i:j:...]
    				if t.Index[1] == nil {
    					p.error("middle index required in 3-index slice")
    					t.Index[1] = p.badExpr()
    				}
    				p.next()
    				if p.tok != _Rbrack {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 62.9K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/ppc64/ssa.go

    			p.To.Type = obj.TYPE_MEM
    			p.To.Reg = v.Args[0].Reg()
    			p.To.Index = ppc64.REGZERO
    			// Save the top of loop
    			if top == nil {
    				top = p
    			}
    			p = s.Prog(ppc64.ASTXVD2X)
    			p.From.Type = obj.TYPE_REG
    			p.From.Reg = ppc64.REG_VS32
    			p.To.Type = obj.TYPE_MEM
    			p.To.Reg = v.Args[0].Reg()
    			p.To.Index = ppc64.REGTMP
    
    			// Increment address for the
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 19:59:38 UTC 2024
    - 55.4K bytes
    - Viewed (0)
  6. src/cmd/go/internal/modload/init.go

    	if !addToolchainRoot {
    		padding = 1
    	}
    	roots = make([]module.Version, 0, padding+len(modFile.Require))
    	for _, r := range modFile.Require {
    		if index := MainModules.Index(m); index != nil && index.exclude[r.Mod] {
    			if cfg.BuildMod == "mod" {
    				fmt.Fprintf(os.Stderr, "go: dropping requirement on excluded version %s %s\n", r.Mod.Path, r.Mod.Version)
    			} else {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Jun 06 18:36:30 UTC 2024
    - 69.8K bytes
    - Viewed (0)
  7. cmd/bucket-handlers.go

    	bucketsToBeUpdatedSlice := bucketsToBeUpdated.ToSlice()
    	g := errgroup.WithNErrs(len(bucketsToBeUpdatedSlice)).WithConcurrency(50)
    
    	for index := range bucketsToBeUpdatedSlice {
    		index := index
    		g.Go(func() error {
    			return globalDNSConfig.Put(bucketsToBeUpdatedSlice[index])
    		}, index)
    	}
    
    	ctx := GlobalContext
    	for _, err := range g.Wait() {
    		if err != nil {
    			dnsLogIf(ctx, err)
    			return
    		}
    	}
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri Jun 14 13:28:35 UTC 2024
    - 61.2K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiextensions-apiserver/pkg/apiserver/schema/cel/compilation_test.go

    			setMaxElements:   4,
    			expectedSetCost:  7,
    		},
    		{
    			name:             "index of array with numbers",
    			schemaGenerator:  genArrayWithRule("number", "self[1] == 0.0"),
    			expectedCalcCost: 2,
    			setMaxElements:   5000,
    			expectedSetCost:  2,
    		},
    		{
    			name:             "index of array with strings",
    			schemaGenerator:  genArrayWithRule("string", "self[1] == self[1]"),
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu May 16 20:13:14 UTC 2024
    - 51.5K bytes
    - Viewed (0)
  9. src/runtime/mgcscavenge.go

    	printunlock()
    }
    
    // scavengeOne walks over the chunk at chunk index ci and searches for
    // a contiguous run of pages to scavenge. It will try to scavenge
    // at most max bytes at once, but may scavenge more to avoid
    // breaking huge pages. Once it scavenges some memory it returns
    // how much it scavenged in bytes.
    //
    // searchIdx is the page index to start searching from in ci.
    //
    // Returns the number of bytes scavenged.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 08 17:48:45 UTC 2024
    - 52.3K bytes
    - Viewed (0)
  10. pkg/scheduler/framework/runtime/framework.go

    	f.Parallelizer().Until(ctx, len(nodes), func(index int) {
    		nodePluginScores := framework.NodePluginScores{
    			Name:   nodes[index].Node().Name,
    			Scores: make([]framework.PluginScore, len(plugins)),
    		}
    
    		for i, pl := range plugins {
    			weight := f.scorePluginWeight[pl.Name()]
    			nodeScoreList := pluginToNodeScores[pl.Name()]
    			score := nodeScoreList[index].Score
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 17 09:07:27 UTC 2024
    - 60.9K bytes
    - Viewed (0)
Back to top