bjorn3 opened PR #6172 from bjorn3:bsc-unwinding-module-serialize2
to bytecodealliance:main
:
This allows a Module implementation to serialize it's internal state and deserialize it in another compilation session. For example to implement LTO or to load the module into cranelift-interpreter.
This is the last PR in the series for now. The actual implementation of a module that can be serialized is in cg_clif. I may extract it in the future, but for now these are almost all the changes that need to be made on the cranelift side. The previous PR's in this series are https://github.com/bytecodealliance/wasmtime/pull/6169 and https://github.com/bytecodealliance/wasmtime/pull/6170.
bjorn3 requested fitzgen for a review on PR #6172.
bjorn3 requested wasmtime-compiler-reviewers for a review on PR #6172.
bjorn3 requested wasmtime-default-reviewers for a review on PR #6172.
bjorn3 updated PR #6172.
bjorn3 submitted PR review.
bjorn3 created PR review comment:
The Deserialize impl is based on serde-derive's macro expansion, but it has been cleaned up a lot and modified to run
get_names
instead of expecting anames
field. This should be license technically, right?
fitzgen requested bnjbvr for a review on PR #6172.
bjorn3 updated PR #6172.
bnjbvr submitted PR review.
bnjbvr submitted PR review.
bnjbvr created PR review comment:
Any chance you can use one of the facilities provided by serde, e.g.
#[serde(serialize_with = ...)]
on thenames
field, instead?
bnjbvr created PR review comment:
nit: can you use
expect
for something a bit shorter here?
bjorn3 submitted PR review.
bjorn3 created PR review comment:
When applied to the names field that doesn't give access to the functions and data_objects fields to reconstruct the names field from from what I can tell.
bjorn3 updated PR #6172.
bjorn3 submitted PR review.
bjorn3 created PR review comment:
Done
bjorn3 updated PR #6172.
bjorn3 updated PR #6172.
bnjbvr submitted PR review:
Lgtm!
bnjbvr merged PR #6172.
Last updated: Dec 23 2024 at 12:05 UTC