MCPcopy Create free account
hub / github.com/GoEdgeLab/EdgeNode / BenchmarkNewPartialRanges

Function BenchmarkNewPartialRanges

internal/caches/partial_ranges_test.go:212–219  ·  view source on GitHub ↗
(b *testing.B)

Source from the content-addressed store, hash-verified

210}
211
212func BenchmarkNewPartialRanges(b *testing.B) {
213 for i := 0; i < b.N; i++ {
214 var r = caches.NewPartialRanges(0)
215 for j := 0; j < 1000; j++ {
216 r.Add(int64(j), int64(j+100))
217 }
218 }
219}
220
221func BenchmarkPartialRanges_String(b *testing.B) {
222 var r = caches.NewPartialRanges(0)

Callers

nothing calls this directly

Calls 2

NewPartialRangesFunction · 0.92
AddMethod · 0.65

Tested by

no test coverage detected