Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reuse buffer for hash computation in the engine. #2218

Merged
merged 1 commit into from
Jun 19, 2020

Conversation

cyriltovena
Copy link
Contributor

Signed-off-by: Cyril Tovena cyril.tovena@gmail.com

❯ benchcmp old.txt new.txt
benchmark                         old ns/op      new ns/op      delta
BenchmarkRangeQuery100000-16      3282273        2946683        -10.22%
BenchmarkRangeQuery200000-16      15338653       15573954       +1.53%
BenchmarkRangeQuery500000-16      2025848024     1976072536     -2.46%
BenchmarkRangeQuery1000000-16     3964696705     3868484541     -2.43%

benchmark                         old allocs     new allocs     delta
BenchmarkRangeQuery100000-16      5244           5296           +0.99%
BenchmarkRangeQuery200000-16      5932           6025           +1.57%
BenchmarkRangeQuery500000-16      138655         138727         +0.05%
BenchmarkRangeQuery1000000-16     271995         272065         +0.03%

benchmark                         old bytes     new bytes     delta
BenchmarkRangeQuery100000-16      719383        720496        +0.15%
BenchmarkRangeQuery200000-16      1404153       1446713       +3.03%
BenchmarkRangeQuery500000-16      135373656     135393336     +0.01%
BenchmarkRangeQuery1000000-16     270947216     270966704     +0.01%

Allocations are a bit more but this is because we need to improve a bit our benchmark to use more labels, currently use only foo/bar...

Signed-off-by: Cyril Tovena <cyril.tovena@gmail.com>
@owen-d owen-d merged commit 7212564 into grafana:master Jun 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants