Skip to content

Have wasm modules export their memory rather than import it. #12315

@sbc100

Description

@sbc100

This was already done for the indirect function table (wasmTable) in #12296 and is a nice win for code size, portability and complexity.

The only reason we couldn't do this before was that JS used to be able to make static allocation and change the memory size and a layout after wasm-ld was run. All that has now been removed the memory layout is now set at wasm-ld time which means that it should be able to create and export the memory to JS.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions