Skip to content

feat: avm merkle gadget in vm2#12726

Merged
dbanks12 merged 40 commits into
masterfrom
db/merkle
Mar 20, 2025
Merged

feat: avm merkle gadget in vm2#12726
dbanks12 merged 40 commits into
masterfrom
db/merkle

Conversation

@dbanks12

@dbanks12 dbanks12 commented Mar 13, 2025

Copy link
Copy Markdown
Contributor

This differs from vm1's merkle gadget in one primary way; the caller is meant to lookup on "end" instead of "start". This changes which inputs need dedicated columns and need to be propagated down during a merkle check. In vm1's implementation, the only thing that needed to be propagated down was expected_root. In this vm2 implementation, we need to propagate leaf, leaf_index, and tree_height, but not expected_root.

I got close to reverting this primary difference but opted not to because it only saves one maybe two columns. If we decide that we should make that change, I'll do so when adding the merkle "write" functionality.

Here is a diagram comparing vm1 vs vm2 ways of doing things (also screenshotted here):
image

Loading
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.

5 participants