Skip to content

Strip component-type* custom sections during componentization#397

Merged
alexcrichton merged 1 commit intobytecodealliance:mainfrom
alexcrichton:strip-sections
Oct 26, 2022
Merged

Strip component-type* custom sections during componentization#397
alexcrichton merged 1 commit intobytecodealliance:mainfrom
alexcrichton:strip-sections

Conversation

@alexcrichton
Copy link
Copy Markdown
Member

This commit leverages a new convenience API in wasmparser to strip the component-type* custom sections emitted by wit-bindgen guests during the componentization process for a core wasm module. These custom sections don't have any place in the core wasm module except as part of the build process and will end up just duplicating bits and pieces of the component itself, so there's no need for them to stick around once a component has been created.

This commit leverages a new convenience API in `wasmparser` to strip the
`component-type*` custom sections emitted by `wit-bindgen` guests during
the componentization process for a core wasm module. These custom
sections don't have any place in the core wasm module except as part of
the build process and will end up just duplicating bits and pieces of
the component itself, so there's no need for them to stick around once a
component has been created.
@alexcrichton alexcrichton requested a review from pchickey October 26, 2022 14:15
@alexcrichton alexcrichton merged commit 6ed55f3 into bytecodealliance:main Oct 26, 2022
@alexcrichton alexcrichton deleted the strip-sections branch October 26, 2022 17:32
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