-
Notifications
You must be signed in to change notification settings - Fork 277
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
[Feat] Optimize for zktrie state #962
base: develop
Are you sure you want to change the base?
Conversation
TODO: add some basic desc. From my reading, currently it actually fill all (union of old and new storage) need data, then finally in "ApplyFilter" nuke one of them? It may be ok as long as it will not bring too much runtime overhead. ( i guess no, since these fields don't involve extra disk io or poseidon hash?) btw i think on top of this pr, i could just change lines of codes to emit a "union format trace" which include old storage proofs and new storage proofs? (so then old rust codes use it as old trace, new rust codes use it as new trace). Btw i prefer we have 3 mode (old / new / union) to give us more flexiblity for testing https://github.com/scroll-tech/go-ethereum/pull/962/files#r1720773656. "new(or named 'flatten')" be default |
what about set default to 'legacy' now? if not, it is not convenient to merge it now. There are third party chunk provers. Using 'flatten' as default will break a lot. |
done |
This PR has induced (1) preimage of merkle nodes (2) a new "flatten" format in
storageTrace
. It can help circuit to be able to handle l2 trace with less effort (no poseidon hash needed for verifying block's state, to speedup ccc ~15% more).In l2trace API, the default format is the new (flatten) one while there is a new option
StorageProofFormat
can switch to the legacy format:by default, the trace output would not change
if
StorageProofFormat
is"flatten"
, API would output new "flatten" format, likeStorageProofFormat
is"union"
, API would output a "union" format, as a "union" of bot old format and the new "flatten" proof, it is used for debugging