Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Generate memory and table imports/exports in web assembly

The default code generation for compiling with LLVM/Clang to WebAssembly exports memory and ignores tables completely.

Is there a way to emit memory and table imports (and/or exports) when targeting web assembly with clang (--target=wasm32-unknown-unknown-wasm)?

like image 510
Casper Beyer Avatar asked Nov 08 '22 18:11

Casper Beyer


1 Answers

LLD with -flavor wasm has been rolled back into upstream LLVM which does give the ability to decide wether memory and function tables should be imported or exported.

like image 123
Casper Beyer Avatar answered Nov 29 '22 05:11

Casper Beyer