summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/passes/Print.cpp2
-rw-r--r--src/wasm/wasm-s-parser.cpp4
-rw-r--r--test/ctor-eval/bad-indirect-call.wast2
-rw-r--r--test/ctor-eval/bad-indirect-call.wast.out2
-rw-r--r--test/ctor-eval/bad-indirect-call2.wast2
-rw-r--r--test/ctor-eval/bad-indirect-call2.wast.out2
-rw-r--r--test/ctor-eval/basics-flatten.wast2
-rw-r--r--test/ctor-eval/basics.wast2
-rw-r--r--test/ctor-eval/indirect-call3.wast2
-rw-r--r--test/dot_s/alias.wast2
-rw-r--r--test/dot_s/basics.wast2
-rw-r--r--test/dot_s/bcp-1.wast38
-rw-r--r--test/dot_s/dyncall.wast6
-rw-r--r--test/dot_s/fix_em_ehsjlj_names.wast8
-rw-r--r--test/dot_s/indidx.wast4
-rw-r--r--test/dot_s/indirect-import.wast6
-rw-r--r--test/emcc_O2_hello_world.fromasm16
-rw-r--r--test/emcc_O2_hello_world.fromasm.clamp16
-rw-r--r--test/emcc_O2_hello_world.fromasm.clamp.no-opts16
-rw-r--r--test/emcc_O2_hello_world.fromasm.imprecise16
-rw-r--r--test/emcc_O2_hello_world.fromasm.imprecise.no-opts16
-rw-r--r--test/emcc_O2_hello_world.fromasm.no-opts16
-rw-r--r--test/emcc_hello_world.fromasm16
-rw-r--r--test/emcc_hello_world.fromasm.clamp16
-rw-r--r--test/emcc_hello_world.fromasm.clamp.no-opts16
-rw-r--r--test/emcc_hello_world.fromasm.imprecise16
-rw-r--r--test/emcc_hello_world.fromasm.imprecise.no-opts16
-rw-r--r--test/emcc_hello_world.fromasm.no-opts16
-rw-r--r--test/example/c-api-kitchen-sink.txt6
-rw-r--r--test/example/c-api-kitchen-sink.txt.txt2
-rw-r--r--test/llvm_autogenerated/call.wast8
-rw-r--r--test/llvm_autogenerated/indirect-import.wast6
-rw-r--r--test/llvm_autogenerated/lower-em-ehsjlj-options.wast2
-rw-r--r--test/llvm_autogenerated/reg-stackify.wast2
-rw-r--r--test/memorygrowth.fromasm16
-rw-r--r--test/memorygrowth.fromasm.clamp16
-rw-r--r--test/memorygrowth.fromasm.clamp.no-opts16
-rw-r--r--test/memorygrowth.fromasm.imprecise16
-rw-r--r--test/memorygrowth.fromasm.imprecise.no-opts16
-rw-r--r--test/memorygrowth.fromasm.no-opts16
-rw-r--r--test/merge/basics.wast2
-rw-r--r--test/merge/basics.wast.combined4
-rw-r--r--test/merge/basics.wast.combined.finalized4
-rw-r--r--test/merge/basics.wast.combined.finalized.opt4
-rw-r--r--test/merge/basics.wast.combined.opt4
-rw-r--r--test/merge/basics.wast.toMerge2
-rw-r--r--test/passes/code-folding.txt2
-rw-r--r--test/passes/code-folding.wast2
-rw-r--r--test/passes/dce.wast8
-rw-r--r--test/passes/duplicate-function-elimination.txt10
-rw-r--r--test/passes/duplicate-function-elimination.wast12
-rw-r--r--test/passes/flatten.txt8
-rw-r--r--test/passes/flatten.wast8
-rw-r--r--test/passes/inlining-optimizing_optimize-level=3.txt16
-rw-r--r--test/passes/inlining-optimizing_optimize-level=3.wast16
-rw-r--r--test/passes/print-call-graph.txt14
-rw-r--r--test/passes/print-call-graph.wast14
-rw-r--r--test/passes/remove-unused-module-elements.txt18
-rw-r--r--test/passes/remove-unused-module-elements.wast18
-rw-r--r--test/passes/remove-unused-names_merge-blocks.txt8
-rw-r--r--test/passes/remove-unused-names_merge-blocks.wast8
-rw-r--r--test/polymorphic_stack.wast2
-rw-r--r--test/polymorphic_stack.wast.from-wast2
-rw-r--r--test/reduce/memory_table.wast4
-rw-r--r--test/reduce/memory_table.wast.txt4
m---------test/spec0
-rw-r--r--test/unit.fromasm16
-rw-r--r--test/unit.fromasm.clamp16
-rw-r--r--test/unit.fromasm.clamp.no-opts16
-rw-r--r--test/unit.fromasm.imprecise16
-rw-r--r--test/unit.fromasm.imprecise.no-opts16
-rw-r--r--test/unit.fromasm.no-opts16
-rw-r--r--test/unit.wast4
-rw-r--r--test/unit.wast.from-wast4
-rw-r--r--test/unit.wast.fromBinary4
-rw-r--r--test/unit.wast.fromBinary.noDebugInfo4
-rw-r--r--test/wasm2asm/br_table_temp.wast8
77 files changed, 358 insertions, 356 deletions
diff --git a/src/passes/Print.cpp b/src/passes/Print.cpp
index ed868deb6..2f7588b37 100644
--- a/src/passes/Print.cpp
+++ b/src/passes/Print.cpp
@@ -264,7 +264,7 @@ struct PrintSExpression : public Visitor<PrintSExpression> {
printCallBody(curr);
}
void visitCallIndirect(CallIndirect *curr) {
- printOpening(o, "call_indirect ") << curr->fullType;
+ printOpening(o, "call_indirect (type ") << curr->fullType << ')';
incIndent();
for (auto operand : curr->operands) {
printFullLine(operand);
diff --git a/src/wasm/wasm-s-parser.cpp b/src/wasm/wasm-s-parser.cpp
index 599eec5b8..0de3edf3f 100644
--- a/src/wasm/wasm-s-parser.cpp
+++ b/src/wasm/wasm-s-parser.cpp
@@ -1387,7 +1387,9 @@ Expression* SExpressionWasmBuilder::makeCallImport(Element& s) {
Expression* SExpressionWasmBuilder::makeCallIndirect(Element& s) {
if (!wasm.table.exists) throw ParseException("no table");
auto ret = allocator.alloc<CallIndirect>();
- IString type = s[1]->str();
+ Element& typeElement = *s[1];
+ if (typeElement[0]->str() != "type") throw ParseException("expected 'type' in call_indirect", s.line, s.col);
+ IString type = typeElement[1]->str();
auto* fullType = wasm.getFunctionTypeOrNull(type);
if (!fullType) throw ParseException("invalid call_indirect type", s.line, s.col);
ret->fullType = fullType->name;
diff --git a/test/ctor-eval/bad-indirect-call.wast b/test/ctor-eval/bad-indirect-call.wast
index bed3112c3..cbc48427a 100644
--- a/test/ctor-eval/bad-indirect-call.wast
+++ b/test/ctor-eval/bad-indirect-call.wast
@@ -6,7 +6,7 @@
(elem (i32.const 0) $call-indirect)
(export "test1" $test1)
(func $test1
- (call_indirect $v (i32.const 1)) ;; unsafe to call, out of range
+ (call_indirect (type $v) (i32.const 1)) ;; unsafe to call, out of range
(i32.store8 (i32.const 20) (i32.const 120))
)
(func $call-indirect
diff --git a/test/ctor-eval/bad-indirect-call.wast.out b/test/ctor-eval/bad-indirect-call.wast.out
index 5cd7830f9..9c9897731 100644
--- a/test/ctor-eval/bad-indirect-call.wast.out
+++ b/test/ctor-eval/bad-indirect-call.wast.out
@@ -6,7 +6,7 @@
(data (i32.const 10) "waka waka waka waka waka")
(export "test1" (func $test1))
(func $test1 (; 0 ;) (type $v)
- (call_indirect $v
+ (call_indirect (type $v)
(i32.const 1)
)
(i32.store8
diff --git a/test/ctor-eval/bad-indirect-call2.wast b/test/ctor-eval/bad-indirect-call2.wast
index 52eaab67c..a19d02be7 100644
--- a/test/ctor-eval/bad-indirect-call2.wast
+++ b/test/ctor-eval/bad-indirect-call2.wast
@@ -7,7 +7,7 @@
(elem (i32.const 0) $_abort $call-indirect)
(export "test1" $test1)
(func $test1
- (call_indirect $v (i32.const 0)) ;; unsafe to call, imported
+ (call_indirect (type $v) (i32.const 0)) ;; unsafe to call, imported
(i32.store8 (i32.const 20) (i32.const 120))
)
(func $call-indirect
diff --git a/test/ctor-eval/bad-indirect-call2.wast.out b/test/ctor-eval/bad-indirect-call2.wast.out
index dd3800a84..b6a50c2f5 100644
--- a/test/ctor-eval/bad-indirect-call2.wast.out
+++ b/test/ctor-eval/bad-indirect-call2.wast.out
@@ -8,7 +8,7 @@
(data (i32.const 10) "waka waka waka waka waka")
(export "test1" (func $test1))
(func $test1 (; 1 ;) (type $v)
- (call_indirect $v
+ (call_indirect (type $v)
(i32.const 0)
)
(i32.store8
diff --git a/test/ctor-eval/basics-flatten.wast b/test/ctor-eval/basics-flatten.wast
index 3bbd27a6b..da8b76163 100644
--- a/test/ctor-eval/basics-flatten.wast
+++ b/test/ctor-eval/basics-flatten.wast
@@ -13,7 +13,7 @@
(func $test1
(drop (i32.const 0)) ;; no work at all, really
(call $safe-to-call) ;; safe to call
- (call_indirect $v (i32.const 0)) ;; safe to call
+ (call_indirect (type $v) (i32.const 0)) ;; safe to call
)
(func $test2
(drop (i32.load (i32.const 12))) ;; a safe load
diff --git a/test/ctor-eval/basics.wast b/test/ctor-eval/basics.wast
index a81b2de2f..997e2cd11 100644
--- a/test/ctor-eval/basics.wast
+++ b/test/ctor-eval/basics.wast
@@ -10,7 +10,7 @@
(func $test1
(drop (i32.const 0)) ;; no work at all, really
(call $safe-to-call) ;; safe to call
- (call_indirect $v (i32.const 0)) ;; safe to call
+ (call_indirect (type $v) (i32.const 0)) ;; safe to call
)
(func $test2
(drop (i32.load (i32.const 12))) ;; a safe load
diff --git a/test/ctor-eval/indirect-call3.wast b/test/ctor-eval/indirect-call3.wast
index 9eaa90821..6695fc5b8 100644
--- a/test/ctor-eval/indirect-call3.wast
+++ b/test/ctor-eval/indirect-call3.wast
@@ -8,7 +8,7 @@
(elem (get_global $tableBase) $_abort $call-indirect)
(export "test1" $test1)
(func $test1
- (call_indirect $v (i32.const 1)) ;; safe to call
+ (call_indirect (type $v) (i32.const 1)) ;; safe to call
(i32.store8 (i32.const 20) (i32.const 120))
)
(func $call-indirect
diff --git a/test/dot_s/alias.wast b/test/dot_s/alias.wast
index 3e70a8c31..4fa629157 100644
--- a/test/dot_s/alias.wast
+++ b/test/dot_s/alias.wast
@@ -62,7 +62,7 @@
(unreachable)
)
(func $dynCall_v (; 6 ;) (param $fptr i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(get_local $fptr)
)
)
diff --git a/test/dot_s/basics.wast b/test/dot_s/basics.wast
index 99c78be9d..9215507f7 100644
--- a/test/dot_s/basics.wast
+++ b/test/dot_s/basics.wast
@@ -131,7 +131,7 @@
(unreachable)
)
(func $dynCall_iii (; 6 ;) (param $fptr i32) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$iii
+ (call_indirect (type $FUNCSIG$iii)
(get_local $0)
(get_local $1)
(get_local $fptr)
diff --git a/test/dot_s/bcp-1.wast b/test/dot_s/bcp-1.wast
index 8d333e7bc..79072396c 100644
--- a/test/dot_s/bcp-1.wast
+++ b/test/dot_s/bcp-1.wast
@@ -132,42 +132,42 @@
)
(block $label$0
(br_if $label$0
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=16
(get_local $0)
)
)
)
(br_if $label$0
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=20
(get_local $0)
)
)
)
(br_if $label$0
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=24
(get_local $0)
)
)
)
(br_if $label$0
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=28
(get_local $0)
)
)
)
(br_if $label$0
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=32
(get_local $0)
)
)
)
(br_if $label$0
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=36
(get_local $0)
)
@@ -183,13 +183,13 @@
)
(block $label$1
(br_if $label$1
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $2)
(get_local $1)
)
)
(br_if $label$1
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $2)
(i32.load offset=44
(get_local $0)
@@ -197,7 +197,7 @@
)
)
(br_if $label$1
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $2)
(i32.load offset=48
(get_local $0)
@@ -214,13 +214,13 @@
)
(block $label$2
(br_if $label$2
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $2)
(get_local $1)
)
)
(br_if $label$2
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $2)
(i32.load offset=56
(get_local $0)
@@ -230,7 +230,7 @@
(block $label$3
(br_if $label$3
(i32.eq
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=60
(get_local $0)
)
@@ -240,7 +240,7 @@
)
(br_if $label$3
(i32.eq
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=64
(get_local $0)
)
@@ -250,7 +250,7 @@
)
(br_if $label$3
(i32.eq
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=68
(get_local $0)
)
@@ -261,7 +261,7 @@
(block $label$4
(br_if $label$4
(i32.eq
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=72
(get_local $0)
)
@@ -271,7 +271,7 @@
)
(br_if $label$4
(i32.eq
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=76
(get_local $0)
)
@@ -281,7 +281,7 @@
)
(br_if $label$4
(i32.eq
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(i32.load offset=80
(get_local $0)
)
@@ -343,12 +343,12 @@
(unreachable)
)
(func $dynCall_i (; 24 ;) (param $fptr i32) (result i32)
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(get_local $fptr)
)
)
(func $dynCall_ii (; 25 ;) (param $fptr i32) (param $0 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $0)
(get_local $fptr)
)
diff --git a/test/dot_s/dyncall.wast b/test/dot_s/dyncall.wast
index 2656ce5c4..27d1ddaf7 100644
--- a/test/dot_s/dyncall.wast
+++ b/test/dot_s/dyncall.wast
@@ -84,18 +84,18 @@
(unreachable)
)
(func $dynCall_i (; 10 ;) (param $fptr i32) (result i32)
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(get_local $fptr)
)
)
(func $dynCall_if (; 11 ;) (param $fptr i32) (param $0 f32) (result i32)
- (call_indirect $FUNCSIG$if
+ (call_indirect (type $FUNCSIG$if)
(get_local $0)
(get_local $fptr)
)
)
(func $dynCall_vd (; 12 ;) (param $fptr i32) (param $0 f64)
- (call_indirect $FUNCSIG$vd
+ (call_indirect (type $FUNCSIG$vd)
(get_local $0)
(get_local $fptr)
)
diff --git a/test/dot_s/fix_em_ehsjlj_names.wast b/test/dot_s/fix_em_ehsjlj_names.wast
index d61668c83..a287983e8 100644
--- a/test/dot_s/fix_em_ehsjlj_names.wast
+++ b/test/dot_s/fix_em_ehsjlj_names.wast
@@ -110,12 +110,12 @@
(unreachable)
)
(func $dynCall_v (; 14 ;) (param $fptr i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(get_local $fptr)
)
)
(func $dynCall_iiii (; 15 ;) (param $fptr i32) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(get_local $1)
(get_local $2)
@@ -123,14 +123,14 @@
)
)
(func $dynCall_ffd (; 16 ;) (param $fptr i32) (param $0 f32) (param $1 f64) (result f32)
- (call_indirect $FUNCSIG$ffd
+ (call_indirect (type $FUNCSIG$ffd)
(get_local $0)
(get_local $1)
(get_local $fptr)
)
)
(func $dynCall_iii (; 17 ;) (param $fptr i32) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$iii
+ (call_indirect (type $FUNCSIG$iii)
(get_local $0)
(get_local $1)
(get_local $fptr)
diff --git a/test/dot_s/indidx.wast b/test/dot_s/indidx.wast
index 36a62da91..194868832 100644
--- a/test/dot_s/indidx.wast
+++ b/test/dot_s/indidx.wast
@@ -43,7 +43,7 @@
)
)
(return
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(get_local $2)
)
)
@@ -85,7 +85,7 @@
(unreachable)
)
(func $dynCall_i (; 10 ;) (param $fptr i32) (result i32)
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(get_local $fptr)
)
)
diff --git a/test/dot_s/indirect-import.wast b/test/dot_s/indirect-import.wast
index 3ee67e2a6..1b4c019ab 100644
--- a/test/dot_s/indirect-import.wast
+++ b/test/dot_s/indirect-import.wast
@@ -153,18 +153,18 @@
)
)
(func $dynCall_fd (; 18 ;) (param $fptr i32) (param $0 f64) (result f32)
- (call_indirect $FUNCSIG$fd
+ (call_indirect (type $FUNCSIG$fd)
(get_local $0)
(get_local $fptr)
)
)
(func $dynCall_v (; 19 ;) (param $fptr i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(get_local $fptr)
)
)
(func $dynCall_vi (; 20 ;) (param $fptr i32) (param $0 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $0)
(get_local $fptr)
)
diff --git a/test/emcc_O2_hello_world.fromasm b/test/emcc_O2_hello_world.fromasm
index 733bf30c6..8d7fbec6f 100644
--- a/test/emcc_O2_hello_world.fromasm
+++ b/test/emcc_O2_hello_world.fromasm
@@ -8172,7 +8172,7 @@
)
(block
(set_local $4
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -8242,7 +8242,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -8717,7 +8717,7 @@
(set_local $4
(if (result i32)
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(get_local $6)
(i32.const 1)
@@ -8777,7 +8777,7 @@
)
(block (result i32)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -8826,7 +8826,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $4)
@@ -9602,7 +9602,7 @@
)
)
(func $dynCall_iiii (; 33 ;) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -9664,7 +9664,7 @@
)
)
(func $dynCall_ii (; 37 ;) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -9693,7 +9693,7 @@
)
)
(func $dynCall_vi (; 40 ;) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/emcc_O2_hello_world.fromasm.clamp b/test/emcc_O2_hello_world.fromasm.clamp
index 733bf30c6..8d7fbec6f 100644
--- a/test/emcc_O2_hello_world.fromasm.clamp
+++ b/test/emcc_O2_hello_world.fromasm.clamp
@@ -8172,7 +8172,7 @@
)
(block
(set_local $4
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -8242,7 +8242,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -8717,7 +8717,7 @@
(set_local $4
(if (result i32)
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(get_local $6)
(i32.const 1)
@@ -8777,7 +8777,7 @@
)
(block (result i32)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -8826,7 +8826,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $4)
@@ -9602,7 +9602,7 @@
)
)
(func $dynCall_iiii (; 33 ;) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -9664,7 +9664,7 @@
)
)
(func $dynCall_ii (; 37 ;) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -9693,7 +9693,7 @@
)
)
(func $dynCall_vi (; 40 ;) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/emcc_O2_hello_world.fromasm.clamp.no-opts b/test/emcc_O2_hello_world.fromasm.clamp.no-opts
index 2b2a083d5..52192d925 100644
--- a/test/emcc_O2_hello_world.fromasm.clamp.no-opts
+++ b/test/emcc_O2_hello_world.fromasm.clamp.no-opts
@@ -9796,7 +9796,7 @@
)
(block
(set_local $i8
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i3)
(get_local $i1)
(get_local $i2)
@@ -9885,7 +9885,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i3)
(get_local $i1)
(get_local $i15)
@@ -10508,7 +10508,7 @@
)
(if
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i1)
(get_local $i4)
(i32.const 1)
@@ -10578,7 +10578,7 @@
)
(block (result i32)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i1)
(i32.const 0)
(i32.const 0)
@@ -10637,7 +10637,7 @@
(get_local $i8)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i1)
(i32.sub
(get_local $i6)
@@ -11738,7 +11738,7 @@
)
(func $dynCall_iiii (; 36 ;) (param $i1 i32) (param $i2 i32) (param $i3 i32) (param $i4 i32) (result i32)
(return
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i2)
(get_local $i3)
(get_local $i4)
@@ -11832,7 +11832,7 @@
)
(func $dynCall_ii (; 41 ;) (param $i1 i32) (param $i2 i32) (result i32)
(return
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $i2)
(i32.add
(i32.and
@@ -11869,7 +11869,7 @@
)
)
(func $dynCall_vi (; 44 ;) (param $i1 i32) (param $i2 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $i2)
(i32.add
(i32.and
diff --git a/test/emcc_O2_hello_world.fromasm.imprecise b/test/emcc_O2_hello_world.fromasm.imprecise
index 917ed8fcf..2a716a896 100644
--- a/test/emcc_O2_hello_world.fromasm.imprecise
+++ b/test/emcc_O2_hello_world.fromasm.imprecise
@@ -8171,7 +8171,7 @@
)
(block
(set_local $4
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -8241,7 +8241,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -8716,7 +8716,7 @@
(set_local $4
(if (result i32)
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(get_local $6)
(i32.const 1)
@@ -8776,7 +8776,7 @@
)
(block (result i32)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -8825,7 +8825,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $4)
@@ -9597,7 +9597,7 @@
)
)
(func $dynCall_iiii (; 33 ;) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -9659,7 +9659,7 @@
)
)
(func $dynCall_ii (; 37 ;) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -9688,7 +9688,7 @@
)
)
(func $dynCall_vi (; 40 ;) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/emcc_O2_hello_world.fromasm.imprecise.no-opts b/test/emcc_O2_hello_world.fromasm.imprecise.no-opts
index 1ebe34895..f1b2457a3 100644
--- a/test/emcc_O2_hello_world.fromasm.imprecise.no-opts
+++ b/test/emcc_O2_hello_world.fromasm.imprecise.no-opts
@@ -9796,7 +9796,7 @@
)
(block
(set_local $i8
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i3)
(get_local $i1)
(get_local $i2)
@@ -9885,7 +9885,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i3)
(get_local $i1)
(get_local $i15)
@@ -10508,7 +10508,7 @@
)
(if
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i1)
(get_local $i4)
(i32.const 1)
@@ -10578,7 +10578,7 @@
)
(block (result i32)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i1)
(i32.const 0)
(i32.const 0)
@@ -10637,7 +10637,7 @@
(get_local $i8)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i1)
(i32.sub
(get_local $i6)
@@ -11726,7 +11726,7 @@
)
(func $dynCall_iiii (; 35 ;) (param $i1 i32) (param $i2 i32) (param $i3 i32) (param $i4 i32) (result i32)
(return
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i2)
(get_local $i3)
(get_local $i4)
@@ -11820,7 +11820,7 @@
)
(func $dynCall_ii (; 40 ;) (param $i1 i32) (param $i2 i32) (result i32)
(return
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $i2)
(i32.add
(i32.and
@@ -11857,7 +11857,7 @@
)
)
(func $dynCall_vi (; 43 ;) (param $i1 i32) (param $i2 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $i2)
(i32.add
(i32.and
diff --git a/test/emcc_O2_hello_world.fromasm.no-opts b/test/emcc_O2_hello_world.fromasm.no-opts
index 2b2a083d5..52192d925 100644
--- a/test/emcc_O2_hello_world.fromasm.no-opts
+++ b/test/emcc_O2_hello_world.fromasm.no-opts
@@ -9796,7 +9796,7 @@
)
(block
(set_local $i8
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i3)
(get_local $i1)
(get_local $i2)
@@ -9885,7 +9885,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i3)
(get_local $i1)
(get_local $i15)
@@ -10508,7 +10508,7 @@
)
(if
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i1)
(get_local $i4)
(i32.const 1)
@@ -10578,7 +10578,7 @@
)
(block (result i32)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i1)
(i32.const 0)
(i32.const 0)
@@ -10637,7 +10637,7 @@
(get_local $i8)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i1)
(i32.sub
(get_local $i6)
@@ -11738,7 +11738,7 @@
)
(func $dynCall_iiii (; 36 ;) (param $i1 i32) (param $i2 i32) (param $i3 i32) (param $i4 i32) (result i32)
(return
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $i2)
(get_local $i3)
(get_local $i4)
@@ -11832,7 +11832,7 @@
)
(func $dynCall_ii (; 41 ;) (param $i1 i32) (param $i2 i32) (result i32)
(return
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $i2)
(i32.add
(i32.and
@@ -11869,7 +11869,7 @@
)
)
(func $dynCall_vi (; 44 ;) (param $i1 i32) (param $i2 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $i2)
(i32.add
(i32.and
diff --git a/test/emcc_hello_world.fromasm b/test/emcc_hello_world.fromasm
index 746fb42c5..2b03ce2a0 100644
--- a/test/emcc_hello_world.fromasm
+++ b/test/emcc_hello_world.fromasm
@@ -1273,7 +1273,7 @@
(get_local $13)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -1413,7 +1413,7 @@
)
(block
(set_local $3
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -1478,7 +1478,7 @@
)
(br_if $label$break$L5
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -2087,7 +2087,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -2135,7 +2135,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $4)
@@ -15618,7 +15618,7 @@
)
)
(func $dynCall_ii (; 66 ;) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -15627,7 +15627,7 @@
)
)
(func $dynCall_iiii (; 67 ;) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -15641,7 +15641,7 @@
)
)
(func $dynCall_vi (; 68 ;) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/emcc_hello_world.fromasm.clamp b/test/emcc_hello_world.fromasm.clamp
index 215c41540..84c48ed9d 100644
--- a/test/emcc_hello_world.fromasm.clamp
+++ b/test/emcc_hello_world.fromasm.clamp
@@ -1271,7 +1271,7 @@
(get_local $13)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -1411,7 +1411,7 @@
)
(block
(set_local $3
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -1476,7 +1476,7 @@
)
(br_if $label$break$L5
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -2085,7 +2085,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -2133,7 +2133,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $4)
@@ -15668,7 +15668,7 @@
)
)
(func $dynCall_ii (; 67 ;) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -15677,7 +15677,7 @@
)
)
(func $dynCall_iiii (; 68 ;) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -15691,7 +15691,7 @@
)
)
(func $dynCall_vi (; 69 ;) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/emcc_hello_world.fromasm.clamp.no-opts b/test/emcc_hello_world.fromasm.clamp.no-opts
index 59f98211b..a90f8b5ad 100644
--- a/test/emcc_hello_world.fromasm.clamp.no-opts
+++ b/test/emcc_hello_world.fromasm.clamp.no-opts
@@ -2549,7 +2549,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(i32.const 0)
(i32.const 0)
@@ -2839,7 +2839,7 @@
)
)
(set_local $$call4
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(get_local $$s)
(get_local $$l)
@@ -2970,7 +2970,7 @@
)
)
(set_local $$call16
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(get_local $$s)
(get_local $$i$0$lcssa36)
@@ -4449,7 +4449,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(i32.const 0)
(i32.const 0)
@@ -4548,7 +4548,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(get_local $$sub$ptr$sub)
(i32.const 1)
@@ -31615,7 +31615,7 @@
)
(func $dynCall_ii (; 76 ;) (param $index i32) (param $a1 i32) (result i32)
(return
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $a1)
(i32.add
(i32.and
@@ -31629,7 +31629,7 @@
)
(func $dynCall_iiii (; 77 ;) (param $index i32) (param $a1 i32) (param $a2 i32) (param $a3 i32) (result i32)
(return
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a1)
(get_local $a2)
(get_local $a3)
@@ -31644,7 +31644,7 @@
)
)
(func $dynCall_vi (; 78 ;) (param $index i32) (param $a1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $a1)
(i32.add
(i32.and
diff --git a/test/emcc_hello_world.fromasm.imprecise b/test/emcc_hello_world.fromasm.imprecise
index 1e2661d37..bcc64a662 100644
--- a/test/emcc_hello_world.fromasm.imprecise
+++ b/test/emcc_hello_world.fromasm.imprecise
@@ -1270,7 +1270,7 @@
(get_local $13)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -1410,7 +1410,7 @@
)
(block
(set_local $3
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -1475,7 +1475,7 @@
)
(br_if $label$break$L5
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -2084,7 +2084,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -2132,7 +2132,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $4)
@@ -15556,7 +15556,7 @@
)
)
(func $dynCall_ii (; 62 ;) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -15565,7 +15565,7 @@
)
)
(func $dynCall_iiii (; 63 ;) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -15579,7 +15579,7 @@
)
)
(func $dynCall_vi (; 64 ;) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/emcc_hello_world.fromasm.imprecise.no-opts b/test/emcc_hello_world.fromasm.imprecise.no-opts
index 1ba5aed89..8f91b3adb 100644
--- a/test/emcc_hello_world.fromasm.imprecise.no-opts
+++ b/test/emcc_hello_world.fromasm.imprecise.no-opts
@@ -2549,7 +2549,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(i32.const 0)
(i32.const 0)
@@ -2839,7 +2839,7 @@
)
)
(set_local $$call4
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(get_local $$s)
(get_local $$l)
@@ -2970,7 +2970,7 @@
)
)
(set_local $$call16
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(get_local $$s)
(get_local $$i$0$lcssa36)
@@ -4449,7 +4449,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(i32.const 0)
(i32.const 0)
@@ -4548,7 +4548,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(get_local $$sub$ptr$sub)
(i32.const 1)
@@ -31502,7 +31502,7 @@
)
(func $dynCall_ii (; 70 ;) (param $index i32) (param $a1 i32) (result i32)
(return
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $a1)
(i32.add
(i32.and
@@ -31516,7 +31516,7 @@
)
(func $dynCall_iiii (; 71 ;) (param $index i32) (param $a1 i32) (param $a2 i32) (param $a3 i32) (result i32)
(return
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a1)
(get_local $a2)
(get_local $a3)
@@ -31531,7 +31531,7 @@
)
)
(func $dynCall_vi (; 72 ;) (param $index i32) (param $a1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $a1)
(i32.add
(i32.and
diff --git a/test/emcc_hello_world.fromasm.no-opts b/test/emcc_hello_world.fromasm.no-opts
index cd4406395..dd84b963a 100644
--- a/test/emcc_hello_world.fromasm.no-opts
+++ b/test/emcc_hello_world.fromasm.no-opts
@@ -2551,7 +2551,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(i32.const 0)
(i32.const 0)
@@ -2841,7 +2841,7 @@
)
)
(set_local $$call4
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(get_local $$s)
(get_local $$l)
@@ -2972,7 +2972,7 @@
)
)
(set_local $$call16
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(get_local $$s)
(get_local $$i$0$lcssa36)
@@ -4451,7 +4451,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(i32.const 0)
(i32.const 0)
@@ -4550,7 +4550,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $$f)
(get_local $$sub$ptr$sub)
(i32.const 1)
@@ -31565,7 +31565,7 @@
)
(func $dynCall_ii (; 75 ;) (param $index i32) (param $a1 i32) (result i32)
(return
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $a1)
(i32.add
(i32.and
@@ -31579,7 +31579,7 @@
)
(func $dynCall_iiii (; 76 ;) (param $index i32) (param $a1 i32) (param $a2 i32) (param $a3 i32) (result i32)
(return
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a1)
(get_local $a2)
(get_local $a3)
@@ -31594,7 +31594,7 @@
)
)
(func $dynCall_vi (; 77 ;) (param $index i32) (param $a1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $a1)
(i32.add
(i32.and
diff --git a/test/example/c-api-kitchen-sink.txt b/test/example/c-api-kitchen-sink.txt
index 21c26791c..f33be1abd 100644
--- a/test/example/c-api-kitchen-sink.txt
+++ b/test/example/c-api-kitchen-sink.txt
@@ -468,7 +468,7 @@ BinaryenFloat64: 4
)
(drop
(i32.eqz
- (call_indirect $iiIfF
+ (call_indirect (type $iiIfF)
(i32.const 13)
(i64.const 37)
(f32.const 1.2999999523162842)
@@ -543,7 +543,7 @@ BinaryenFloat64: 4
(type $I (func (result i64)))
(memory $0 0)
(func $unreachable-fn (; 0 ;) (type $i) (result i32)
- (call_indirect $I
+ (call_indirect (type $I)
(unreachable)
)
)
@@ -1889,7 +1889,7 @@ int main() {
)
(drop
(i32.eqz
- (call_indirect $iiIfF
+ (call_indirect (type $iiIfF)
(i32.const 13)
(i64.const 37)
(f32.const 1.2999999523162842)
diff --git a/test/example/c-api-kitchen-sink.txt.txt b/test/example/c-api-kitchen-sink.txt.txt
index a14138166..f7a454507 100644
--- a/test/example/c-api-kitchen-sink.txt.txt
+++ b/test/example/c-api-kitchen-sink.txt.txt
@@ -463,7 +463,7 @@
)
(drop
(i32.eqz
- (call_indirect $iiIfF
+ (call_indirect (type $iiIfF)
(i32.const 13)
(i64.const 37)
(f32.const 1.2999999523162842)
diff --git a/test/llvm_autogenerated/call.wast b/test/llvm_autogenerated/call.wast
index 7aa279535..11b6fc306 100644
--- a/test/llvm_autogenerated/call.wast
+++ b/test/llvm_autogenerated/call.wast
@@ -74,20 +74,20 @@
)
)
(func $call_indirect_void (; 14 ;) (param $0 i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(get_local $0)
)
(return)
)
(func $call_indirect_i32 (; 15 ;) (param $0 i32) (result i32)
(return
- (call_indirect $FUNCSIG$i
+ (call_indirect (type $FUNCSIG$i)
(get_local $0)
)
)
)
(func $call_indirect_arg (; 16 ;) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(get_local $0)
)
@@ -95,7 +95,7 @@
)
(func $call_indirect_arg_2 (; 17 ;) (param $0 i32) (param $1 i32) (param $2 i32)
(drop
- (call_indirect $FUNCSIG$iii
+ (call_indirect (type $FUNCSIG$iii)
(get_local $1)
(get_local $2)
(get_local $0)
diff --git a/test/llvm_autogenerated/indirect-import.wast b/test/llvm_autogenerated/indirect-import.wast
index c9e6e3d88..909c229b6 100644
--- a/test/llvm_autogenerated/indirect-import.wast
+++ b/test/llvm_autogenerated/indirect-import.wast
@@ -153,18 +153,18 @@
)
)
(func $dynCall_fd (; 17 ;) (param $fptr i32) (param $0 f64) (result f32)
- (call_indirect $FUNCSIG$fd
+ (call_indirect (type $FUNCSIG$fd)
(get_local $0)
(get_local $fptr)
)
)
(func $dynCall_v (; 18 ;) (param $fptr i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(get_local $fptr)
)
)
(func $dynCall_vi (; 19 ;) (param $fptr i32) (param $0 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $0)
(get_local $fptr)
)
diff --git a/test/llvm_autogenerated/lower-em-ehsjlj-options.wast b/test/llvm_autogenerated/lower-em-ehsjlj-options.wast
index 848cb78cc..6fc2a9b56 100644
--- a/test/llvm_autogenerated/lower-em-ehsjlj-options.wast
+++ b/test/llvm_autogenerated/lower-em-ehsjlj-options.wast
@@ -145,7 +145,7 @@
(call $foo)
)
(func $dynCall_v (; 16 ;) (param $fptr i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(get_local $fptr)
)
)
diff --git a/test/llvm_autogenerated/reg-stackify.wast b/test/llvm_autogenerated/reg-stackify.wast
index e3c92b672..6a490cc7f 100644
--- a/test/llvm_autogenerated/reg-stackify.wast
+++ b/test/llvm_autogenerated/reg-stackify.wast
@@ -580,7 +580,7 @@
)
(func $call_indirect_stackify (; 36 ;) (param $0 i32) (param $1 i32) (result i32)
(return
- (call_indirect $FUNCSIG$iii
+ (call_indirect (type $FUNCSIG$iii)
(tee_local $0
(i32.load
(get_local $0)
diff --git a/test/memorygrowth.fromasm b/test/memorygrowth.fromasm
index e624d5ec4..7345d440e 100644
--- a/test/memorygrowth.fromasm
+++ b/test/memorygrowth.fromasm
@@ -8220,7 +8220,7 @@
)
(block
(set_local $4
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -8290,7 +8290,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -8763,7 +8763,7 @@
(set_local $4
(if (result i32)
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(get_local $6)
(i32.const 1)
@@ -8821,7 +8821,7 @@
)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -8882,7 +8882,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $2)
@@ -9672,7 +9672,7 @@
)
)
(func $lb (; 31 ;) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -9729,7 +9729,7 @@
)
)
(func $kb (; 35 ;) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -9750,7 +9750,7 @@
)
)
(func $mb (; 37 ;) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/memorygrowth.fromasm.clamp b/test/memorygrowth.fromasm.clamp
index e624d5ec4..7345d440e 100644
--- a/test/memorygrowth.fromasm.clamp
+++ b/test/memorygrowth.fromasm.clamp
@@ -8220,7 +8220,7 @@
)
(block
(set_local $4
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -8290,7 +8290,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -8763,7 +8763,7 @@
(set_local $4
(if (result i32)
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(get_local $6)
(i32.const 1)
@@ -8821,7 +8821,7 @@
)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -8882,7 +8882,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $2)
@@ -9672,7 +9672,7 @@
)
)
(func $lb (; 31 ;) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -9729,7 +9729,7 @@
)
)
(func $kb (; 35 ;) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -9750,7 +9750,7 @@
)
)
(func $mb (; 37 ;) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/memorygrowth.fromasm.clamp.no-opts b/test/memorygrowth.fromasm.clamp.no-opts
index 65caa61b1..46625f4b0 100644
--- a/test/memorygrowth.fromasm.clamp.no-opts
+++ b/test/memorygrowth.fromasm.clamp.no-opts
@@ -9839,7 +9839,7 @@
)
(block
(set_local $h
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $c)
(get_local $a)
(get_local $b)
@@ -9928,7 +9928,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $c)
(get_local $a)
(get_local $q)
@@ -10552,7 +10552,7 @@
)
(if
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a)
(get_local $d)
(i32.const 1)
@@ -10621,7 +10621,7 @@
)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a)
(i32.const 0)
(i32.const 0)
@@ -10691,7 +10691,7 @@
(get_local $h)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a)
(i32.sub
(get_local $f)
@@ -11814,7 +11814,7 @@
)
(func $lb (; 34 ;) (param $a i32) (param $b i32) (param $c i32) (param $d i32) (result i32)
(return
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $b)
(get_local $c)
(get_local $d)
@@ -11892,7 +11892,7 @@
)
(func $kb (; 39 ;) (param $a i32) (param $b i32) (result i32)
(return
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $b)
(i32.add
(i32.and
@@ -11921,7 +11921,7 @@
(return)
)
(func $mb (; 41 ;) (param $a i32) (param $b i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $b)
(i32.add
(i32.and
diff --git a/test/memorygrowth.fromasm.imprecise b/test/memorygrowth.fromasm.imprecise
index eb359fc61..acf1fdd59 100644
--- a/test/memorygrowth.fromasm.imprecise
+++ b/test/memorygrowth.fromasm.imprecise
@@ -8219,7 +8219,7 @@
)
(block
(set_local $4
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -8289,7 +8289,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -8762,7 +8762,7 @@
(set_local $4
(if (result i32)
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(get_local $6)
(i32.const 1)
@@ -8820,7 +8820,7 @@
)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -8881,7 +8881,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $2)
@@ -9667,7 +9667,7 @@
)
)
(func $lb (; 31 ;) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -9724,7 +9724,7 @@
)
)
(func $kb (; 35 ;) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -9745,7 +9745,7 @@
)
)
(func $mb (; 37 ;) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/memorygrowth.fromasm.imprecise.no-opts b/test/memorygrowth.fromasm.imprecise.no-opts
index 86b8b1266..86256f15a 100644
--- a/test/memorygrowth.fromasm.imprecise.no-opts
+++ b/test/memorygrowth.fromasm.imprecise.no-opts
@@ -9839,7 +9839,7 @@
)
(block
(set_local $h
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $c)
(get_local $a)
(get_local $b)
@@ -9928,7 +9928,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $c)
(get_local $a)
(get_local $q)
@@ -10552,7 +10552,7 @@
)
(if
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a)
(get_local $d)
(i32.const 1)
@@ -10621,7 +10621,7 @@
)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a)
(i32.const 0)
(i32.const 0)
@@ -10691,7 +10691,7 @@
(get_local $h)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a)
(i32.sub
(get_local $f)
@@ -11802,7 +11802,7 @@
)
(func $lb (; 33 ;) (param $a i32) (param $b i32) (param $c i32) (param $d i32) (result i32)
(return
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $b)
(get_local $c)
(get_local $d)
@@ -11880,7 +11880,7 @@
)
(func $kb (; 38 ;) (param $a i32) (param $b i32) (result i32)
(return
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $b)
(i32.add
(i32.and
@@ -11909,7 +11909,7 @@
(return)
)
(func $mb (; 40 ;) (param $a i32) (param $b i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $b)
(i32.add
(i32.and
diff --git a/test/memorygrowth.fromasm.no-opts b/test/memorygrowth.fromasm.no-opts
index 65caa61b1..46625f4b0 100644
--- a/test/memorygrowth.fromasm.no-opts
+++ b/test/memorygrowth.fromasm.no-opts
@@ -9839,7 +9839,7 @@
)
(block
(set_local $h
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $c)
(get_local $a)
(get_local $b)
@@ -9928,7 +9928,7 @@
)
(if
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $c)
(get_local $a)
(get_local $q)
@@ -10552,7 +10552,7 @@
)
(if
(i32.eq
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a)
(get_local $d)
(i32.const 1)
@@ -10621,7 +10621,7 @@
)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a)
(i32.const 0)
(i32.const 0)
@@ -10691,7 +10691,7 @@
(get_local $h)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $a)
(i32.sub
(get_local $f)
@@ -11814,7 +11814,7 @@
)
(func $lb (; 34 ;) (param $a i32) (param $b i32) (param $c i32) (param $d i32) (result i32)
(return
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $b)
(get_local $c)
(get_local $d)
@@ -11892,7 +11892,7 @@
)
(func $kb (; 39 ;) (param $a i32) (param $b i32) (result i32)
(return
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $b)
(i32.add
(i32.and
@@ -11921,7 +11921,7 @@
(return)
)
(func $mb (; 41 ;) (param $a i32) (param $b i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $b)
(i32.add
(i32.and
diff --git a/test/merge/basics.wast b/test/merge/basics.wast
index 7a234584b..b5fc97f7e 100644
--- a/test/merge/basics.wast
+++ b/test/merge/basics.wast
@@ -19,7 +19,7 @@
(call $only-a)
(call_import $some-func)
(call_import $some-collide)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 123)
(i32.const 456)
(i32.const 789)
diff --git a/test/merge/basics.wast.combined b/test/merge/basics.wast.combined
index ec322b100..e90b4f594 100644
--- a/test/merge/basics.wast.combined
+++ b/test/merge/basics.wast.combined
@@ -33,7 +33,7 @@
(call $only-a)
(call $some-func)
(call $some-collide)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 123)
(i32.const 456)
(i32.const 789)
@@ -67,7 +67,7 @@
(call $only-b)
(call $some-func-b)
(call $some-collide$0)
- (call_indirect $ii$0
+ (call_indirect (type $ii$0)
(i32.const 12)
(i32.const 34)
(i32.const 56)
diff --git a/test/merge/basics.wast.combined.finalized b/test/merge/basics.wast.combined.finalized
index ffa18e9f8..e25d70a6e 100644
--- a/test/merge/basics.wast.combined.finalized
+++ b/test/merge/basics.wast.combined.finalized
@@ -33,7 +33,7 @@
(call $only-a)
(call $some-func)
(call $some-collide)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 123)
(i32.const 456)
(i32.const 789)
@@ -67,7 +67,7 @@
(call $only-b)
(call $some-func-b)
(call $some-collide$0)
- (call_indirect $ii$0
+ (call_indirect (type $ii$0)
(i32.const 12)
(i32.const 34)
(i32.const 56)
diff --git a/test/merge/basics.wast.combined.finalized.opt b/test/merge/basics.wast.combined.finalized.opt
index 978e57dc8..d023ca183 100644
--- a/test/merge/basics.wast.combined.finalized.opt
+++ b/test/merge/basics.wast.combined.finalized.opt
@@ -25,7 +25,7 @@
(call $only-a)
(call $some-func)
(call $some-collide)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 123)
(i32.const 456)
(i32.const 789)
@@ -51,7 +51,7 @@
(call $only-b)
(call $some-func-b)
(call $some-collide$0)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 12)
(i32.const 34)
(i32.const 56)
diff --git a/test/merge/basics.wast.combined.opt b/test/merge/basics.wast.combined.opt
index 447b8affc..beddc7e0b 100644
--- a/test/merge/basics.wast.combined.opt
+++ b/test/merge/basics.wast.combined.opt
@@ -29,7 +29,7 @@
(call $only-a)
(call $some-func)
(call $some-collide)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 123)
(i32.const 456)
(i32.const 789)
@@ -59,7 +59,7 @@
(call $only-b)
(call $some-func-b)
(call $some-collide$0)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 12)
(i32.const 34)
(i32.const 56)
diff --git a/test/merge/basics.wast.toMerge b/test/merge/basics.wast.toMerge
index 5122afe31..954b95bce 100644
--- a/test/merge/basics.wast.toMerge
+++ b/test/merge/basics.wast.toMerge
@@ -20,7 +20,7 @@
(call $only-b)
(call $some-func-b)
(call_import $some-collide)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 12)
(i32.const 34)
(i32.const 56)
diff --git a/test/passes/code-folding.txt b/test/passes/code-folding.txt
index 646960a4e..031f93b91 100644
--- a/test/passes/code-folding.txt
+++ b/test/passes/code-folding.txt
@@ -10,7 +10,7 @@
(i32.const 1)
(block
(block $label$3
- (call_indirect $13
+ (call_indirect (type $13)
(block $label$4
(br $label$3)
)
diff --git a/test/passes/code-folding.wast b/test/passes/code-folding.wast
index ca1768c16..32a32b28b 100644
--- a/test/passes/code-folding.wast
+++ b/test/passes/code-folding.wast
@@ -7,7 +7,7 @@
(if
(i32.const 1)
(block $label$3
- (call_indirect $13
+ (call_indirect (type $13)
(block $label$4 (result f32) ;; but this type may change dangerously
(nop) ;; fold this
(br $label$3)
diff --git a/test/passes/dce.wast b/test/passes/dce.wast
index acabf6ca5..7050a383f 100644
--- a/test/passes/dce.wast
+++ b/test/passes/dce.wast
@@ -251,7 +251,7 @@
)
(if
(i32.const -1)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 123)
(i32.const 456)
(unreachable)
@@ -259,7 +259,7 @@
)
(if
(i32.const -2)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 139)
(unreachable)
(i32.const 0)
@@ -267,7 +267,7 @@
)
(if
(i32.const -3)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 246)
(unreachable)
(unreachable)
@@ -275,7 +275,7 @@
)
(if
(i32.const -4)
- (call_indirect $ii
+ (call_indirect (type $ii)
(unreachable)
(unreachable)
(unreachable)
diff --git a/test/passes/duplicate-function-elimination.txt b/test/passes/duplicate-function-elimination.txt
index 9499b0011..baf4fedf2 100644
--- a/test/passes/duplicate-function-elimination.txt
+++ b/test/passes/duplicate-function-elimination.txt
@@ -391,7 +391,7 @@
(elem (i32.const 0) $erase $erase)
(memory $0 0)
(func $erase (; 0 ;) (type $T)
- (call_indirect $T
+ (call_indirect (type $T)
(i32.const 0)
)
)
@@ -402,12 +402,12 @@
(elem (i32.const 0) $keep2 $other)
(memory $0 0)
(func $keep2 (; 0 ;) (type $T)
- (call_indirect $T
+ (call_indirect (type $T)
(i32.const 0)
)
)
(func $other (; 1 ;) (type $T)
- (call_indirect $T
+ (call_indirect (type $T)
(i32.const 1)
)
)
@@ -419,12 +419,12 @@
(elem (i32.const 0) $keep2 $other)
(memory $0 0)
(func $keep2 (; 0 ;) (type $T)
- (call_indirect $T
+ (call_indirect (type $T)
(i32.const 0)
)
)
(func $other (; 1 ;) (type $T)
- (call_indirect $S
+ (call_indirect (type $S)
(i32.const 0)
)
)
diff --git a/test/passes/duplicate-function-elimination.wast b/test/passes/duplicate-function-elimination.wast
index 2a01d61ec..b79032155 100644
--- a/test/passes/duplicate-function-elimination.wast
+++ b/test/passes/duplicate-function-elimination.wast
@@ -464,12 +464,12 @@
(table 2 2 anyfunc)
(elem (i32.const 0) $erase $other)
(func $erase (type $T)
- (call_indirect $T
+ (call_indirect (type $T)
(i32.const 0)
)
)
(func $other (type $T)
- (call_indirect $T
+ (call_indirect (type $T)
(i32.const 0)
)
)
@@ -480,12 +480,12 @@
(table 2 2 anyfunc)
(elem (i32.const 0) $keep2 $other)
(func $keep2 (type $T)
- (call_indirect $T
+ (call_indirect (type $T)
(i32.const 0)
)
)
(func $other (type $T)
- (call_indirect $T
+ (call_indirect (type $T)
(i32.const 1)
)
)
@@ -497,12 +497,12 @@
(table 2 2 anyfunc)
(elem (i32.const 0) $keep2 $other)
(func $keep2 (type $T)
- (call_indirect $T
+ (call_indirect (type $T)
(i32.const 0)
)
)
(func $other (type $T)
- (call_indirect $S
+ (call_indirect (type $S)
(i32.const 0)
)
)
diff --git a/test/passes/flatten.txt b/test/passes/flatten.txt
index b8ec0c49a..946c45ebe 100644
--- a/test/passes/flatten.txt
+++ b/test/passes/flatten.txt
@@ -1073,7 +1073,7 @@
(i32.const -1)
(block
(unreachable)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 123)
(i32.const 456)
(unreachable)
@@ -1086,7 +1086,7 @@
(i32.const -2)
(block
(unreachable)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 139)
(unreachable)
(i32.const 0)
@@ -1100,7 +1100,7 @@
(block
(unreachable)
(unreachable)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 246)
(unreachable)
(unreachable)
@@ -1115,7 +1115,7 @@
(unreachable)
(unreachable)
(unreachable)
- (call_indirect $ii
+ (call_indirect (type $ii)
(unreachable)
(unreachable)
(unreachable)
diff --git a/test/passes/flatten.wast b/test/passes/flatten.wast
index 92edd354d..35b009939 100644
--- a/test/passes/flatten.wast
+++ b/test/passes/flatten.wast
@@ -468,7 +468,7 @@
)
(if
(i32.const -1)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 123)
(i32.const 456)
(unreachable)
@@ -476,7 +476,7 @@
)
(if
(i32.const -2)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 139)
(unreachable)
(i32.const 0)
@@ -484,7 +484,7 @@
)
(if
(i32.const -3)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 246)
(unreachable)
(unreachable)
@@ -492,7 +492,7 @@
)
(if
(i32.const -4)
- (call_indirect $ii
+ (call_indirect (type $ii)
(unreachable)
(unreachable)
(unreachable)
diff --git a/test/passes/inlining-optimizing_optimize-level=3.txt b/test/passes/inlining-optimizing_optimize-level=3.txt
index ea3379c44..1bc6fe742 100644
--- a/test/passes/inlining-optimizing_optimize-level=3.txt
+++ b/test/passes/inlining-optimizing_optimize-level=3.txt
@@ -1256,7 +1256,7 @@
(get_local $13)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -1393,7 +1393,7 @@
)
(block $block30
(set_local $3
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -1458,7 +1458,7 @@
)
(br_if $label$break$L5
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -2083,7 +2083,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -2131,7 +2131,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $4)
@@ -15739,7 +15739,7 @@
)
)
(func $dynCall_ii (; 60 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -15748,7 +15748,7 @@
)
)
(func $dynCall_iiii (; 61 ;) (type $12) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -15762,7 +15762,7 @@
)
)
(func $dynCall_vi (; 62 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/passes/inlining-optimizing_optimize-level=3.wast b/test/passes/inlining-optimizing_optimize-level=3.wast
index 0370c1fda..ca357e548 100644
--- a/test/passes/inlining-optimizing_optimize-level=3.wast
+++ b/test/passes/inlining-optimizing_optimize-level=3.wast
@@ -1272,7 +1272,7 @@
(get_local $13)
(block
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -1412,7 +1412,7 @@
)
(block
(set_local $3
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $1)
@@ -1477,7 +1477,7 @@
)
(br_if $label$break$L5
(i32.lt_u
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $2)
(get_local $0)
(get_local $3)
@@ -2086,7 +2086,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -2134,7 +2134,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $4)
@@ -15649,7 +15649,7 @@
)
)
(func $dynCall_ii (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.and
(get_local $0)
@@ -15658,7 +15658,7 @@
)
)
(func $dynCall_iiii (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -15672,7 +15672,7 @@
)
)
(func $dynCall_vi (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
diff --git a/test/passes/print-call-graph.txt b/test/passes/print-call-graph.txt
index 129b4a37c..50c67d9d7 100644
--- a/test/passes/print-call-graph.txt
+++ b/test/passes/print-call-graph.txt
@@ -983,7 +983,7 @@ digraph call {
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -1031,7 +1031,7 @@ digraph call {
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $4)
@@ -1096,7 +1096,7 @@ digraph call {
(call $__ZSt15get_new_handlerv)
)
(block $block
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.add
(i32.and
(get_local $0)
@@ -1424,7 +1424,7 @@ digraph call {
(i32.const 0)
)
(func $dynCall_ii (; 35 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.add
(i32.and
@@ -1436,7 +1436,7 @@ digraph call {
)
)
(func $dynCall_iiii (; 36 ;) (type $7) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -1450,7 +1450,7 @@ digraph call {
)
)
(func $dynCall_vi (; 37 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
@@ -1462,7 +1462,7 @@ digraph call {
)
)
(func $dynCall_v (; 38 ;) (type $FUNCSIG$vi) (param $0 i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.add
(i32.and
(get_local $0)
diff --git a/test/passes/print-call-graph.wast b/test/passes/print-call-graph.wast
index 100648c1e..1a9eb2f42 100644
--- a/test/passes/print-call-graph.wast
+++ b/test/passes/print-call-graph.wast
@@ -868,7 +868,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.const 0)
(i32.const 0)
@@ -916,7 +916,7 @@
)
)
(drop
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $0)
(i32.sub
(get_local $4)
@@ -981,7 +981,7 @@
(call $__ZSt15get_new_handlerv)
)
(block
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.add
(i32.and
(get_local $0)
@@ -1309,7 +1309,7 @@
(i32.const 0)
)
(func $dynCall_ii (param $0 i32) (param $1 i32) (result i32)
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(get_local $1)
(i32.add
(i32.and
@@ -1321,7 +1321,7 @@
)
)
(func $dynCall_iiii (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
- (call_indirect $FUNCSIG$iiii
+ (call_indirect (type $FUNCSIG$iiii)
(get_local $1)
(get_local $2)
(get_local $3)
@@ -1335,7 +1335,7 @@
)
)
(func $dynCall_vi (param $0 i32) (param $1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $1)
(i32.add
(i32.and
@@ -1347,7 +1347,7 @@
)
)
(func $dynCall_v (param $0 i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.add
(i32.and
(get_local $0)
diff --git a/test/passes/remove-unused-module-elements.txt b/test/passes/remove-unused-module-elements.txt
index ecb888662..a577c187c 100644
--- a/test/passes/remove-unused-module-elements.txt
+++ b/test/passes/remove-unused-module-elements.txt
@@ -36,40 +36,40 @@
(call $called3)
)
(func $other1 (; 8 ;) (type $1) (param $0 i32)
- (call_indirect $0
+ (call_indirect (type $0)
(i32.const 0)
)
- (call_indirect $0
+ (call_indirect (type $0)
(i32.const 0)
)
- (call_indirect $0
+ (call_indirect (type $0)
(i32.const 0)
)
- (call_indirect $0
+ (call_indirect (type $0)
(i32.const 0)
)
- (call_indirect $1
+ (call_indirect (type $1)
(i32.const 0)
(i32.const 0)
)
- (call_indirect $1
+ (call_indirect (type $1)
(i32.const 0)
(i32.const 0)
)
(drop
- (call_indirect $2
+ (call_indirect (type $2)
(i32.const 0)
(i32.const 0)
)
)
(drop
- (call_indirect $2
+ (call_indirect (type $2)
(i32.const 0)
(i32.const 0)
)
)
(drop
- (call_indirect $2
+ (call_indirect (type $2)
(i32.const 0)
(i32.const 0)
)
diff --git a/test/passes/remove-unused-module-elements.wast b/test/passes/remove-unused-module-elements.wast
index e0ae7b4ec..4dfb9300f 100644
--- a/test/passes/remove-unused-module-elements.wast
+++ b/test/passes/remove-unused-module-elements.wast
@@ -55,15 +55,15 @@
(call $remove3)
)
(func $other1 (param i32) (type $1)
- (call_indirect $0 (i32.const 0))
- (call_indirect $0 (i32.const 0))
- (call_indirect $0-dupe (i32.const 0))
- (call_indirect $0-dupe (i32.const 0))
- (call_indirect $1 (i32.const 0) (i32.const 0))
- (call_indirect $1-dupe (i32.const 0) (i32.const 0))
- (drop (call_indirect $2 (i32.const 0) (i32.const 0)))
- (drop (call_indirect $2-dupe (i32.const 0) (i32.const 0)))
- (drop (call_indirect $2-thrupe (i32.const 0) (i32.const 0)))
+ (call_indirect (type $0) (i32.const 0))
+ (call_indirect (type $0) (i32.const 0))
+ (call_indirect (type $0-dupe) (i32.const 0))
+ (call_indirect (type $0-dupe) (i32.const 0))
+ (call_indirect (type $1) (i32.const 0) (i32.const 0))
+ (call_indirect (type $1-dupe) (i32.const 0) (i32.const 0))
+ (drop (call_indirect (type $2) (i32.const 0) (i32.const 0)))
+ (drop (call_indirect (type $2-dupe) (i32.const 0) (i32.const 0)))
+ (drop (call_indirect (type $2-thrupe) (i32.const 0) (i32.const 0)))
)
(func $other2 (param i32) (type $1-dupe)
(unreachable)
diff --git a/test/passes/remove-unused-names_merge-blocks.txt b/test/passes/remove-unused-names_merge-blocks.txt
index d5373adde..a46cacf47 100644
--- a/test/passes/remove-unused-names_merge-blocks.txt
+++ b/test/passes/remove-unused-names_merge-blocks.txt
@@ -694,12 +694,12 @@
(drop
(i32.const 50)
)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 20)
(i32.const 40)
(i32.const 60)
)
- (call_indirect $ii
+ (call_indirect (type $ii)
(unreachable)
(block (result i32)
(drop
@@ -717,7 +717,7 @@
(drop
(i32.const 31)
)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 41)
(unreachable)
(block (result i32)
@@ -733,7 +733,7 @@
(drop
(i32.const 52)
)
- (call_indirect $ii
+ (call_indirect (type $ii)
(i32.const 42)
(i32.const 62)
(unreachable)
diff --git a/test/passes/remove-unused-names_merge-blocks.wast b/test/passes/remove-unused-names_merge-blocks.wast
index 4cd7abe09..920664b4b 100644
--- a/test/passes/remove-unused-names_merge-blocks.wast
+++ b/test/passes/remove-unused-names_merge-blocks.wast
@@ -819,7 +819,7 @@
(i32.const 50)
)
)
- (call_indirect $ii
+ (call_indirect (type $ii)
(block $block18 (result i32)
(drop
(i32.const 10)
@@ -839,7 +839,7 @@
(i32.const 60)
)
)
- (call_indirect $ii
+ (call_indirect (type $ii)
(unreachable)
(block $block21 (result i32)
(drop
@@ -854,7 +854,7 @@
(i32.const 60)
)
)
- (call_indirect $ii
+ (call_indirect (type $ii)
(block $block21 (result i32)
(drop
(i32.const 31)
@@ -869,7 +869,7 @@
(i32.const 61)
)
)
- (call_indirect $ii
+ (call_indirect (type $ii)
(block $block21 (result i32)
(drop
(i32.const 32)
diff --git a/test/polymorphic_stack.wast b/test/polymorphic_stack.wast
index d0b9986ba..86993d5e1 100644
--- a/test/polymorphic_stack.wast
+++ b/test/polymorphic_stack.wast
@@ -33,7 +33,7 @@
)
(drop
(i64.eqz
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(unreachable)
(unreachable)
)
diff --git a/test/polymorphic_stack.wast.from-wast b/test/polymorphic_stack.wast.from-wast
index 5162969cd..f58d04ca8 100644
--- a/test/polymorphic_stack.wast.from-wast
+++ b/test/polymorphic_stack.wast.from-wast
@@ -37,7 +37,7 @@
)
(drop
(i64.eqz
- (call_indirect $FUNCSIG$ii
+ (call_indirect (type $FUNCSIG$ii)
(unreachable)
(unreachable)
)
diff --git a/test/reduce/memory_table.wast b/test/reduce/memory_table.wast
index 9e8ad4445..129d95155 100644
--- a/test/reduce/memory_table.wast
+++ b/test/reduce/memory_table.wast
@@ -23,8 +23,8 @@
)
(func $f4 (result i32)
(i32.add
- (call_indirect $i (i32.const 3))
- (call_indirect $i (i32.const 0))
+ (call_indirect (type $i) (i32.const 3))
+ (call_indirect (type $i) (i32.const 0))
)
)
)
diff --git a/test/reduce/memory_table.wast.txt b/test/reduce/memory_table.wast.txt
index 0a9a8a9e4..c8a265b1b 100644
--- a/test/reduce/memory_table.wast.txt
+++ b/test/reduce/memory_table.wast.txt
@@ -9,10 +9,10 @@
(export "f4" (func $0))
(func $0 (; 0 ;) (type $0) (result i32)
(i32.add
- (call_indirect $0
+ (call_indirect (type $0)
(i32.const 3)
)
- (call_indirect $0
+ (call_indirect (type $0)
(i32.const 0)
)
)
diff --git a/test/spec b/test/spec
-Subproject 8b1077b8a9e75054ec373b064a25fd23e9a3971
+Subproject 4b50c1c3f0d28c1a848866c6cdd0a1f469e1923
diff --git a/test/unit.fromasm b/test/unit.fromasm
index cae5357f0..c890b3a55 100644
--- a/test/unit.fromasm
+++ b/test/unit.fromasm
@@ -266,7 +266,7 @@
)
(func $neg (; 20 ;)
(local $0 f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(f32.neg
(get_local $0)
)
@@ -274,7 +274,7 @@
)
)
(func $cneg (; 21 ;) (param $0 f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $0)
(i32.const 9)
)
@@ -307,7 +307,7 @@
(get_local $0)
)
(func $cneg_nosemicolon (; 23 ;)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 1)
(i32.const 17)
)
@@ -1137,13 +1137,13 @@
)
)
(func $relocatableAndModules (; 56 ;) (result i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 10)
)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 20)
)
- (call_indirect $FUNCSIG$idi
+ (call_indirect (type $FUNCSIG$idi)
(f64.const 1.5)
(i32.const 200)
(i32.const 30)
@@ -1192,11 +1192,11 @@
(f64.const 100)
)
)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 0)
(i32.const 17)
)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 0)
(block (result i32)
(set_global $Int
diff --git a/test/unit.fromasm.clamp b/test/unit.fromasm.clamp
index 5d32c0f97..09c68d8f1 100644
--- a/test/unit.fromasm.clamp
+++ b/test/unit.fromasm.clamp
@@ -314,7 +314,7 @@
)
(func $neg (; 21 ;)
(local $0 f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(f32.neg
(get_local $0)
)
@@ -322,7 +322,7 @@
)
)
(func $cneg (; 22 ;) (param $0 f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $0)
(i32.const 9)
)
@@ -355,7 +355,7 @@
(get_local $0)
)
(func $cneg_nosemicolon (; 24 ;)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 1)
(i32.const 17)
)
@@ -1185,13 +1185,13 @@
)
)
(func $relocatableAndModules (; 57 ;) (result i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 10)
)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 20)
)
- (call_indirect $FUNCSIG$idi
+ (call_indirect (type $FUNCSIG$idi)
(f64.const 1.5)
(i32.const 200)
(i32.const 30)
@@ -1261,11 +1261,11 @@
(f64.const 100)
)
)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 0)
(i32.const 17)
)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 0)
(block (result i32)
(set_global $Int
diff --git a/test/unit.fromasm.clamp.no-opts b/test/unit.fromasm.clamp.no-opts
index ad698921e..6a576e3ca 100644
--- a/test/unit.fromasm.clamp.no-opts
+++ b/test/unit.fromasm.clamp.no-opts
@@ -615,7 +615,7 @@
(get_local $x)
)
)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $x)
(i32.add
(i32.and
@@ -627,7 +627,7 @@
)
)
(func $cneg (; 29 ;) (param $x f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $x)
(i32.add
(i32.and
@@ -677,7 +677,7 @@
)
)
(func $cneg_nosemicolon (; 32 ;)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 1)
(i32.add
(i32.and
@@ -1999,14 +1999,14 @@
)
)
(func $relocatableAndModules (; 71 ;) (result i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 10)
)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 20)
)
(return
- (call_indirect $FUNCSIG$idi
+ (call_indirect (type $FUNCSIG$idi)
(f64.const 1.5)
(i32.const 200)
(i32.const 30)
@@ -2112,7 +2112,7 @@
(local $i1 i32)
(set_local $i1
(block (result i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 0)
(i32.add
(i32.and
@@ -2128,7 +2128,7 @@
)
(func $emterpretify_assertions_safeHeap (; 79 ;)
(local $i1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $i1)
(i32.add
(i32.and
diff --git a/test/unit.fromasm.imprecise b/test/unit.fromasm.imprecise
index 41b365bdc..6cda1e7c1 100644
--- a/test/unit.fromasm.imprecise
+++ b/test/unit.fromasm.imprecise
@@ -255,7 +255,7 @@
)
(func $neg (; 19 ;)
(local $0 f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(f32.neg
(get_local $0)
)
@@ -263,7 +263,7 @@
)
)
(func $cneg (; 20 ;) (param $0 f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $0)
(i32.const 9)
)
@@ -296,7 +296,7 @@
(get_local $0)
)
(func $cneg_nosemicolon (; 22 ;)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 1)
(i32.const 17)
)
@@ -1126,13 +1126,13 @@
)
)
(func $relocatableAndModules (; 55 ;) (result i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 10)
)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 20)
)
- (call_indirect $FUNCSIG$idi
+ (call_indirect (type $FUNCSIG$idi)
(f64.const 1.5)
(i32.const 200)
(i32.const 30)
@@ -1166,11 +1166,11 @@
(f64.const 2.18281)
)
)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 0)
(i32.const 17)
)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 0)
(block (result i32)
(set_global $Int
diff --git a/test/unit.fromasm.imprecise.no-opts b/test/unit.fromasm.imprecise.no-opts
index f74ca4290..3e52e1c11 100644
--- a/test/unit.fromasm.imprecise.no-opts
+++ b/test/unit.fromasm.imprecise.no-opts
@@ -526,7 +526,7 @@
(get_local $x)
)
)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $x)
(i32.add
(i32.and
@@ -538,7 +538,7 @@
)
)
(func $cneg (; 25 ;) (param $x f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $x)
(i32.add
(i32.and
@@ -588,7 +588,7 @@
)
)
(func $cneg_nosemicolon (; 28 ;)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 1)
(i32.add
(i32.and
@@ -1910,14 +1910,14 @@
)
)
(func $relocatableAndModules (; 67 ;) (result i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 10)
)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 20)
)
(return
- (call_indirect $FUNCSIG$idi
+ (call_indirect (type $FUNCSIG$idi)
(f64.const 1.5)
(i32.const 200)
(i32.const 30)
@@ -1997,7 +1997,7 @@
(local $i1 i32)
(set_local $i1
(block (result i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 0)
(i32.add
(i32.and
@@ -2013,7 +2013,7 @@
)
(func $emterpretify_assertions_safeHeap (; 74 ;)
(local $i1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $i1)
(i32.add
(i32.and
diff --git a/test/unit.fromasm.no-opts b/test/unit.fromasm.no-opts
index b9cd7ce46..375c34af6 100644
--- a/test/unit.fromasm.no-opts
+++ b/test/unit.fromasm.no-opts
@@ -567,7 +567,7 @@
(get_local $x)
)
)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $x)
(i32.add
(i32.and
@@ -579,7 +579,7 @@
)
)
(func $cneg (; 28 ;) (param $x f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $x)
(i32.add
(i32.and
@@ -629,7 +629,7 @@
)
)
(func $cneg_nosemicolon (; 31 ;)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 1)
(i32.add
(i32.and
@@ -1951,14 +1951,14 @@
)
)
(func $relocatableAndModules (; 70 ;) (result i32)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 10)
)
- (call_indirect $FUNCSIG$v
+ (call_indirect (type $FUNCSIG$v)
(i32.const 20)
)
(return
- (call_indirect $FUNCSIG$idi
+ (call_indirect (type $FUNCSIG$idi)
(f64.const 1.5)
(i32.const 200)
(i32.const 30)
@@ -2038,7 +2038,7 @@
(local $i1 i32)
(set_local $i1
(block (result i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(i32.const 0)
(i32.add
(i32.and
@@ -2054,7 +2054,7 @@
)
(func $emterpretify_assertions_safeHeap (; 77 ;)
(local $i1 i32)
- (call_indirect $FUNCSIG$vi
+ (call_indirect (type $FUNCSIG$vi)
(get_local $i1)
(i32.add
(i32.and
diff --git a/test/unit.wast b/test/unit.wast
index c28e7b7f8..e1c6b602e 100644
--- a/test/unit.wast
+++ b/test/unit.wast
@@ -379,7 +379,7 @@
(get_local $x)
)
)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $x)
(i32.add
(i32.and
@@ -392,7 +392,7 @@
)
)
(func $cneg (type $FUNCSIG$vf) (param $x f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $x)
(i32.add
(i32.and
diff --git a/test/unit.wast.from-wast b/test/unit.wast.from-wast
index 8cc89255c..2ae39e64b 100644
--- a/test/unit.wast.from-wast
+++ b/test/unit.wast.from-wast
@@ -379,7 +379,7 @@
(get_local $x)
)
)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $x)
(i32.add
(i32.and
@@ -392,7 +392,7 @@
)
)
(func $cneg (; 18 ;) (type $FUNCSIG$vf) (param $x f32)
- (call_indirect $FUNCSIG$vf
+ (call_indirect (type $FUNCSIG$vf)
(get_local $x)
(i32.add
(i32.and
diff --git a/test/unit.wast.fromBinary b/test/unit.wast.fromBinary
index 6a902f38c..827fd5e6f 100644
--- a/test/unit.wast.fromBinary
+++ b/test/unit.wast.fromBinary
@@ -360,7 +360,7 @@
(get_local $var$0)
)
)
- (call_indirect $0
+ (call_indirect (type $0)
(get_local $var$0)
(i32.add
(i32.and
@@ -372,7 +372,7 @@
)
)
(func $cneg (; 18 ;) (type $0) (param $var$0 f32)
- (call_indirect $0
+ (call_indirect (type $0)
(get_local $var$0)
(i32.add
(i32.and
diff --git a/test/unit.wast.fromBinary.noDebugInfo b/test/unit.wast.fromBinary.noDebugInfo
index ceb7bf8ce..4fe3d9015 100644
--- a/test/unit.wast.fromBinary.noDebugInfo
+++ b/test/unit.wast.fromBinary.noDebugInfo
@@ -360,7 +360,7 @@
(get_local $var$0)
)
)
- (call_indirect $0
+ (call_indirect (type $0)
(get_local $var$0)
(i32.add
(i32.and
@@ -372,7 +372,7 @@
)
)
(func $15 (; 18 ;) (type $0) (param $var$0 f32)
- (call_indirect $0
+ (call_indirect (type $0)
(get_local $var$0)
(i32.add
(i32.and
diff --git a/test/wasm2asm/br_table_temp.wast b/test/wasm2asm/br_table_temp.wast
index c6314762d..abd66053a 100644
--- a/test/wasm2asm/br_table_temp.wast
+++ b/test/wasm2asm/br_table_temp.wast
@@ -983,7 +983,7 @@
(table anyfunc (elem $f))
(func (export "as-call_indirect-first") (result i32)
(block i32
- (call_indirect $sig
+ (call_indirect (type $sig)
(br_table 0 (i32.const 20) (i32.const 1)) (i32.const 1) (i32.const 2)
(i32.const 3)
)
@@ -991,7 +991,7 @@
)
(func (export "as-call_indirect-mid") (result i32)
(block i32
- (call_indirect $sig
+ (call_indirect (type $sig)
(i32.const 0) (br_table 0 (i32.const 21) (i32.const 1)) (i32.const 2)
(i32.const 3)
)
@@ -999,7 +999,7 @@
)
(func (export "as-call_indirect-last") (result i32)
(block i32
- (call_indirect $sig
+ (call_indirect (type $sig)
(i32.const 0) (i32.const 1) (br_table 0 (i32.const 22) (i32.const 1))
(i32.const 3)
)
@@ -1007,7 +1007,7 @@
)
(func (export "as-call_indirect-func") (result i32)
(block i32
- (call_indirect $sig
+ (call_indirect (type $sig)
(i32.const 0) (i32.const 1) (i32.const 2)
(br_table 0 (i32.const 23) (i32.const 1))
)