MCPcopy Create free account
hub / github.com/LagrangeDev/LagrangeGo / benchEncoderUvarint

Function benchEncoderUvarint

internal/proto/dynamic_test.go:11–17  ·  view source on GitHub ↗
(b *testing.B, v uint64)

Source from the content-addressed store, hash-verified

9)
10
11func benchEncoderUvarint(b *testing.B, v uint64) {
12 e := encoder{}
13 for i := 0; i < b.N; i++ {
14 e.buf = e.buf[:0]
15 e.uvarint(v)
16 }
17}
18
19func benchEncoderSvarint(b *testing.B, v int64) {
20 e := encoder{}

Callers 1

Calls 1

uvarintMethod · 0.95

Tested by

no test coverage detected