diff options
author | Max Graey <maxgraey@gmail.com> | 2020-11-10 21:41:22 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-10 11:41:22 -0800 |
commit | 0c20d9f427b63a6fdc354bb917c11f382068eaec (patch) | |
tree | 750a49a311872f566d6c5b91a29d19d5f2a2e3c1 /test/passes/converge_O3_metrics.bin.txt | |
parent | 5d2c13f16af2183a5d1861828e512fe0f964990c (diff) | |
download | binaryen-0c20d9f427b63a6fdc354bb917c11f382068eaec.tar.gz binaryen-0c20d9f427b63a6fdc354bb917c11f382068eaec.tar.bz2 binaryen-0c20d9f427b63a6fdc354bb917c11f382068eaec.zip |
Canonicalize subtraction with constant on the right to addition (#3321)
Using addition in more places is better for gzip, and helps simplify the
optimizer as well.
Add a FinalOptimizer phase to do optimizations like our signed LEB tweaks, to
reduce binary size in the rare case when we do want a subtraction.
Diffstat (limited to 'test/passes/converge_O3_metrics.bin.txt')
-rw-r--r-- | test/passes/converge_O3_metrics.bin.txt | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/test/passes/converge_O3_metrics.bin.txt b/test/passes/converge_O3_metrics.bin.txt index fe69552fc..bb68dd500 100644 --- a/test/passes/converge_O3_metrics.bin.txt +++ b/test/passes/converge_O3_metrics.bin.txt @@ -85,11 +85,11 @@ total (i32.load offset=24 (i32.add (i32.load - (i32.add + (i32.sub (i32.load (i32.const 18100) ) - (i32.const -12) + (i32.const 12) ) ) (i32.const 18100) @@ -163,11 +163,11 @@ total (i32.load (i32.add (i32.load - (i32.add + (i32.sub (i32.load (i32.const 18100) ) - (i32.const -12) + (i32.const 12) ) ) (i32.const 18124) @@ -326,11 +326,11 @@ total (i32.load offset=24 (i32.add (i32.load - (i32.add + (i32.sub (i32.load (i32.const 18100) ) - (i32.const -12) + (i32.const 12) ) ) (i32.const 18100) @@ -404,11 +404,11 @@ total (i32.load (i32.add (i32.load - (i32.add + (i32.sub (i32.load (i32.const 18100) ) - (i32.const -12) + (i32.const 12) ) ) (i32.const 18124) |