v8/test/mjsunit/wasm/bulk-memory-spec/table_init.wast
Ben Smith 3c7bc08aec [wasm][bulk-memory] Add bulk memory spec tests
These are added as mjsunit tests for now since they haven't been merged
to the spec repo. When that happens, the wasm-spec-tests testsuite can
be updated to include these tests, and the tests in this directory can
be removed.

This CL also adds the test/mjsunit/wasm/bulk-memory-spec directory to a
list of directories that aren't checked for copyright (since these files
are auto-generated).

Bug: v8:7747
Change-Id: I906f2ca45f497a6728f94afb9b3330971e1d3fd5
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1600363
Commit-Queue: Ben Smith <binji@chromium.org>
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Sergiy Belozorov <sergiyb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#61395}
2019-05-10 01:40:42 +00:00

1603 lines
67 KiB
Plaintext

;;
;; Generated by ../meta/generate_table_init.js
;;
(module
(func (export "ef0") (result i32) (i32.const 0))
(func (export "ef1") (result i32) (i32.const 1))
(func (export "ef2") (result i32) (i32.const 2))
(func (export "ef3") (result i32) (i32.const 3))
(func (export "ef4") (result i32) (i32.const 4))
)
(register "a")
(module
(type (func (result i32))) ;; type #0
(import "a" "ef0" (func (result i32))) ;; index 0
(import "a" "ef1" (func (result i32)))
(import "a" "ef2" (func (result i32)))
(import "a" "ef3" (func (result i32)))
(import "a" "ef4" (func (result i32))) ;; index 4
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 5)) ;; index 5
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9)) ;; index 9
(func (export "test")
(table.init 1 (i32.const 7) (i32.const 0) (i32.const 4)))
(func (export "check") (param i32) (result i32)
(call_indirect (type 0) (local.get 0)))
)
(invoke "test")
(assert_trap (invoke "check" (i32.const 0)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 1)) "uninitialized element")
(assert_return (invoke "check" (i32.const 2)) (i32.const 3))
(assert_return (invoke "check" (i32.const 3)) (i32.const 1))
(assert_return (invoke "check" (i32.const 4)) (i32.const 4))
(assert_return (invoke "check" (i32.const 5)) (i32.const 1))
(assert_trap (invoke "check" (i32.const 6)) "uninitialized element")
(assert_return (invoke "check" (i32.const 7)) (i32.const 2))
(assert_return (invoke "check" (i32.const 8)) (i32.const 7))
(assert_return (invoke "check" (i32.const 9)) (i32.const 1))
(assert_return (invoke "check" (i32.const 10)) (i32.const 8))
(assert_trap (invoke "check" (i32.const 11)) "uninitialized element")
(assert_return (invoke "check" (i32.const 12)) (i32.const 7))
(assert_return (invoke "check" (i32.const 13)) (i32.const 5))
(assert_return (invoke "check" (i32.const 14)) (i32.const 2))
(assert_return (invoke "check" (i32.const 15)) (i32.const 3))
(assert_return (invoke "check" (i32.const 16)) (i32.const 6))
(assert_trap (invoke "check" (i32.const 17)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 18)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 19)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 20)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 21)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 22)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 23)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 24)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 25)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 26)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 27)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 28)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 29)) "uninitialized element")
(module
(type (func (result i32))) ;; type #0
(import "a" "ef0" (func (result i32))) ;; index 0
(import "a" "ef1" (func (result i32)))
(import "a" "ef2" (func (result i32)))
(import "a" "ef3" (func (result i32)))
(import "a" "ef4" (func (result i32))) ;; index 4
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 5)) ;; index 5
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9)) ;; index 9
(func (export "test")
(table.init 3 (i32.const 15) (i32.const 1) (i32.const 3)))
(func (export "check") (param i32) (result i32)
(call_indirect (type 0) (local.get 0)))
)
(invoke "test")
(assert_trap (invoke "check" (i32.const 0)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 1)) "uninitialized element")
(assert_return (invoke "check" (i32.const 2)) (i32.const 3))
(assert_return (invoke "check" (i32.const 3)) (i32.const 1))
(assert_return (invoke "check" (i32.const 4)) (i32.const 4))
(assert_return (invoke "check" (i32.const 5)) (i32.const 1))
(assert_trap (invoke "check" (i32.const 6)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 7)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 8)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 9)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 10)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 11)) "uninitialized element")
(assert_return (invoke "check" (i32.const 12)) (i32.const 7))
(assert_return (invoke "check" (i32.const 13)) (i32.const 5))
(assert_return (invoke "check" (i32.const 14)) (i32.const 2))
(assert_return (invoke "check" (i32.const 15)) (i32.const 9))
(assert_return (invoke "check" (i32.const 16)) (i32.const 2))
(assert_return (invoke "check" (i32.const 17)) (i32.const 7))
(assert_trap (invoke "check" (i32.const 18)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 19)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 20)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 21)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 22)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 23)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 24)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 25)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 26)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 27)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 28)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 29)) "uninitialized element")
(module
(type (func (result i32))) ;; type #0
(import "a" "ef0" (func (result i32))) ;; index 0
(import "a" "ef1" (func (result i32)))
(import "a" "ef2" (func (result i32)))
(import "a" "ef3" (func (result i32)))
(import "a" "ef4" (func (result i32))) ;; index 4
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 5)) ;; index 5
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9)) ;; index 9
(func (export "test")
(table.init 1 (i32.const 7) (i32.const 0) (i32.const 4))
(elem.drop 1)
(table.init 3 (i32.const 15) (i32.const 1) (i32.const 3))
(elem.drop 3)
(table.copy (i32.const 20) (i32.const 15) (i32.const 5))
(table.copy (i32.const 21) (i32.const 29) (i32.const 1))
(table.copy (i32.const 24) (i32.const 10) (i32.const 1))
(table.copy (i32.const 13) (i32.const 11) (i32.const 4))
(table.copy (i32.const 19) (i32.const 20) (i32.const 5)))
(func (export "check") (param i32) (result i32)
(call_indirect (type 0) (local.get 0)))
)
(invoke "test")
(assert_trap (invoke "check" (i32.const 0)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 1)) "uninitialized element")
(assert_return (invoke "check" (i32.const 2)) (i32.const 3))
(assert_return (invoke "check" (i32.const 3)) (i32.const 1))
(assert_return (invoke "check" (i32.const 4)) (i32.const 4))
(assert_return (invoke "check" (i32.const 5)) (i32.const 1))
(assert_trap (invoke "check" (i32.const 6)) "uninitialized element")
(assert_return (invoke "check" (i32.const 7)) (i32.const 2))
(assert_return (invoke "check" (i32.const 8)) (i32.const 7))
(assert_return (invoke "check" (i32.const 9)) (i32.const 1))
(assert_return (invoke "check" (i32.const 10)) (i32.const 8))
(assert_trap (invoke "check" (i32.const 11)) "uninitialized element")
(assert_return (invoke "check" (i32.const 12)) (i32.const 7))
(assert_trap (invoke "check" (i32.const 13)) "uninitialized element")
(assert_return (invoke "check" (i32.const 14)) (i32.const 7))
(assert_return (invoke "check" (i32.const 15)) (i32.const 5))
(assert_return (invoke "check" (i32.const 16)) (i32.const 2))
(assert_return (invoke "check" (i32.const 17)) (i32.const 7))
(assert_trap (invoke "check" (i32.const 18)) "uninitialized element")
(assert_return (invoke "check" (i32.const 19)) (i32.const 9))
(assert_trap (invoke "check" (i32.const 20)) "uninitialized element")
(assert_return (invoke "check" (i32.const 21)) (i32.const 7))
(assert_trap (invoke "check" (i32.const 22)) "uninitialized element")
(assert_return (invoke "check" (i32.const 23)) (i32.const 8))
(assert_return (invoke "check" (i32.const 24)) (i32.const 8))
(assert_trap (invoke "check" (i32.const 25)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 26)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 27)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 28)) "uninitialized element")
(assert_trap (invoke "check" (i32.const 29)) "uninitialized element")
(assert_invalid
(module
(func (export "test")
(elem.drop 0)))
"unknown table 0")
(assert_invalid
(module
(func (export "test")
(table.init 0 (i32.const 12) (i32.const 1) (i32.const 1))))
"unknown table 0")
(assert_invalid
(module
(elem passive funcref 0)
(func (result i32) (i32.const 0))
(func (export "test")
(elem.drop 4)))
"unknown table 0")
(assert_invalid
(module
(elem passive funcref 0)
(func (result i32) (i32.const 0))
(func (export "test")
(table.init 4 (i32.const 12) (i32.const 1) (i32.const 1))))
"unknown table 0")
(module
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 0))
(func (result i32) (i32.const 1))
(func (result i32) (i32.const 2))
(func (result i32) (i32.const 3))
(func (result i32) (i32.const 4))
(func (result i32) (i32.const 5))
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9))
(func (export "test")
(elem.drop 2)
))
(assert_trap (invoke "test") "element segment dropped")
(module
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 0))
(func (result i32) (i32.const 1))
(func (result i32) (i32.const 2))
(func (result i32) (i32.const 3))
(func (result i32) (i32.const 4))
(func (result i32) (i32.const 5))
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9))
(func (export "test")
(table.init 2 (i32.const 12) (i32.const 1) (i32.const 1))
))
(assert_trap (invoke "test") "element segment dropped")
(module
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 0))
(func (result i32) (i32.const 1))
(func (result i32) (i32.const 2))
(func (result i32) (i32.const 3))
(func (result i32) (i32.const 4))
(func (result i32) (i32.const 5))
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9))
(func (export "test")
(table.init 1 (i32.const 12) (i32.const 1) (i32.const 1))
(table.init 1 (i32.const 21) (i32.const 1) (i32.const 1))))
(invoke "test")
(module
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 0))
(func (result i32) (i32.const 1))
(func (result i32) (i32.const 2))
(func (result i32) (i32.const 3))
(func (result i32) (i32.const 4))
(func (result i32) (i32.const 5))
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9))
(func (export "test")
(elem.drop 1)
(elem.drop 1)))
(assert_trap (invoke "test") "element segment dropped")
(module
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 0))
(func (result i32) (i32.const 1))
(func (result i32) (i32.const 2))
(func (result i32) (i32.const 3))
(func (result i32) (i32.const 4))
(func (result i32) (i32.const 5))
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9))
(func (export "test")
(elem.drop 1)
(table.init 1 (i32.const 12) (i32.const 1) (i32.const 1))))
(assert_trap (invoke "test") "element segment dropped")
(module
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 0))
(func (result i32) (i32.const 1))
(func (result i32) (i32.const 2))
(func (result i32) (i32.const 3))
(func (result i32) (i32.const 4))
(func (result i32) (i32.const 5))
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9))
(func (export "test")
(table.init 1 (i32.const 12) (i32.const 0) (i32.const 5))
))
(assert_trap (invoke "test") "out of bounds")
(module
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 0))
(func (result i32) (i32.const 1))
(func (result i32) (i32.const 2))
(func (result i32) (i32.const 3))
(func (result i32) (i32.const 4))
(func (result i32) (i32.const 5))
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9))
(func (export "test")
(table.init 1 (i32.const 12) (i32.const 2) (i32.const 3))
))
(assert_trap (invoke "test") "out of bounds")
(module
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 0))
(func (result i32) (i32.const 1))
(func (result i32) (i32.const 2))
(func (result i32) (i32.const 3))
(func (result i32) (i32.const 4))
(func (result i32) (i32.const 5))
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9))
(func (export "test")
(table.init 1 (i32.const 28) (i32.const 1) (i32.const 3))
))
(assert_trap (invoke "test") "out of bounds")
(module
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 0))
(func (result i32) (i32.const 1))
(func (result i32) (i32.const 2))
(func (result i32) (i32.const 3))
(func (result i32) (i32.const 4))
(func (result i32) (i32.const 5))
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9))
(func (export "test")
(table.init 1 (i32.const 12) (i32.const 4) (i32.const 0))
))
(invoke "test")
(module
(table 30 30 funcref)
(elem (i32.const 2) 3 1 4 1)
(elem passive funcref 2 7 1 8)
(elem (i32.const 12) 7 5 2 3 6)
(elem passive funcref 5 9 2 7 6)
(func (result i32) (i32.const 0))
(func (result i32) (i32.const 1))
(func (result i32) (i32.const 2))
(func (result i32) (i32.const 3))
(func (result i32) (i32.const 4))
(func (result i32) (i32.const 5))
(func (result i32) (i32.const 6))
(func (result i32) (i32.const 7))
(func (result i32) (i32.const 8))
(func (result i32) (i32.const 9))
(func (export "test")
(table.init 1 (i32.const 30) (i32.const 2) (i32.const 0))
))
(invoke "test")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (i32.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (i32.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (i32.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (f32.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (f32.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (f32.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (f32.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (i64.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (i64.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (i64.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (i64.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (f64.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (f64.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (f64.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i32.const 1) (f64.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (i32.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (i32.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (i32.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (i32.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (f32.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (f32.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (f32.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (f32.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (i64.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (i64.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (i64.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (i64.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (f64.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (f64.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (f64.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f32.const 1) (f64.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (i32.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (i32.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (i32.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (i32.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (f32.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (f32.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (f32.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (f32.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (i64.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (i64.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (i64.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (i64.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (f64.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (f64.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (f64.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (i64.const 1) (f64.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (i32.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (i32.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (i32.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (i32.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (f32.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (f32.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (f32.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (f32.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (i64.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (i64.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (i64.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (i64.const 1) (f64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (f64.const 1) (i32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (f64.const 1) (f32.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (f64.const 1) (i64.const 1))))
"type mismatch")
(assert_invalid
(module
(table 10 funcref)
(elem passive funcref $f0 $f0 $f0)
(func $f0)
(func (export "test")
(table.init 0 (f64.const 1) (f64.const 1) (f64.const 1))))
"type mismatch")
(module
(type (func (result i32)))
(table 32 64 funcref)
(elem passive funcref $f0 $f1 $f2 $f3 $f4 $f5 $f6 $f7 $f8 $f9 $f10 $f11 $f12 $f13 $f14 $f15)
(func $f0 (export "f0") (result i32) (i32.const 0))
(func $f1 (export "f1") (result i32) (i32.const 1))
(func $f2 (export "f2") (result i32) (i32.const 2))
(func $f3 (export "f3") (result i32) (i32.const 3))
(func $f4 (export "f4") (result i32) (i32.const 4))
(func $f5 (export "f5") (result i32) (i32.const 5))
(func $f6 (export "f6") (result i32) (i32.const 6))
(func $f7 (export "f7") (result i32) (i32.const 7))
(func $f8 (export "f8") (result i32) (i32.const 8))
(func $f9 (export "f9") (result i32) (i32.const 9))
(func $f10 (export "f10") (result i32) (i32.const 10))
(func $f11 (export "f11") (result i32) (i32.const 11))
(func $f12 (export "f12") (result i32) (i32.const 12))
(func $f13 (export "f13") (result i32) (i32.const 13))
(func $f14 (export "f14") (result i32) (i32.const 14))
(func $f15 (export "f15") (result i32) (i32.const 15))
(func (export "test") (param $n i32) (result i32)
(call_indirect (type 0) (local.get $n)))
(func (export "run") (param $offs i32) (param $len i32)
(table.init 0 (local.get $offs) (i32.const 0) (local.get $len))))
(assert_trap (invoke "run" (i32.const 24) (i32.const 16)) "out of bounds")
(assert_return (invoke "test" (i32.const 24)) (i32.const 0))
(assert_return (invoke "test" (i32.const 25)) (i32.const 1))
(assert_return (invoke "test" (i32.const 26)) (i32.const 2))
(assert_return (invoke "test" (i32.const 27)) (i32.const 3))
(assert_return (invoke "test" (i32.const 28)) (i32.const 4))
(assert_return (invoke "test" (i32.const 29)) (i32.const 5))
(assert_return (invoke "test" (i32.const 30)) (i32.const 6))
(assert_return (invoke "test" (i32.const 31)) (i32.const 7))
(assert_trap (invoke "test" (i32.const 0)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 1)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 2)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 3)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 4)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 5)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 6)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 7)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 8)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 9)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 10)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 11)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 12)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 13)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 14)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 15)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 16)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 17)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 18)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 19)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 20)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 21)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 22)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 23)) "uninitialized element")
(module
(type (func (result i32)))
(table 32 64 funcref)
(elem passive funcref $f0 $f1 $f2 $f3 $f4 $f5 $f6 $f7 $f8 $f9 $f10 $f11 $f12 $f13 $f14 $f15)
(func $f0 (export "f0") (result i32) (i32.const 0))
(func $f1 (export "f1") (result i32) (i32.const 1))
(func $f2 (export "f2") (result i32) (i32.const 2))
(func $f3 (export "f3") (result i32) (i32.const 3))
(func $f4 (export "f4") (result i32) (i32.const 4))
(func $f5 (export "f5") (result i32) (i32.const 5))
(func $f6 (export "f6") (result i32) (i32.const 6))
(func $f7 (export "f7") (result i32) (i32.const 7))
(func $f8 (export "f8") (result i32) (i32.const 8))
(func $f9 (export "f9") (result i32) (i32.const 9))
(func $f10 (export "f10") (result i32) (i32.const 10))
(func $f11 (export "f11") (result i32) (i32.const 11))
(func $f12 (export "f12") (result i32) (i32.const 12))
(func $f13 (export "f13") (result i32) (i32.const 13))
(func $f14 (export "f14") (result i32) (i32.const 14))
(func $f15 (export "f15") (result i32) (i32.const 15))
(func (export "test") (param $n i32) (result i32)
(call_indirect (type 0) (local.get $n)))
(func (export "run") (param $offs i32) (param $len i32)
(table.init 0 (local.get $offs) (i32.const 0) (local.get $len))))
(assert_trap (invoke "run" (i32.const 25) (i32.const 16)) "out of bounds")
(assert_return (invoke "test" (i32.const 25)) (i32.const 0))
(assert_return (invoke "test" (i32.const 26)) (i32.const 1))
(assert_return (invoke "test" (i32.const 27)) (i32.const 2))
(assert_return (invoke "test" (i32.const 28)) (i32.const 3))
(assert_return (invoke "test" (i32.const 29)) (i32.const 4))
(assert_return (invoke "test" (i32.const 30)) (i32.const 5))
(assert_return (invoke "test" (i32.const 31)) (i32.const 6))
(assert_trap (invoke "test" (i32.const 0)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 1)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 2)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 3)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 4)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 5)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 6)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 7)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 8)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 9)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 10)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 11)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 12)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 13)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 14)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 15)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 16)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 17)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 18)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 19)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 20)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 21)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 22)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 23)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 24)) "uninitialized element")
(module
(type (func (result i32)))
(table 160 320 funcref)
(elem passive funcref $f0 $f1 $f2 $f3 $f4 $f5 $f6 $f7 $f8 $f9 $f10 $f11 $f12 $f13 $f14 $f15)
(func $f0 (export "f0") (result i32) (i32.const 0))
(func $f1 (export "f1") (result i32) (i32.const 1))
(func $f2 (export "f2") (result i32) (i32.const 2))
(func $f3 (export "f3") (result i32) (i32.const 3))
(func $f4 (export "f4") (result i32) (i32.const 4))
(func $f5 (export "f5") (result i32) (i32.const 5))
(func $f6 (export "f6") (result i32) (i32.const 6))
(func $f7 (export "f7") (result i32) (i32.const 7))
(func $f8 (export "f8") (result i32) (i32.const 8))
(func $f9 (export "f9") (result i32) (i32.const 9))
(func $f10 (export "f10") (result i32) (i32.const 10))
(func $f11 (export "f11") (result i32) (i32.const 11))
(func $f12 (export "f12") (result i32) (i32.const 12))
(func $f13 (export "f13") (result i32) (i32.const 13))
(func $f14 (export "f14") (result i32) (i32.const 14))
(func $f15 (export "f15") (result i32) (i32.const 15))
(func (export "test") (param $n i32) (result i32)
(call_indirect (type 0) (local.get $n)))
(func (export "run") (param $offs i32) (param $len i32)
(table.init 0 (local.get $offs) (i32.const 0) (local.get $len))))
(assert_trap (invoke "run" (i32.const 96) (i32.const 32)) "out of bounds")
(assert_return (invoke "test" (i32.const 96)) (i32.const 0))
(assert_return (invoke "test" (i32.const 97)) (i32.const 1))
(assert_return (invoke "test" (i32.const 98)) (i32.const 2))
(assert_return (invoke "test" (i32.const 99)) (i32.const 3))
(assert_return (invoke "test" (i32.const 100)) (i32.const 4))
(assert_return (invoke "test" (i32.const 101)) (i32.const 5))
(assert_return (invoke "test" (i32.const 102)) (i32.const 6))
(assert_return (invoke "test" (i32.const 103)) (i32.const 7))
(assert_return (invoke "test" (i32.const 104)) (i32.const 8))
(assert_return (invoke "test" (i32.const 105)) (i32.const 9))
(assert_return (invoke "test" (i32.const 106)) (i32.const 10))
(assert_return (invoke "test" (i32.const 107)) (i32.const 11))
(assert_return (invoke "test" (i32.const 108)) (i32.const 12))
(assert_return (invoke "test" (i32.const 109)) (i32.const 13))
(assert_return (invoke "test" (i32.const 110)) (i32.const 14))
(assert_return (invoke "test" (i32.const 111)) (i32.const 15))
(assert_trap (invoke "test" (i32.const 112)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 113)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 114)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 115)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 116)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 117)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 118)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 119)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 120)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 121)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 122)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 123)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 124)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 125)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 126)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 127)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 128)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 129)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 130)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 131)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 132)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 133)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 134)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 135)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 136)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 137)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 138)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 139)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 140)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 141)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 142)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 143)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 144)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 145)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 146)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 147)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 148)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 149)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 150)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 151)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 152)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 153)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 154)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 155)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 156)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 157)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 158)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 159)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 0)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 1)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 2)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 3)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 4)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 5)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 6)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 7)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 8)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 9)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 10)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 11)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 12)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 13)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 14)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 15)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 16)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 17)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 18)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 19)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 20)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 21)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 22)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 23)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 24)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 25)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 26)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 27)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 28)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 29)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 30)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 31)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 32)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 33)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 34)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 35)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 36)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 37)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 38)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 39)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 40)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 41)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 42)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 43)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 44)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 45)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 46)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 47)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 48)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 49)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 50)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 51)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 52)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 53)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 54)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 55)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 56)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 57)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 58)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 59)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 60)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 61)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 62)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 63)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 64)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 65)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 66)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 67)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 68)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 69)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 70)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 71)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 72)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 73)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 74)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 75)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 76)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 77)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 78)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 79)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 80)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 81)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 82)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 83)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 84)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 85)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 86)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 87)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 88)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 89)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 90)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 91)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 92)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 93)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 94)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 95)) "uninitialized element")
(module
(type (func (result i32)))
(table 160 320 funcref)
(elem passive funcref $f0 $f1 $f2 $f3 $f4 $f5 $f6 $f7 $f8 $f9 $f10 $f11 $f12 $f13 $f14 $f15)
(func $f0 (export "f0") (result i32) (i32.const 0))
(func $f1 (export "f1") (result i32) (i32.const 1))
(func $f2 (export "f2") (result i32) (i32.const 2))
(func $f3 (export "f3") (result i32) (i32.const 3))
(func $f4 (export "f4") (result i32) (i32.const 4))
(func $f5 (export "f5") (result i32) (i32.const 5))
(func $f6 (export "f6") (result i32) (i32.const 6))
(func $f7 (export "f7") (result i32) (i32.const 7))
(func $f8 (export "f8") (result i32) (i32.const 8))
(func $f9 (export "f9") (result i32) (i32.const 9))
(func $f10 (export "f10") (result i32) (i32.const 10))
(func $f11 (export "f11") (result i32) (i32.const 11))
(func $f12 (export "f12") (result i32) (i32.const 12))
(func $f13 (export "f13") (result i32) (i32.const 13))
(func $f14 (export "f14") (result i32) (i32.const 14))
(func $f15 (export "f15") (result i32) (i32.const 15))
(func (export "test") (param $n i32) (result i32)
(call_indirect (type 0) (local.get $n)))
(func (export "run") (param $offs i32) (param $len i32)
(table.init 0 (local.get $offs) (i32.const 0) (local.get $len))))
(assert_trap (invoke "run" (i32.const 97) (i32.const 31)) "out of bounds")
(assert_return (invoke "test" (i32.const 97)) (i32.const 0))
(assert_return (invoke "test" (i32.const 98)) (i32.const 1))
(assert_return (invoke "test" (i32.const 99)) (i32.const 2))
(assert_return (invoke "test" (i32.const 100)) (i32.const 3))
(assert_return (invoke "test" (i32.const 101)) (i32.const 4))
(assert_return (invoke "test" (i32.const 102)) (i32.const 5))
(assert_return (invoke "test" (i32.const 103)) (i32.const 6))
(assert_return (invoke "test" (i32.const 104)) (i32.const 7))
(assert_return (invoke "test" (i32.const 105)) (i32.const 8))
(assert_return (invoke "test" (i32.const 106)) (i32.const 9))
(assert_return (invoke "test" (i32.const 107)) (i32.const 10))
(assert_return (invoke "test" (i32.const 108)) (i32.const 11))
(assert_return (invoke "test" (i32.const 109)) (i32.const 12))
(assert_return (invoke "test" (i32.const 110)) (i32.const 13))
(assert_return (invoke "test" (i32.const 111)) (i32.const 14))
(assert_return (invoke "test" (i32.const 112)) (i32.const 15))
(assert_trap (invoke "test" (i32.const 113)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 114)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 115)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 116)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 117)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 118)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 119)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 120)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 121)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 122)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 123)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 124)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 125)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 126)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 127)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 128)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 129)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 130)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 131)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 132)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 133)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 134)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 135)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 136)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 137)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 138)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 139)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 140)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 141)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 142)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 143)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 144)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 145)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 146)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 147)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 148)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 149)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 150)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 151)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 152)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 153)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 154)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 155)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 156)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 157)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 158)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 159)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 0)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 1)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 2)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 3)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 4)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 5)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 6)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 7)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 8)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 9)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 10)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 11)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 12)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 13)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 14)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 15)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 16)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 17)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 18)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 19)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 20)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 21)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 22)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 23)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 24)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 25)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 26)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 27)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 28)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 29)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 30)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 31)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 32)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 33)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 34)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 35)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 36)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 37)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 38)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 39)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 40)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 41)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 42)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 43)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 44)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 45)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 46)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 47)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 48)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 49)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 50)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 51)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 52)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 53)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 54)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 55)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 56)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 57)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 58)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 59)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 60)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 61)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 62)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 63)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 64)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 65)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 66)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 67)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 68)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 69)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 70)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 71)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 72)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 73)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 74)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 75)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 76)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 77)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 78)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 79)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 80)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 81)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 82)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 83)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 84)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 85)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 86)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 87)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 88)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 89)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 90)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 91)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 92)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 93)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 94)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 95)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 96)) "uninitialized element")
(module
(type (func (result i32)))
(table 64 64 funcref)
(elem passive funcref $f0 $f1 $f2 $f3 $f4 $f5 $f6 $f7 $f8 $f9 $f10 $f11 $f12 $f13 $f14 $f15)
(func $f0 (export "f0") (result i32) (i32.const 0))
(func $f1 (export "f1") (result i32) (i32.const 1))
(func $f2 (export "f2") (result i32) (i32.const 2))
(func $f3 (export "f3") (result i32) (i32.const 3))
(func $f4 (export "f4") (result i32) (i32.const 4))
(func $f5 (export "f5") (result i32) (i32.const 5))
(func $f6 (export "f6") (result i32) (i32.const 6))
(func $f7 (export "f7") (result i32) (i32.const 7))
(func $f8 (export "f8") (result i32) (i32.const 8))
(func $f9 (export "f9") (result i32) (i32.const 9))
(func $f10 (export "f10") (result i32) (i32.const 10))
(func $f11 (export "f11") (result i32) (i32.const 11))
(func $f12 (export "f12") (result i32) (i32.const 12))
(func $f13 (export "f13") (result i32) (i32.const 13))
(func $f14 (export "f14") (result i32) (i32.const 14))
(func $f15 (export "f15") (result i32) (i32.const 15))
(func (export "test") (param $n i32) (result i32)
(call_indirect (type 0) (local.get $n)))
(func (export "run") (param $offs i32) (param $len i32)
(table.init 0 (local.get $offs) (i32.const 0) (local.get $len))))
(assert_trap (invoke "run" (i32.const 48) (i32.const 4294967280)) "out of bounds")
(assert_return (invoke "test" (i32.const 48)) (i32.const 0))
(assert_return (invoke "test" (i32.const 49)) (i32.const 1))
(assert_return (invoke "test" (i32.const 50)) (i32.const 2))
(assert_return (invoke "test" (i32.const 51)) (i32.const 3))
(assert_return (invoke "test" (i32.const 52)) (i32.const 4))
(assert_return (invoke "test" (i32.const 53)) (i32.const 5))
(assert_return (invoke "test" (i32.const 54)) (i32.const 6))
(assert_return (invoke "test" (i32.const 55)) (i32.const 7))
(assert_return (invoke "test" (i32.const 56)) (i32.const 8))
(assert_return (invoke "test" (i32.const 57)) (i32.const 9))
(assert_return (invoke "test" (i32.const 58)) (i32.const 10))
(assert_return (invoke "test" (i32.const 59)) (i32.const 11))
(assert_return (invoke "test" (i32.const 60)) (i32.const 12))
(assert_return (invoke "test" (i32.const 61)) (i32.const 13))
(assert_return (invoke "test" (i32.const 62)) (i32.const 14))
(assert_return (invoke "test" (i32.const 63)) (i32.const 15))
(assert_trap (invoke "test" (i32.const 0)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 1)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 2)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 3)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 4)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 5)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 6)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 7)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 8)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 9)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 10)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 11)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 12)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 13)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 14)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 15)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 16)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 17)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 18)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 19)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 20)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 21)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 22)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 23)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 24)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 25)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 26)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 27)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 28)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 29)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 30)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 31)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 32)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 33)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 34)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 35)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 36)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 37)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 38)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 39)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 40)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 41)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 42)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 43)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 44)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 45)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 46)) "uninitialized element")
(assert_trap (invoke "test" (i32.const 47)) "uninitialized element")
(module
(type (func (result i32)))
(table 16 16 funcref)
(elem passive funcref $f0 $f1 $f2 $f3 $f4 $f5 $f6 $f7 $f8 $f9 $f10 $f11 $f12 $f13 $f14 $f15)
(func $f0 (export "f0") (result i32) (i32.const 0))
(func $f1 (export "f1") (result i32) (i32.const 1))
(func $f2 (export "f2") (result i32) (i32.const 2))
(func $f3 (export "f3") (result i32) (i32.const 3))
(func $f4 (export "f4") (result i32) (i32.const 4))
(func $f5 (export "f5") (result i32) (i32.const 5))
(func $f6 (export "f6") (result i32) (i32.const 6))
(func $f7 (export "f7") (result i32) (i32.const 7))
(func $f8 (export "f8") (result i32) (i32.const 8))
(func $f9 (export "f9") (result i32) (i32.const 9))
(func $f10 (export "f10") (result i32) (i32.const 10))
(func $f11 (export "f11") (result i32) (i32.const 11))
(func $f12 (export "f12") (result i32) (i32.const 12))
(func $f13 (export "f13") (result i32) (i32.const 13))
(func $f14 (export "f14") (result i32) (i32.const 14))
(func $f15 (export "f15") (result i32) (i32.const 15))
(func (export "test") (param $n i32) (result i32)
(call_indirect (type 0) (local.get $n)))
(func (export "run") (param $offs i32) (param $len i32)
(table.init 0 (local.get $offs) (i32.const 8) (local.get $len))))
(assert_trap (invoke "run" (i32.const 0) (i32.const 4294967292)) "out of bounds")
(assert_return (invoke "test" (i32.const 0)) (i32.const 8))
(assert_return (invoke "test" (i32.const 1)) (i32.const 9))
(assert_return (invoke "test" (i32.const 2)) (i32.const 10))
(assert_return (invoke "test" (i32.const 3)) (i32.const 11))
(assert_return (invoke "test" (i32.const 4)) (i32.const 12))
(assert_return (invoke "test" (i32.const 5)) (i32.const 13))
(assert_return (invoke "test" (i32.const 6)) (i32.const 14))
(assert_return (invoke "test" (i32.const 7)) (i32.const 15))