summaryrefslogtreecommitdiff
path: root/src/passes/ReorderFunctions.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Simpify PassRunner.add() and automatically parallelize parallel functions ↵Alon Zakai2019-07-191-6/+1
| | | | | | | | | (#2242) Main change here is in pass.h, everything else is changes to work with the new API. The add("name") remains as before, while the weird variadic add(..) which constructed the pass now just gets a std::unique_ptr of a pass. This also makes the memory management internally fully automatic. And it makes it trivial to parallelize WalkerPass::run on parallel passes. As a benefit, this allows removing a lot of code since in many cases there is no need to create a new pass runner, and running a pass can be just a single line.
* Apply format changes from #2048 (#2059)Alon Zakai2019-04-261-20/+18
| | | Mass change to apply clang-format to everything. We are applying this in a PR by me so the (git) blame is all mine ;) but @aheejin did all the work to get clang-format set up and all the manual work to tidy up some things to make the output nicer in #2048
* Global optimization fixes (#1360)Alon Zakai2018-01-171-11/+45
| | | | | | | | | | | | | | | | * run dfe at the very end, as it may be more effective after inlining * optimize reorder-functions * do a final dfe in asm2wasm after all other opts * make inlining deterministic: std::atomic<T> values are not zero-initialized * do global post opts at the end of asm2wasm, and don't also do them in the module builder * fix function type removing * don't inline+optimize when preserving debug info
* Default Walker subclasses to using Visitor<SubType> (#921)jgravelle-google2017-02-231-1/+1
| | | | Most module walkers use PostWalker<T, Visitor<T>>, let that pattern be expressed as simply PostWalker<T>
* offset support in tableAlon Zakai2016-08-151-2/+4
|
* Add initialization functions for passes to avoid missing pass registration ↵Jukka Jylänki2016-06-211-1/+3
| | | | due to linker dead code elimination. Fixes #577.
* Pass sort comparison function arguments by const-reference (#472)Derek Schuff2016-05-111-3/+3
| | | Fixes build failure with libstdc++ 4.8
* Add a pass to order functions by their use frequency. (#452)Michael Bebenita2016-05-111-0/+62