WebAssembly / WebAssembly/tool-conventions
Linking.md: Use multiple data and code sections
Nobody has claimed this yet.
- Dominant language
- WebAssembly
- Stars
- 372
- Forks
- 75
- PR merge metrics
- No merged PRs in 30d
Description
I'd like to propose that we move towards using multple data and code sections in the object format.
This matches llvm's internal ideas about what a section is. Today if you iterate through section in an object you will only see a single code section, even though we default -ffunction-section. This mean the linker is forced then break down the monolithic code and section sections in sub-sections.
There are bugs popping up due to the fact that we dont currently map llvm's concept of a section onto a wasm section: https://reviews.llvm.org/D74531
There is a wasm proposal out of make repeated sections a valid thing: https://github.com/WebAssembly/conditional-sections.
The fact that we can currently validate wasm object files with tools like wasm-validate is feature I don't want to loose, so such tools would need to learn about conditional sections (at at least the multi-section part of it) before we would want to enable this by default.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading Linking.md and compare its object-format section model with LLVM's section concepts and the conditional-sections proposal. Check how wasm-validate currently handles object files. Done means the convention clearly supports multiple data and code sections while validation remains supported, with the relevant tool changes identified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- wasm
- Domain
- compilers
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100