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

Add miden-package crate with Package type to represent a compiled Miden program/library. #1544

Open
wants to merge 12 commits into
base: next
Choose a base branch
from

Conversation

greenhat
Copy link
Contributor

@greenhat greenhat commented Oct 23, 2024

This PR adds miden-package crate with Package type ported from the compiler's ad-hoc implementation to represent a compiled Miden program/library. Besides this, the deserialization of the LibraryPath was switched to use the unchecked constructors to accommodate the Wasm Component Model names for modules.

Please consider reviewing this PR commit-by-commit. I crafted the commits to be focused on a single change and show the evolution of the implementation.

The reasons for the new crate are explained in 0xPolygonMiden/compiler#346

The compiler's PR that uses miden-package from this PR is 0xPolygonMiden/compiler#349

@greenhat greenhat changed the title Ass miden-package crate with Package type to represent a compiled Miden program/library. Add miden-package crate with Package type to represent a compiled Miden program/library. Oct 23, 2024
@greenhat greenhat force-pushed the greenhat/miden-package branch 4 times, most recently from 76a4b7e to 9ff342e Compare October 30, 2024 09:44
@greenhat greenhat force-pushed the greenhat/miden-package branch from 9ff342e to 7c9b95b Compare October 30, 2024 10:14
@greenhat greenhat changed the base branch from next to greenhat/library-deser-uncheck-exports October 30, 2024 10:15
@greenhat greenhat force-pushed the greenhat/library-deser-uncheck-exports branch from 1ca8581 to 3581727 Compare November 4, 2024 17:37
Base automatically changed from greenhat/library-deser-uncheck-exports to next November 4, 2024 21:37
@greenhat greenhat force-pushed the greenhat/miden-package branch 7 times, most recently from 41b5f5d to c5ff6f0 Compare November 12, 2024 14:07
@greenhat greenhat force-pushed the greenhat/miden-package branch 6 times, most recently from 211f34c to 84ea102 Compare November 19, 2024 08:49
@greenhat greenhat changed the base branch from next to greenhat/i1547-mastforest-add-advicemap November 19, 2024 08:49
@greenhat greenhat changed the title Add miden-package crate with Package type to represent a compiled Miden program/library. [2/2] Add miden-package crate with Package type to represent a compiled Miden program/library. Nov 19, 2024
@greenhat greenhat force-pushed the greenhat/i1547-mastforest-add-advicemap branch from eda4a01 to 006e03a Compare November 19, 2024 14:40
@greenhat greenhat force-pushed the greenhat/miden-package branch 2 times, most recently from 5ec902e to d6419ca Compare November 19, 2024 15:00
@greenhat greenhat force-pushed the greenhat/i1547-mastforest-add-advicemap branch from 006e03a to 92f3309 Compare November 20, 2024 07:05
@greenhat greenhat force-pushed the greenhat/i1547-mastforest-add-advicemap branch 3 times, most recently from 2f8f3fe to 93869ef Compare November 20, 2024 12:41
@greenhat greenhat force-pushed the greenhat/miden-package branch from d6419ca to fe4afa2 Compare November 20, 2024 14:53
Base automatically changed from greenhat/i1547-mastforest-add-advicemap to next November 21, 2024 12:01
@greenhat greenhat changed the title [2/2] Add miden-package crate with Package type to represent a compiled Miden program/library. Add miden-package crate with Package type to represent a compiled Miden program/library. Nov 25, 2024
@greenhat greenhat force-pushed the greenhat/miden-package branch from 75bd636 to 3b9b31d Compare November 25, 2024 14:47
@greenhat greenhat force-pushed the greenhat/miden-package branch from 3b9b31d to 280d338 Compare December 18, 2024 07:50
@greenhat greenhat force-pushed the greenhat/miden-package branch from 1ce2c26 to 9886dc6 Compare December 20, 2024 15:01
add test for deserializing rustc mangled symbols.
…compiler

Reasons:
- The `Package` serialization proptests and testing `LibraryPath`,
`ProcedureName` with example names produced by the compiler are enough;
- The test is fragile and brakes on any change to `Package` underlying
  types serialization. Updating the `masp` file is non-trivial;
@greenhat greenhat force-pushed the greenhat/miden-package branch from 9886dc6 to b1354c1 Compare December 20, 2024 15:22
@greenhat greenhat marked this pull request as ready for review December 20, 2024 16:15
@greenhat greenhat force-pushed the greenhat/miden-package branch from 514b7fc to ebc8311 Compare December 20, 2024 16:25
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.

1 participant