MCPcopy Create free account
hub / github.com/Workiva/go-datastructures / BenchmarkSparseBitArrayToNums

Function BenchmarkSparseBitArrayToNums

bitarray/sparse_bitarray_test.go:366–378  ·  view source on GitHub ↗
(b *testing.B)

Source from the content-addressed store, hash-verified

364}
365
366func BenchmarkSparseBitArrayToNums(b *testing.B) {
367 numItems := uint64(1000)
368 sba := newSparseBitArray()
369
370 for i := uint64(0); i < numItems; i++ {
371 sba.SetBit(i)
372 }
373
374 b.ResetTimer()
375 for i := 0; i < b.N; i++ {
376 sba.ToNums()
377 }
378}

Callers

nothing calls this directly

Calls 3

newSparseBitArrayFunction · 0.85
SetBitMethod · 0.65
ToNumsMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…