summaryrefslogtreecommitdiff
path: root/test
Commit message (Collapse)AuthorAgeFilesLines
* merge adjacent br_ifsAlon Zakai2016-10-272-0/+117
|
* recreate simply ifsAlon Zakai2016-10-278-351/+442
|
* recurse in optimizeBoolean (#809)Alon Zakai2016-10-274-12/+40
|
* Set the type of the implicit blocks we use for a loop body in s2wasm (#810)jgravelle-google2016-10-272-0/+21
| | | | | | | Loops are modeled in Binaryen IR as having a Block as a body. The block is added to module walkers and validated like a normal block. In s2wasm when we add the blocks, we need to make sure that the type of the loop body matches the type of the loop itself, or we run into issues.
* optimize ne of 0 in a boolean context (#808)Alon Zakai2016-10-278-68/+47
|
* Code pushing (#807)Alon Zakai2016-10-268-2194/+2753
| | | Push code forward, potentially letting it not execute
* Conditionalize boolean operations based on cost (#805)Alon Zakai2016-10-262-0/+523
| | | When we have expensive | expensive, and both are boolean, then we can execute one of them conditionally if it doesn't have side effects.
* Optimize out bool & 1 (#804)Alon Zakai2016-10-2514-201/+290
| | | | | | * asm.js corrections to unit.asm.js test * optimize out bool&1
* Update s2wasm for reordered call_indirect (#802)jgravelle-google2016-10-2481-5477/+6863
| | | | | | | | | | | | | | | * Update s2wasm for reordered call_indirect https://reviews.llvm.org/D25708 fixed call_indirect for 0xc by reordering the operands. s2wasm needs to be aware of that too. * Update llvm_autogenerated tests * Update torture-s tests * run auto_update_tests * update handwritten dot_s test that had call_indirect with args
* Adds a pass to print call graphs in .dot (graphviz) format. (#794)Michael Bebenita2016-10-202-0/+2910
|
* Add priority to copies on backedges (#791)Alon Zakai2016-10-208-7652/+7760
| | | | | | | | * add a coalesce-locals test for costly backedges * add script to strip local names out, for convenient diffing * prioritize backedge copies
* Optimize to i64.store[less] (#792)Alon Zakai2016-10-202-0/+16
|
* Add support for i64.store[N] (#789)jgravelle-google2016-10-192-0/+26
| | | | | | | | | | | | * Add support for i64.store[N] Previously storing i64 in the interpreter assumed an 8byte store. Stores like i64.store8 would then use the special-case i64 storing code, when they could just use the i32.store8 code. * Add printf test for interpreter * Update wasm.js
* Pass options (#788)Alon Zakai2016-10-184-18/+57
| | | | * add PassOptions structure, and use it for new -Os param to wasm-opt
* add table and memory contents to metrics (#787)Alon Zakai2016-10-182-0/+18
|
* reorder locals after simplify-locals, to remove unused locals before ↵Alon Zakai2016-10-166-7468/+7386
| | | | coalesce-locals, making it much faster (#783)
* optimize out i32.and of -1Alon Zakai2016-10-155-145/+97
|
* optimize loads and stores that mask their values, as the load/store ↵Alon Zakai2016-10-154-378/+314
| | | | operation masks itself
* Merge pull request #778 from WebAssembly/passeAlon Zakai2016-10-1425-1877/+354
|\ | | | | Add remove-unused-functions to default passes
| * run remove-unused-functions by defaultAlon Zakai2016-10-1425-1877/+354
| |
* | Import memory instead of defining/exporting it when using emscripten glue (#777)Derek Schuff2016-10-1483-166/+83
|/ | | | | The emscripten JS module code creates the memory using the native wasm APIs, and imports that into the wasm module.
* Do not use exported memory as a root set of RemoveUnusedFunctions pass (#763)Taiju Tsuiki2016-10-142-0/+2
| | | | | | | | * Do not use exported memory as a root set of RemoveUnusedFunctions pass RemoveUnusedFunctions pass of wasm-opt fails when the memory is exported. That's due to a wrong root set handling on the exported symbols. This CL fixes the failure by ignoring non-function exported symbol.
* Merge pull request #775 from WebAssembly/sl-fixAlon Zakai2016-10-132-27/+97
|\ | | | | Fix simplify-locals when adding a value to a br_if
| * when simplify-locals give br_if a value, the br_if also returns it, so it ↵Alon Zakai2016-10-132-27/+97
| | | | | | | | must be dropped
* | handle globals in dceAlon Zakai2016-10-132-0/+10
|/
* Don't create a memory section for an imported memory; fixes #772 (#773)Benjamin Bouvier2016-10-133-0/+29
|
* update spec tests, now using binary-0xc branch as our stack test refactoring ↵Alon Zakai2016-10-121-0/+0
| | | | landed in upstream (#754)
* handle unreachable tee_local properly in coalesce-locals (#761)Alon Zakai2016-10-122-0/+20
|
* fix bug where we set memory max to the initial value if the max wasn't ↵Alon Zakai2016-10-129-0/+36
| | | | specified (#760)
* remove memory maximum in asm2wasm when memory growth is onAlon Zakai2016-10-114-4/+4
|
* if we see no asm.js function tables, the table size is 0Alon Zakai2016-10-1124-24/+24
|
* allow a maximum 0 size for a tableAlon Zakai2016-10-113-0/+14
|
* Don't create table sections for imported tables (#756)Derek Schuff2016-10-113-0/+29
| | | Previously the Print pass searched the imports for a table import and skipped printing a local table declaration if found. Instead this refactors to make importation explicit, and also create importation records (previously we were inconsistent about whether such records were created in the IR depending on the wast syntax).
* track unreachable code in coalesce-locals, we know what is unreachable ↵Alon Zakai2016-10-083-28/+86
| | | | anyhow, and it just adds overhead to not ignore it
* Change print order of top-level module components (#751)Derek Schuff2016-10-07152-676/+602
| | | | | | | | In wast files, the spec and WABT require imports to appear before any non-import definitions (see also https://github.com/WebAssembly/wabt/issues/152). This patch re-orders visitModule in the wast printer to meet this requirement, and more or less match the order of the binary sections. Also remove extraneous whitespace around table definitions.
* Require unique names in binaryen IR (#746)Alon Zakai2016-10-0627-3674/+3670
|
* Dot s block signatures (#747)jgravelle-google2016-10-061254-4217/+4420
| | | | | | | | | | * Support block signatures in s2wasm's .s format * Autogenerate tests * update cfg-stackify tests * Remove conflict files
* Update for removal of loop's bottom label from LLVM (#750)Derek Schuff2016-10-061249-5418/+5651
| | | | Corresponds to LLVM change https://reviews.llvm.org/D25122, r283502
* Update s2wasm for removal of store results (#749)Derek Schuff2016-10-061298-11549/+12279
| | | | Corresponds to LLVM change https://reviews.llvm.org/D25122
* Remove hard-coded paths from LLVM test auto-generator (#748)Derek Schuff2016-10-061-6/+11
| | | | Use the command-line instead. Also update the blacklist to handle new tests.
* DCE bugfix (#736)Alon Zakai2016-10-044-0/+94
| | | | | * fix a dce bug where it is invalid to truncate a block if it leaves a final element with a bad type (wasm doesn't always allow removing unreachable code) * add wast pass fuzzer
* handle ifs with an i64 condition #741 (#742)Alon Zakai2016-10-044-4/+12
|
* Update i64 stores for 0xc (#731)jgravelle-google2016-10-046-9/+26
| | | | | | | | | | * Update i64 stores for 0xc * Update autogenerated LLVM tests * Update known torture test failures * Add i64.store32 test to unit.wast
* don't create an unnecessary duplicate block in asm2wasm switches, when there ↵Alon Zakai2016-10-038-9876/+9836
| | | | isn't a default (#734)
* wasm-only additions: i32.cttz, copysign, popcnt (#729)Alon Zakai2016-10-025-1/+88
|
* fix vacuum big where we changed an unreachable node to a nop (#728)Alon Zakai2016-10-022-0/+19
|
* More wasm-only opts (#727)Alon Zakai2016-10-025-34/+757
| | | | | | * wasm-only loads and stores * wasm-only 32-bit bitcasts
* asm2wasm i64 support (#723)Alon Zakai2016-09-3010-0/+1960
| | | | | | | | | | | | * support i64 intrinsics from fastcomp, adding --wasm-only flag * refactor callImport logic in asm2wasm to avoid recomputing wasm types again * legalize illegal i64 params in exports and imports * do safe i64 binary ops depending on precision * fix addVar, only assert on names if we are using a name
* Make the linker always create a table segment (#722)Derek Schuff2016-09-3071-3/+141
| | | | | | | Previously a table was only created if there were any address-taken functions. New module validation rules require the existence of a table for any call-indirects to validate (even if they are dead and never called). However this use case seems common enough that we might want to make it continue to work. So the linker now always creates an empty table segment (indicating an empty table).
* validate drop (#712)Alon Zakai2016-09-302-10/+12
|