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

Problem: memiavl persisted node queries is not optimal #1016

Closed
Tracked by #870
yihuang opened this issue May 3, 2023 · 0 comments · Fixed by #1021
Closed
Tracked by #870

Problem: memiavl persisted node queries is not optimal #1016

yihuang opened this issue May 3, 2023 · 0 comments · Fixed by #1021

Comments

@yihuang
Copy link
Collaborator

yihuang commented May 3, 2023

Leaf Separation

The idea is store leaf nodes separately, so we can directly do binary search in it, using the index.

Traversing the iavl tree is similar to binary search, but with directly binary search on leaf nodes, we have less indirections, based on local benchmarks, this optimization could reduce the time of Get from 200+ns(little endian byte order) or 170ns(native byte order) to 100ns, faster than the performance of MemNode.

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 a pull request may close this issue.

1 participant