summaryrefslogtreecommitdiff
path: root/test/polymorphic_stack.wast.from-wast
blob: 82f88f4af5759820cd982e94c998b76d844587f6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
(module
 (type $FUNCSIG$ii (func (param i32) (result i32)))
 (type $1 (func (result i32)))
 (type $2 (func (param i32)))
 (type $3 (func))
 (import "env" "table" (table 9 9 anyfunc))
 (memory $0 0)
 (func $break-and-binary (type $1) (result i32)
  (block $x (result i32)
   (f32.add
    (br_if $x
     (i32.trunc_u/f64
      (unreachable)
     )
     (i32.trunc_u/f64
      (unreachable)
     )
    )
    (f32.const 1)
   )
  )
 )
 (func $call-and-unary (type $FUNCSIG$ii) (param $0 i32) (result i32)
  (drop
   (i64.eqz
    (call $call-and-unary
     (unreachable)
    )
   )
  )
  (drop
   (i64.eqz
    (i32.eqz
     (unreachable)
    )
   )
  )
  (drop
   (i64.eqz
    (call_indirect $FUNCSIG$ii
     (unreachable)
     (unreachable)
    )
   )
  )
 )
 (func $tee (type $2) (param $x i32)
  (local $y f32)
  (drop
   (i64.eqz
    (tee_local $x
     (unreachable)
    )
   )
  )
  (drop
   (tee_local $y
    (i64.eqz
     (unreachable)
    )
   )
  )
 )
 (func $tee2 (type $3)
  (local $0 f32)
  (if
   (i32.const 259)
   (tee_local $0
    (unreachable)
   )
  )
 )
 (func $select (type $3)
  (drop
   (i64.eqz
    (select
     (unreachable)
     (i32.const 1)
     (i32.const 2)
    )
   )
  )
 )
 (func $untaken-break-should-have-value (type $1) (result i32)
  (block $x (result i32)
   (block $block
    (br_if $x
     (unreachable)
    )
   )
  )
 )
 (func $unreachable-in-block-but-code-before (type $FUNCSIG$ii) (param $0 i32) (result i32)
  (if
   (get_local $0)
   (return
    (i32.const 127)
   )
  )
  (block $label$0 (result i32)
   (br_if $label$0
    (return
     (i32.const -32)
    )
   )
  )
 )
 (func $br_table_unreachable_to_also_unreachable (type $1) (result i32)
  (block $a (result i32)
   (block $b
    (br_table $a $b
     (unreachable)
     (unreachable)
    )
   )
  )
 )
)