| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
* Runtime.stackAlloc should grow down for wasm
* stackAlloc should align properly; update tests
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Generate stackSave function in s2wasm
* Generate stackAlloc in s2wasm
* Generate stackRestore in s2wasm
* Update dot_s tests for runtime functions
* Add s2wasm check for exporting runtime functions
* Fix flake8 for s2wasm.py
* Rename wasmBuilder to builder
|
|
|
|
|
|
| |
* Refactor AsmConstWalker to use smaller subfunctions
* Replace cashew::IStrings with Names
|
|
|
|
| |
Most module walkers use PostWalker<T, Visitor<T>>, let that pattern be
expressed as simply PostWalker<T>
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Fully handle EM_ASM in s2wasm
* Iterate with size_ts, remember to erase from importsMap as well
* Fix dot_s test EM_ASM signatures
* Move Name out to its own file, support/name.h
* Move removeImportsWithSubstring out of Module class
|
|
|
|
| |
else (#915)
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Handle importing globals in s2wasm
* Make importedGlobals a set of Names, make Names hashable
* Revert "Make importedGlobals a set of Names, make Names hashable"
This reverts commit 1d0ca7a5e3839b15ca60593330979864c9c3ed60.
* Refactor relocation parsing to handle expressions directly
* PR Feedback
- Move comment where it belongs
- Add comment about ownership to addRelocation
- Remove do-nothing parseImportGlobal
* Reword "imported globals" to "imported objects"
- Flip isObjectImported to isObjectImplemented, for consistency
* Add tests for s2wasm globals.
Also implement import relocation expression handling
* Simplify globals.s test
* Fix memory leak of relocation
* Use unique_ptr instead of delete in getRelocatableExpression
|
| |
|
|
|
|
|
|
|
|
|
|
| |
It's possible to generate an EM_ASM call with empty contents (due to
ifdefs, for example), and this gets converted to an empty string.
AsmConstWalker assumes that by this point any addresses it is pointing
to have a corresponding data section, which is reasonable. However in
the case of an empty string, we don't create a data section, but just
leave that address uninitialized, i.e. set to 0.
In the case of AsmConstWalker, a correct thing to do is to emit the
empty string as metadata, which becomes an empty emscripten_asm_v call.
|
|
* Add a flag to s2wasm to export grow_memory
Binaryen's wasm.js-post.js calls back in to wasm in order to grow the
linear memory, via a function that asm2wasm exports called
__growWasmMemory.
This changes exposes that method through s2wasm when invoked with a
flag.
* Move AsmConstWalker from wasm-linker to wasm-emscripten
* Add test for memory growth in s2wasm
* Move makeDynCallThunks into wasm-emscripten module
* Move mutation in getTableSegment into a separate method
* Move emscripten metadata generation into wasm-emscripten
Also make AsmConstWalker internal to the wasm-emscripten module, as it's only used for the metadata pass.
|