Branch: refs/heads/master
Home: https://github.com/conformal/btcwire
Commit: 900db0b44471965de9597af2998e99a089454885
https://github.com/conformal/btcwire/commit/900db0b44471965de9597af2998e99a089454885
Author: Dave Collins <[email protected]>
Date: 2013-11-05 (Tue, 05 Nov 2013)
Changed paths:
A bench_test.go
Log Message:
-----------
Add benchmarks for writeVarInt.
This commit adds a few benchmarks for the writeVarInt function.
Commit: 50c10faf4e679d96b25a633a7c33e5f80e894628
https://github.com/conformal/btcwire/commit/50c10faf4e679d96b25a633a7c33e5f80e894628
Author: Dave Collins <[email protected]>
Date: 2013-11-05 (Tue, 05 Nov 2013)
Changed paths:
M common.go
Log Message:
-----------
Optimize writeVarInt.
Before:
BenchmarkWriteVarInt1 10000000 173 ns/op
BenchmarkWriteVarInt3 2000000 965 ns/op
BenchmarkWriteVarInt5 2000000 966 ns/op
BenchmarkWriteVarInt9 2000000 968 ns/op
After:
BenchmarkWriteVarInt1 20000000 101 ns/op
BenchmarkWriteVarInt3 20000000 136 ns/op
BenchmarkWriteVarInt5 10000000 142 ns/op
BenchmarkWriteVarInt9 10000000 156 ns/op
This is part of the ongoing effort to optimize serialization as noted in
conformal/btcd#27.
Compare:
https://github.com/conformal/btcwire/compare/b7b700fd5aeb...50c10faf4e67