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

[query] Improve readerIterator performance #3512

Merged
merged 1 commit into from
May 22, 2021
Merged

Conversation

arnikola
Copy link
Collaborator

@arnikola arnikola commented May 22, 2021

What this PR does / why we need it:
Takes logic from the Current() function used to calculate the values
into the Next() function so that it will only be executed once.

Below benchmarks from running the ./bin/read_data_files tool:

Before:

Running time: 732.597858ms
35238 series read
(48100.06 series/second)
2535668 datapoints decoded
(3461200.40 datapoints/second)

After:

Running time: 649.265258ms
35238 series read
(54273.66 series/second)
2535668 datapoints decoded
(3905442.30 datapoints/second)

Takes logic from the Current() function used to calculate the values
into the Next() function so that it will only be executed once
Copy link
Collaborator

@robskillington robskillington left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@codecov
Copy link

codecov bot commented May 22, 2021

Codecov Report

Merging #3512 (75c764f) into master (de6d212) will increase coverage by 0.1%.
The diff coverage is 57.1%.

Impacted file tree graph

@@           Coverage Diff            @@
##           master   #3512     +/-   ##
========================================
+ Coverage    55.9%   56.1%   +0.1%     
========================================
  Files         548     548             
  Lines       61373   61372      -1     
========================================
+ Hits        34328   34441    +113     
+ Misses      23937   23834    -103     
+ Partials     3108    3097     -11     
Flag Coverage Δ
aggregator 57.3% <ø> (-0.1%) ⬇️
cluster ∅ <ø> (∅)
collector 54.3% <ø> (ø)
dbnode 60.6% <57.1%> (+0.2%) ⬆️
m3em 46.4% <ø> (ø)
metrics 19.8% <ø> (ø)
msg 74.6% <ø> (+<0.1%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update de6d212...75c764f. Read the comment docs.

@arnikola arnikola merged commit 4477597 into master May 22, 2021
@arnikola arnikola deleted the arnikola/optimize-iter branch May 22, 2021 03:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants