diff options
Diffstat (limited to 'test/passes/code-folding.wast')
-rw-r--r-- | test/passes/code-folding.wast | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/test/passes/code-folding.wast b/test/passes/code-folding.wast index 32a32b28b..2064f2db6 100644 --- a/test/passes/code-folding.wast +++ b/test/passes/code-folding.wast @@ -52,5 +52,67 @@ ) ) ) + (func $break-target-outside-of-return-merged-code + (block $label$A + (if + (unreachable) + (block + (block + (block $label$B + (if + (unreachable) + (br_table $label$A $label$B + (unreachable) + ) + ) + ) + (return) + ) + ) + (block + (block $label$C + (if + (unreachable) + (br_table $label$A $label$C ;; this all looks mergeable, but $label$A is outside + (unreachable) + ) + ) + ) + (return) + ) + ) + ) + ) + (func $break-target-inside-all-good + (block $label$A + (if + (unreachable) + (block + (block + (block $label$B + (if + (unreachable) + (br_table $label$B $label$B + (unreachable) + ) + ) + ) + (return) + ) + ) + (block + (block $label$C + (if + (unreachable) + (br_table $label$C $label$C ;; this all looks mergeable, and is, B ~~ C + (unreachable) + ) + ) + ) + (return) + ) + ) + ) + ) ) |