diff options
author | Daniel Wirtz <dcode@dcode.io> | 2019-11-19 19:58:58 +0100 |
---|---|---|
committer | Alon Zakai <azakai@google.com> | 2019-11-19 10:58:58 -0800 |
commit | 00bbde099c0d968ce4ab95eba56d767d534e4094 (patch) | |
tree | 918c58218ebf22ab8cb7195a8af9063620b4d5c5 /src/passes/pass.cpp | |
parent | 365e6f239926e3da640014237b5420895ec247b9 (diff) | |
download | binaryen-00bbde099c0d968ce4ab95eba56d767d534e4094.tar.gz binaryen-00bbde099c0d968ce4ab95eba56d767d534e4094.tar.bz2 binaryen-00bbde099c0d968ce4ab95eba56d767d534e4094.zip |
Add PostAssemblyScript pass (#2407)
Adds the AssemblyScript-specific passes post-assemblyscript
and post-assemblyscript-finalize, eliminating redundant ARC-style
retain/release patterns conservatively emitted by the compiler.
Diffstat (limited to 'src/passes/pass.cpp')
-rw-r--r-- | src/passes/pass.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/passes/pass.cpp b/src/passes/pass.cpp index 0ac70aa59..0f6507d98 100644 --- a/src/passes/pass.cpp +++ b/src/passes/pass.cpp @@ -207,6 +207,12 @@ void PassRegistry::registerPasses() { registerPass("pick-load-signs", "pick load signs based on their uses", createPickLoadSignsPass); + registerPass("post-assemblyscript", + "eliminates redundant ARC patterns in AssemblyScript output", + createPostAssemblyScriptPass); + registerPass("post-assemblyscript-finalize", + "eliminates collapsed ARC patterns after other optimizations", + createPostAssemblyScriptFinalizePass); registerPass("post-emscripten", "miscellaneous optimizations for Emscripten-generated code", createPostEmscriptenPass); |