Skip to content

Avoid duplicate root-bound map openings - #195

Merged
BernardLowe merged 1 commit into
mainfrom
agent/materialization-cache-v1
Aug 17, 2026
Merged

Avoid duplicate root-bound map openings#195
BernardLowe merged 1 commit into
mainfrom
agent/materialization-cache-v1

Conversation

@BernardLowe

Copy link
Copy Markdown
Contributor

What

  • Load radix-node slots once per visited map node.
  • Reuse the requested ProveSlot root-bound opening instead of performing an extra slot-0 opening.
  • Add regressions asserting one ProveAtRoot call per visited node.

Why

Gateway proof timing showed that the root-bound opening dominates cold proof generation. The previous path opened each node twice even though the requested slot proof already authenticates the node root.

Soundness

KZG, IPA, and fallback paths remain root-bound and fail closed: every visited node is authenticated by the requested slot opening before traversal continues.

Verification

  • Targeted mapping/radix tests
  • Full go test ./...
  • Full go vet ./...
  • Full go build ./...

@BernardLowe
BernardLowe marked this pull request as ready for review August 17, 2026 08:38
Copilot AI lite review requested due to automatic review settings August 17, 2026 08:38

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@BernardLowe
BernardLowe merged commit 6c55430 into main Aug 17, 2026
7 checks passed
@BernardLowe
BernardLowe deleted the agent/materialization-cache-v1 branch August 17, 2026 08:40
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.

2 participants