diff options
author | Alon Zakai <alonzakai@gmail.com> | 2017-08-05 12:06:22 -0700 |
---|---|---|
committer | Alon Zakai (kripken) <alonzakai@gmail.com> | 2017-08-05 13:46:09 -0700 |
commit | 7231e619004414c33b30f4a3dd55ff85c69e1406 (patch) | |
tree | a9fc848274b1bbf65fb2c931a34b26c2279028d9 /test | |
parent | cc193a49fa612142fdea016ed8fe8a527be7c835 (diff) | |
download | binaryen-7231e619004414c33b30f4a3dd55ff85c69e1406.tar.gz binaryen-7231e619004414c33b30f4a3dd55ff85c69e1406.tar.bz2 binaryen-7231e619004414c33b30f4a3dd55ff85c69e1406.zip |
fix merge-blocks bug with replacing an unreachable block with a concrete final element (which is never reached)
Diffstat (limited to 'test')
-rw-r--r-- | test/passes/remove-unused-names_merge-blocks.txt | 14 | ||||
-rw-r--r-- | test/passes/remove-unused-names_merge-blocks.wast | 14 |
2 files changed, 28 insertions, 0 deletions
diff --git a/test/passes/remove-unused-names_merge-blocks.txt b/test/passes/remove-unused-names_merge-blocks.txt index 7769b1ac8..ff0d8b912 100644 --- a/test/passes/remove-unused-names_merge-blocks.txt +++ b/test/passes/remove-unused-names_merge-blocks.txt @@ -892,4 +892,18 @@ ) ) ) + (func $drop-unreachable-block-with-concrete-final (type $3) + (drop + (block + (drop + (block + (drop + (return) + ) + ) + ) + (i32.const -452) + ) + ) + ) ) diff --git a/test/passes/remove-unused-names_merge-blocks.wast b/test/passes/remove-unused-names_merge-blocks.wast index 1233ef538..2911203d1 100644 --- a/test/passes/remove-unused-names_merge-blocks.wast +++ b/test/passes/remove-unused-names_merge-blocks.wast @@ -1054,4 +1054,18 @@ ) ) ) + (func $drop-unreachable-block-with-concrete-final + (drop + (block + (drop + (block + (drop + (return) + ) + ) + ) + (i32.const -452) + ) + ) + ) ) |