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

Try storing Arc<Validator> in HDiffBuffer #6579

Open
michaelsproul opened this issue Nov 11, 2024 · 0 comments
Open

Try storing Arc<Validator> in HDiffBuffer #6579

michaelsproul opened this issue Nov 11, 2024 · 0 comments
Labels
optimization Something to make Lighthouse run more efficiently. tree-states Upcoming state and database overhaul

Comments

@michaelsproul
Copy link
Member

michaelsproul commented Nov 11, 2024

Description

The HDiffBuffer now contains a Vec<Validator> which we could optimise by using Arc:

The validator entries come from a milhouse List originally where they are arced, so we could clone these arcs and share memory between any live milhouse lists and hdiff buffers with the same data. For the freezer DB this isn't particularly likely to happen, but once we start implementing hdiffs in the hot DB, it will be quite common.

@michaelsproul michaelsproul added optimization Something to make Lighthouse run more efficiently. tree-states Upcoming state and database overhaul labels Nov 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
optimization Something to make Lighthouse run more efficiently. tree-states Upcoming state and database overhaul
Projects
None yet
Development

No branches or pull requests

1 participant