- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for numWrites (0.1 sec)
-
pkg/channels/unbounded_test.go
wg.Add(1) go func() { defer wg.Done() ch := ub.Get() for i := 0; i < numWriters*numWrites; i++ { r := <-ch reads = append(reads, r) ub.Load() } }() wg.Add(numWriters) for i := 0; i < numWriters; i++ { go func(index int) { defer wg.Done() for j := 0; j < numWrites; j++ { ub.Put(index) } }(i) } wg.Wait() sort.Ints(reads)
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed Aug 31 19:53:39 UTC 2022 - 2.3K bytes - Viewed (0) -
src/strings/builder_test.go
f(b, 3, true) }) } func BenchmarkBuildString_Builder(b *testing.B) { benchmarkBuilder(b, func(b *testing.B, numWrite int, grow bool) { for i := 0; i < b.N; i++ { var buf Builder if grow { buf.Grow(len(someBytes) * numWrite) } for i := 0; i < numWrite; i++ { buf.Write(someBytes) } sinkS = buf.String() } }) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Feb 19 19:51:15 UTC 2024 - 8.1K bytes - Viewed (0)