MCPcopy Index your code
hub / github.com/Workiva/go-datastructures / BenchmarkSetCompressedBit

Function BenchmarkSetCompressedBit

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

Source from the content-addressed store, hash-verified

66}
67
68func BenchmarkSetCompressedBit(b *testing.B) {
69 numItems := 1000
70 ba := newSparseBitArray()
71
72 b.ResetTimer()
73 for i := 0; i < b.N; i++ {
74 for j := 0; j < numItems; j++ {
75 ba.SetBit(uint64(j))
76 }
77 }
78}
79
80func TestGetSetCompressedBits(t *testing.T) {
81 ba := newSparseBitArray()

Callers

nothing calls this directly

Calls 2

newSparseBitArrayFunction · 0.85
SetBitMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…