avalanchego
avalanchego copied to clipboard
Some more GetCanonicalValidatorSet benchmarks
Why this should be merged
How this works
How this was tested
abenegia@avaLabs:~/work/avalanchego$ go test -run=^$ -bench ^BenchmarkGetCanonicalValidatorSetByDepth$ github.com/ava-labs/avalanchego/vms/platformvm/warp/benchmarks -cpuprofile=cpuprofile.out goos: linux goarch: amd64 pkg: github.com/ava-labs/avalanchego/vms/platformvm/warp/benchmarks cpu: Intel(R) Core(TM) i7-10750H CPU @ 2.60GHz BenchmarkGetCanonicalValidatorSetByDepth/0-12 20356 57927 ns/op BenchmarkGetCanonicalValidatorSetByDepth/1-12 22956 50642 ns/op BenchmarkGetCanonicalValidatorSetByDepth/2-12 26288 45141 ns/op BenchmarkGetCanonicalValidatorSetByDepth/3-12 29674 38662 ns/op BenchmarkGetCanonicalValidatorSetByDepth/4-12 34130 33823 ns/op BenchmarkGetCanonicalValidatorSetByDepth/5-12 42694 28255 ns/op BenchmarkGetCanonicalValidatorSetByDepth/6-12 52185 22563 ns/op BenchmarkGetCanonicalValidatorSetByDepth/7-12 65055 16938 ns/op BenchmarkGetCanonicalValidatorSetByDepth/8-12 101066 11559 ns/op BenchmarkGetCanonicalValidatorSetByDepth/9-12 166063 6466 ns/op PASS ok github.com/ava-labs/avalanchego/vms/platformvm/warp/benchmarks 16.216s
I feel like we should probably be separating benchmarks for GetCanonicalValidatorSet
and GetValidatorSet
rather than expanding tests for GetCanonicalValidatorSet
to include the actual GetValidatorSet
implementation
I feel like we should probably be separating benchmarks for
GetCanonicalValidatorSet
andGetValidatorSet
rather than expanding tests forGetCanonicalValidatorSet
to include the actualGetValidatorSet
implementation
@StephenButtolph , I think @aaronbuchwald request was to have a scenario as close as possible to prod, to get a feeling of the costs of supporting GetCanonicalValidatorSet
. Also bls key creation really dominates all of other ops, hence I doubt we would get much more insight until we optimize/cache bls keys handling?
This PR has become stale because it has been open for 30 days with no activity. Adding the lifecycle/frozen
label will cause this PR to ignore lifecycle events.
This PR has become stale because it has been open for 30 days with no activity. Adding the lifecycle/frozen
label will cause this PR to ignore lifecycle events.
This PR has become stale because it has been open for 30 days with no activity. Adding the lifecycle/frozen
label will cause this PR to ignore lifecycle events.