diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/passes/untee.txt | 48 | ||||
-rw-r--r-- | test/passes/untee.wast | 12 |
2 files changed, 60 insertions, 0 deletions
diff --git a/test/passes/untee.txt b/test/passes/untee.txt new file mode 100644 index 000000000..f174da801 --- /dev/null +++ b/test/passes/untee.txt @@ -0,0 +1,48 @@ +(module + (type $0 (func)) + (memory $0 0) + (func $tee (type $0) + (local $x i32) + (local $y f64) + (drop + (block (result i32) + (set_local $x + (i32.const 1) + ) + (get_local $x) + ) + ) + (drop + (block (result f64) + (set_local $y + (f64.const 2) + ) + (get_local $y) + ) + ) + (set_local $x + (block (result i32) + (set_local $x + (i32.const 3) + ) + (get_local $x) + ) + ) + (set_local $x + (block (result i32) + (set_local $x + (block (result i32) + (set_local $x + (i32.const 3) + ) + (get_local $x) + ) + ) + (get_local $x) + ) + ) + (drop + (unreachable) + ) + ) +) diff --git a/test/passes/untee.wast b/test/passes/untee.wast new file mode 100644 index 000000000..5a16a1c71 --- /dev/null +++ b/test/passes/untee.wast @@ -0,0 +1,12 @@ +(module + (func $tee + (local $x i32) + (local $y f64) + (drop (tee_local $x (i32.const 1))) + (drop (tee_local $y (f64.const 2))) + (set_local $x (tee_local $x (i32.const 3))) + (set_local $x (tee_local $x (tee_local $x (i32.const 3)))) + (drop (tee_local $x (unreachable))) + ) +) + |