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

Optimise universe proof leaf additional inputs #503

Open
ffranr opened this issue Sep 13, 2023 · 0 comments
Open

Optimise universe proof leaf additional inputs #503

ffranr opened this issue Sep 13, 2023 · 0 comments

Comments

@ffranr
Copy link
Contributor

ffranr commented Sep 13, 2023

As things currently stand, a universe's proof leaf has a field called AdditionalInputs. This field contains proofs for other inputs that may have been merged as part of a spend.

The AdditionalInputs field is of type []proof.File. Which means, that for each additional input, we store an entire proof file. A universe leaf is supposed to represent a single proof. But where additional inputs are concerned, a universe leaf may also contain entire proof files for each additional input.

This means that a universe makes sub-optimal use of memory in that each leaf may also contain entire proof files which are duplicated as leaves in other parts of the universe.

Within a universe leaf, the AdditionalInputs field should perhaps contain proof locators instead of entire proof files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants