(b *testing.B)
| 164 | } |
| 165 | |
| 166 | func BenchmarkWriteVarUint64Loop(b *testing.B) { |
| 167 | buf := NewByteBuffer(make([]byte, 0, 1024)) |
| 168 | values := benchVarUint64Values |
| 169 | b.ReportAllocs() |
| 170 | b.ResetTimer() |
| 171 | for i := 0; i < b.N; i++ { |
| 172 | buf.writerIndex = 0 |
| 173 | buf.WriteVarUint64(values[i%len(values)]) |
| 174 | } |
| 175 | } |
| 176 | |
| 177 | func BenchmarkWriteVarUint64LoopSmall(b *testing.B) { |
| 178 | buf := NewByteBuffer(make([]byte, 0, 1024)) |
nothing calls this directly
no test coverage detected