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 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243
|
(module
(type $0 (func))
(memory $8 256 256)
(data (i32.const 1024) "hello, world!\n\00\00\9c\0c\00\00-+ 0X0x\00(null)\00\00\00\00\00\00\00\00\00\00\00\00\11\00\n\00\11\11\11\00\00\00\00\05\00\00\00\00\00\00\t\00\00\00\00\0b\00\00\00\00\00\00\00\00\11\00\0f\n\11\11\11\03\n\07\00\01\13\t\0b\0b\00\00\t\06\0b\00\00\0b\00\06\11\00\00\00\11\11\11\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\0b\00\00\00\00\00\00\00\00\11\00\n\n\11\11\11\00\n\00\00\02\00\t\0b\00\00\00\t\00\0b\00\00\0b\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\0c\00\00\00\00\00\00\00\00\00\00\00\0c\00\00\00\00\0c\00\00\00\00\t\0c\00\00\00\00\00\0c\00\00\0c\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\0e\00\00\00\00\00\00\00\00\00\00\00\0d\00\00\00\04\0d\00\00\00\00\t\0e\00\00\00\00\00\0e\00\00\0e\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\10\00\00\00\00\00\00\00\00\00\00\00\0f\00\00\00\00\0f\00\00\00\00\t\10\00\00\00\00\00\10\00\00\10\00\00\12\00\00\00\12\12\12\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\12\00\00\00\12\12\12\00\00\00\00\00\00\t\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\0b\00\00\00\00\00\00\00\00\00\00\00\n\00\00\00\00\n\00\00\00\00\t\0b\00\00\00\00\00\0b\00\00\0b\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\0c\00\00\00\00\00\00\00\00\00\00\00\0c\00\00\00\00\0c\00\00\00\00\t\0c\00\00\00\00\00\0c\00\00\0c\00\000123456789ABCDEF-0X+0X 0X-0x+0x 0x\00inf\00INF\00nan\00NAN\00.\00")
(data (i32.const 1600) "\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00")
(import "env" "table" (table $timport$9 7 funcref))
(elem (i32.const 1) $foo $bar $tabled)
(import "env" "__syscall6" (func $syscall$6 (param i32 i32) (result i32)))
(import "env" "__syscall54" (func $syscall$54 (param i32 i32) (result i32)))
(global $global$0 (mut i32) (i32.const 5243904))
(export "main" (func $main))
(export "other" (func $other))
(export "__growWasmMemory" (func $__growWasmMemory))
(export "exported" (func $exported))
(export "sub-zero" (func $sub-zero))
(export "select" (func $select))
(export "bools" (func $bools))
(func $main
(drop (call $syscall$6 (i32.const 1) (i32.const 2)))
(drop (call $syscall$54 (i32.const 3) (i32.const 4)))
(call_indirect (type $0)
(i32.load offset=1030
(i32.const 0)
)
)
(drop (call $internal (i32.const 1)))
(drop (call $tabled (i32.const 1)))
(drop (call $exported (i32.const 1)))
)
(func $other
(call $main)
)
(func $foo
(unreachable)
)
(func $bar
(drop
(i32.load8_u
(i32.const 128)
)
)
(drop
(i32.load8_s
(i32.const 128)
)
)
(drop
(i32.load16_u
(i32.const 128)
)
)
(drop
(i32.load16_s
(i32.const 128)
)
)
(i32.store
(i32.const 16)
(i32.add (i32.const 1) (i32.const 2))
)
(f32.store
(i32.const 16)
(f32.add (f32.const 3) (f32.const 4))
)
(f64.store
(i32.const 16)
(f64.add (f64.const 5) (f64.const 6))
)
(i32.store8
(i32.const 16)
(i32.add (i32.const 7) (i32.const 8))
)
(i32.store16
(i32.const 16)
(i32.add (i32.const 9) (i32.const 10))
)
(if (i32.eq (i32.load (i32.const 100)) (i32.const 1))
(call $bar)
)
(if (i32.lt_s (i32.load (i32.const 104)) (i32.const 2))
(call $bar)
)
(if (i32.lt_u (i32.load (i32.const 108)) (i32.const 3))
(call $bar)
)
(if (i32.eq (i32.load16_s (i32.const 112)) (i32.const 1))
(call $bar)
)
(if (i32.lt_s (i32.load16_s (i32.const 116)) (i32.const 2))
(call $bar)
)
(if (i32.lt_s (i32.load16_u (i32.const 120)) (i32.const 2))
(call $bar)
)
(if (i32.lt_u (i32.load16_s (i32.const 124)) (i32.const 3))
(call $bar)
)
(if (i32.lt_u (i32.load16_u (i32.const 128)) (i32.const 3))
(call $bar)
)
(if (i32.lt_s (i32.load8_s (i32.const 132)) (i32.const 2))
(call $bar)
)
(if (i32.lt_s (i32.load8_u (i32.const 136)) (i32.const 2))
(call $bar)
)
(if (i32.lt_u (i32.load8_s (i32.const 140)) (i32.const 3))
(call $bar)
)
(if (i32.lt_u (i32.load8_u (i32.const 144)) (i32.const 3))
(call $bar)
)
(if (i32.shr_u (call $bools (i32.const 314159)) (i32.const 7))
(call $bar)
)
(if (i32.shr_s (call $bools (i32.const 314159)) (i32.const 8))
(call $bar)
)
(if (i32.trunc_f32_u (call $getf32))
(call $bar)
)
(if (i32.trunc_f32_s (call $getf32))
(call $bar)
)
(if (i32.trunc_f64_u (call $getf64))
(call $bar)
)
(if (i32.trunc_f64_s (call $getf64))
(call $bar)
)
(if
(i32.add
(i32.add
(call $geti32)
(call $geti32)
)
(call $geti32)
)
(call $bar)
)
(if
(i32.add
(call $geti32)
(i32.add
(call $geti32)
(call $geti32)
)
)
(call $bar)
)
(if
(i32.add
(i32.add
(call $geti32)
(call $geti32)
)
(i32.add
(call $geti32)
(call $geti32)
)
)
(call $bar)
)
(if
(i32.add
(i32.add
(i32.add
(call $geti32)
(call $geti32)
)
(i32.add
(call $geti32)
(call $geti32)
)
)
(i32.add
(i32.add
(call $geti32)
(call $geti32)
)
(i32.add
(call $geti32)
(call $geti32)
)
)
)
(call $bar)
)
)
(func $geti32 (result i32)
(call $geti32)
)
(func $getf32 (result f32)
(call $getf32)
)
(func $getf64 (result f64)
(call $getf64)
)
(func $__growWasmMemory (param $0 i32) (result i32)
(memory.grow
(local.get $0)
)
)
(func $internal (param $x i32) (result i32)
(local.get $x)
)
(func $tabled (param $x i32) (result i32)
(local.get $x)
)
(func $exported (param $x i32) (result i32)
(local.get $x)
)
(func $sub-zero (param $x i32) (result i32)
(i32.sub (local.get $x) (i32.const -5))
)
(func $select (param $x i32) (result i32)
(select
(local.get $x)
(i32.load (i32.const 16)) ;; we can ignore this implicit trap, no side effects
(local.get $x)
)
)
(func $bools (param $x i32) (result i32)
(drop (call $bools (i32.and (i32.load8_u (i32.const 0)) (i32.const 1))))
(drop (call $bools (i32.and (i32.load8_s (i32.const 0)) (i32.const 1))))
(drop (call $bools (i32.and (i32.load16_u (i32.const 0)) (i32.const 1))))
(drop (call $bools (i32.and (i32.load16_s (i32.const 0)) (i32.const 1))))
(drop (call $bools (i32.and (i32.load (i32.const 0)) (i32.const 1))))
(drop (call $bools (i32.and (i32.load8_u (i32.const 0)) (i32.const 2))))
(drop (call $bools (i32.xor (local.get $x) (i32.const 1))))
(if
(i32.xor (local.get $x) (i32.const 1))
(drop (call $bools (i32.const 2)))
)
(if
(i32.xor (local.get $x) (i32.const 2))
(drop (call $bools (i32.const 2)))
)
(drop (call $bools (i32.eqz (i32.xor (local.get $x) (i32.const 1)))))
(unreachable)
)
)
|