summaryrefslogtreecommitdiff
path: root/test/merge
Commit message (Collapse)AuthorAgeFilesLines
* Delete wasm-merge (#1969)Thomas Lively2019-03-2990-2054/+0
| | | It is not very useful.
* Massive renaming (#1855)Thomas Lively2019-01-0740-254/+254
| | | | | | Automated renaming according to https://github.com/WebAssembly/spec/issues/884#issuecomment-426433329.
* Rename tableBase/memoryBase to __table_base/__memory_base (#1731)Sam Clegg2018-11-0830-139/+188
|
* Emit imports before defined things in text format (#1715)Alon Zakai2018-11-0128-28/+28
| | | | | That is the correct order in the text format, wabt errors otherwise. See AssemblyScript/assemblyscript#310
* Unify imported and non-imported things (#1678)Alon Zakai2018-09-1947-152/+152
| | | | | | | | | | | | | | Fixes #1649 This moves us to a single object for functions, which can be imported or nor, and likewise for globals (as a result, GetGlobals do not need to check if the global is imported or not, etc.). All imported things now inherit from Importable, which has the module and base of the import, and if they are set then it is an import. For convenient iteration, there are a few helpers like ModuleUtils::iterDefinedGlobals(wasm, [&](Global* global) { .. use global .. }); as often iteration only cares about imported or defined (non-imported) things.
* Binary format local parsing fixes (#1664)Alon Zakai2018-09-114-12/+12
| | | | | | * Error if there are more locals than browsers allow (50,000). We usually just warn about stuff like this, but we do need some limit (or else we hang or OOM), and if so, why not use the agreed-upon Web limit. * Do not generate nice string names for locals in binary parsing - the name is just $var$x instead of $x, so not much benefit, and worse as our names are interned this is actually slow (which is why the fuzz testcase here hangs instead of OOMing). Testcases and bugreport in #1663.
* Support constant globals in precompute pass (#1622)Daniel Wirtz2018-07-1814-80/+60
| | | | | | | | | This PR includes non-mutable globals in precompute, which will allow me to continue removing manual inlining of constants in AssemblyScript without breaking something. Related: #1621, i.e. enum Animal { CAT = 0, DOG = CAT + 1 // requires that `Animal.CAT` is evaluated to // precompute the constant value for `Animal.DOG` }
* ensure unique import names for each type, by giving them a prefix, avoiding ↵Alon Zakai2018-02-223-19/+19
| | | | collisions between say a global import and a function with a name from the name section that happens to match it (#1424)
* Optimize out memory and table when possible (#1352)Alon Zakai2018-01-108-16/+0
| | | We can remove the memory/table (itself, or an import if imported) if they are not used. This is pretty minor on a large wasm file, but when reading small wasts it's very noticeable to have an unused memory and table all the time.
* support fixed (non-relocatable) segments in wasm-merge. also a few printing ↵Alon Zakai2017-12-0526-16/+406
| | | | fixes for multiple segments, which we never really printed that prettily (#1316)
* name function imports using name section (#1290)Alon Zakai2017-11-214-4/+4
|
* Update call_indirect text syntax to match spec update (#1281)Derek Schuff2017-11-136-10/+10
| | | | Function type gets its own element rather than being a part of the call_indirect (see WebAssembly/spec#599)
* Emit binary function index in comment in text format, for convenience (#1232)Alon Zakai2017-10-2028-72/+72
|
* Avoid new blocks in binary reading/writing (#1165)Alon Zakai2017-09-124-82/+74
| | | | | | * don't emit a toplevel block if we don't need to, as in wasm it is a list context * don't create unnecessary blocks in wasm reading
* Return to more structured type rules for block and if (#1148)Alon Zakai2017-09-051-1/+1
| | | | | | | | * if a block has a concrete final element (or a break with a value), then even if it has an unreachable child, keep it with that concrete type. this means we no longe allow the silly case of a block with an unreachable in the middle and a concrete as the final element while the block is unreachable - after this change, the block would have the type of the final element * if an if has a concrete element in one arm, make it have that type as a result, even if the if condition is unreachable, to parallel block * make type rules for brs and switches simpler, ignore whether they are reachable or not. whether they are dead code should not affect how they influence other types in our IR.
* Support new result syntax for if/loop/block (#1047)Sam Clegg2017-06-124-16/+16
| | | | | | Support both syntax formats in input since the old spec tests still need to be parsable.
* Optimize/merge duplicate function types (#1041)Alon Zakai2017-06-1212-36/+14
|
* Fix bustage (#975)Alon Zakai2017-04-186-108/+148
| | | | | | * support -g in wasm-opt, which makes it easier to upgrade binaries for bustage * upgrade binaries in test/merge to new names section format
* wasm-merge tool (#919)Alon Zakai2017-04-1780-0/+1641
wasm-merge tool: combines two wasm files into a larger one, handling collisions, and aware of the dynamic linking conventions. it does not do full static linking, but may eventually.