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

Replace wasmer 0,17 code serialization and deserialization with borsh #3724

Closed
ailisp opened this issue Dec 10, 2020 · 3 comments
Closed

Replace wasmer 0,17 code serialization and deserialization with borsh #3724

ailisp opened this issue Dec 10, 2020 · 3 comments
Assignees
Labels
A-contract-runtime Area: contract compilation and execution, virtual machines, etc T-contract-runtime Team: issues relevant to the contract runtime team

Comments

@ailisp
Copy link
Member

ailisp commented Dec 10, 2020

Discovered by @evgenykuzyakov:

Wasmer 0.17.1 uses serde_bench for artifact serialization. Except it’s mostly not supported: https://github.com/serde-rs/benchI wonder if it’s performant enough to serialize large contracts, e.g. 1Mb
Based on description it seems the format is similar to bincode and according to borsh benchmarks for large objects, it loses substantially to borsh: https://borsh.io/

wasmer 0.17 we maintain our own fork: https://github.com/near/wasmer/tree/0.17.2. so we can replace the code serialization with borsh

@ailisp ailisp closed this as completed Dec 19, 2020
@ailisp ailisp self-assigned this Dec 19, 2020
@ailisp ailisp reopened this Dec 19, 2020
@bowenwang1996 bowenwang1996 added A-contract-runtime Area: contract compilation and execution, virtual machines, etc T-contract-runtime Team: issues relevant to the contract runtime team labels Jun 29, 2021
@bowenwang1996
Copy link
Collaborator

@ailisp what is the status of this issue?

@ailisp
Copy link
Member Author

ailisp commented Jul 1, 2021

@bowenwang1996 mostly finished but haven't merge, I'm doing a rebase and test it again to merge & release a new wasmer-near: #4448

@matklad
Copy link
Contributor

matklad commented Jul 30, 2021

Fixed by @ailisp !

@matklad matklad closed this as completed Jul 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-contract-runtime Area: contract compilation and execution, virtual machines, etc T-contract-runtime Team: issues relevant to the contract runtime team
Projects
None yet
Development

No branches or pull requests

3 participants