-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Replace binary search with linear search for epoch construction #723
Conversation
Unrolling the first four epochs gives a very significant speedup for my benchmark of indexing 1000 blocks starting from block 700000. Index time drops from 44 minutes (linear search) to 31 minutes (unrolled loop). Seems worth it. Will try to use criterion benchmark for this function. |
Maybe we should unroll the loop the whole way? Each epoch is half as big as the previous, so I think a linear search will always be more performant. Obviously small gains, but it's a little cleaner. |
No description provided.