|
@@ -1,120 +1,52 @@
|
|
|
-diff --git a/test/core/binary.wast b/test/core/binary.wast
|
|
|
|
|
-index 891aad3..07356a3 100644
|
|
|
|
|
---- a/test/core/binary.wast
|
|
|
|
|
-+++ b/test/core/binary.wast
|
|
|
|
|
-@@ -206,7 +206,7 @@
|
|
|
|
|
- )
|
|
|
|
|
-
|
|
|
|
|
- ;; Type section with signed LEB128 encoded type
|
|
|
|
|
--(assert_malformed
|
|
|
|
|
-+(;assert_malformed
|
|
|
|
|
- (module binary
|
|
|
|
|
- "\00asm" "\01\00\00\00"
|
|
|
|
|
- "\01" ;; Type section id
|
|
|
|
|
-@@ -216,7 +216,7 @@
|
|
|
|
|
- "\00\00"
|
|
|
|
|
- )
|
|
|
|
|
- "integer representation too long"
|
|
|
|
|
--)
|
|
|
|
|
-+;)
|
|
|
|
|
-
|
|
|
|
|
- ;; Unsigned LEB128 must not be overlong
|
|
|
|
|
- (assert_malformed
|
|
|
|
|
-@@ -1683,7 +1683,7 @@
|
|
|
|
|
- )
|
|
|
|
|
-
|
|
|
|
|
- ;; 2 elem segment declared, 1 given
|
|
|
|
|
--(assert_malformed
|
|
|
|
|
-+(;assert_malformed
|
|
|
|
|
- (module binary
|
|
|
|
|
- "\00asm" "\01\00\00\00"
|
|
|
|
|
- "\01\04\01" ;; type section
|
|
|
|
|
-@@ -1696,7 +1696,7 @@
|
|
|
|
|
- ;; "\00\41\00\0b\01\00" ;; elem 1 (missed)
|
|
|
|
|
- )
|
|
|
|
|
- "unexpected end"
|
|
|
|
|
--)
|
|
|
|
|
-+;)
|
|
|
|
|
-
|
|
|
|
|
- ;; 2 elem segment declared, 1.5 given
|
|
|
|
|
- (assert_malformed
|
|
|
|
|
-@@ -1813,7 +1813,7 @@
|
|
|
|
|
- )
|
|
|
|
|
-
|
|
|
|
|
- ;; 1 br_table target declared, 2 given
|
|
|
|
|
--(assert_malformed
|
|
|
|
|
-+(;assert_malformed
|
|
|
|
|
- (module binary
|
|
|
|
|
- "\00asm" "\01\00\00\00"
|
|
|
|
|
- "\01\04\01" ;; type section
|
|
|
|
|
-@@ -1832,7 +1832,7 @@
|
|
|
|
|
- "\0b\0b\0b" ;; end
|
|
|
|
|
- )
|
|
|
|
|
- "unexpected end"
|
|
|
|
|
--)
|
|
|
|
|
-+;)
|
|
|
|
|
-
|
|
|
|
|
- ;; Start section
|
|
|
|
|
- (module binary
|
|
|
|
|
diff --git a/test/core/data.wast b/test/core/data.wast
|
|
diff --git a/test/core/data.wast b/test/core/data.wast
|
|
|
-index 4f339be..0b5b3e6 100644
|
|
|
|
|
|
|
+index b1e1239..a0f6967 100644
|
|
|
--- a/test/core/data.wast
|
|
--- a/test/core/data.wast
|
|
|
+++ b/test/core/data.wast
|
|
+++ b/test/core/data.wast
|
|
|
-@@ -306,9 +306,10 @@
|
|
|
|
|
|
|
+@@ -312,7 +312,8 @@
|
|
|
"\02\01\41\00\0b" ;; active data segment 0 for memory 1
|
|
"\02\01\41\00\0b" ;; active data segment 0 for memory 1
|
|
|
"\00" ;; empty vec(byte)
|
|
"\00" ;; empty vec(byte)
|
|
|
)
|
|
)
|
|
|
- "unknown memory 1"
|
|
- "unknown memory 1"
|
|
|
|
|
++ ;; TODO: restore after supporting multi memory"
|
|
|
+ "unknown memory"
|
|
+ "unknown memory"
|
|
|
)
|
|
)
|
|
|
|
|
|
|
|
-+(; not supported by wat2wasm
|
|
|
|
|
;; Data segment with memory index 0 (no memory section)
|
|
;; Data segment with memory index 0 (no memory section)
|
|
|
- (assert_invalid
|
|
|
|
|
- (module binary
|
|
|
|
|
-@@ -317,7 +318,7 @@
|
|
|
|
|
- "\00\41\00\0b" ;; active data segment 0 for memory 0
|
|
|
|
|
- "\00" ;; empty vec(byte)
|
|
|
|
|
- )
|
|
|
|
|
-- "unknown memory 0"
|
|
|
|
|
-+ "unknown memory"
|
|
|
|
|
- )
|
|
|
|
|
-
|
|
|
|
|
- ;; Data segment with memory index 1 (no memory section)
|
|
|
|
|
-@@ -328,7 +329,7 @@
|
|
|
|
|
|
|
+@@ -334,7 +335,8 @@
|
|
|
"\02\01\41\00\0b" ;; active data segment 0 for memory 1
|
|
"\02\01\41\00\0b" ;; active data segment 0 for memory 1
|
|
|
"\00" ;; empty vec(byte)
|
|
"\00" ;; empty vec(byte)
|
|
|
)
|
|
)
|
|
|
- "unknown memory 1"
|
|
- "unknown memory 1"
|
|
|
|
|
++ ;; TODO: restore after supporting multi memory"
|
|
|
+ "unknown memory"
|
|
+ "unknown memory"
|
|
|
)
|
|
)
|
|
|
|
|
|
|
|
;; Data segment with memory index 1 and vec(byte) as above,
|
|
;; Data segment with memory index 1 and vec(byte) as above,
|
|
|
-@@ -348,7 +349,7 @@
|
|
|
|
|
|
|
+@@ -354,7 +356,8 @@
|
|
|
"\20\21\22\23\24\25\26\27\28\29\2a\2b\2c\2d\2e\2f"
|
|
"\20\21\22\23\24\25\26\27\28\29\2a\2b\2c\2d\2e\2f"
|
|
|
"\30\31\32\33\34\35\36\37\38\39\3a\3b\3c\3d"
|
|
"\30\31\32\33\34\35\36\37\38\39\3a\3b\3c\3d"
|
|
|
)
|
|
)
|
|
|
- "unknown memory 1"
|
|
- "unknown memory 1"
|
|
|
|
|
++ ;; TODO: restore after supporting multi memory"
|
|
|
+ "unknown memory"
|
|
+ "unknown memory"
|
|
|
)
|
|
)
|
|
|
|
|
|
|
|
;; Data segment with memory index 1 and specially crafted vec(byte) after.
|
|
;; Data segment with memory index 1 and specially crafted vec(byte) after.
|
|
|
-@@ -368,8 +369,9 @@
|
|
|
|
|
|
|
+@@ -374,7 +377,8 @@
|
|
|
"\20\21\22\23\24\25\26\27\28\29\2a\2b\2c\2d\2e\2f"
|
|
"\20\21\22\23\24\25\26\27\28\29\2a\2b\2c\2d\2e\2f"
|
|
|
"\30\31\32\33\34\35\36\37\38\39\3a\3b\3c\3d"
|
|
"\30\31\32\33\34\35\36\37\38\39\3a\3b\3c\3d"
|
|
|
)
|
|
)
|
|
|
- "unknown memory 1"
|
|
- "unknown memory 1"
|
|
|
|
|
++ ;; TODO: restore after supporting multi memory"
|
|
|
+ "unknown memory"
|
|
+ "unknown memory"
|
|
|
)
|
|
)
|
|
|
-+;)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
- ;; Invalid offsets
|
|
|
|
|
diff --git a/test/core/elem.wast b/test/core/elem.wast
|
|
diff --git a/test/core/elem.wast b/test/core/elem.wast
|
|
|
-index 575ecef..6eecab9 100644
|
|
|
|
|
|
|
+index 33b3f67..c72431c 100644
|
|
|
--- a/test/core/elem.wast
|
|
--- a/test/core/elem.wast
|
|
|
+++ b/test/core/elem.wast
|
|
+++ b/test/core/elem.wast
|
|
|
-@@ -571,9 +571,11 @@
|
|
|
|
|
|
|
+@@ -595,9 +595,11 @@
|
|
|
(func $const-i32-d (type $out-i32) (i32.const 68))
|
|
(func $const-i32-d (type $out-i32) (i32.const 68))
|
|
|
)
|
|
)
|
|
|
|
|
|
|
@@ -126,7 +58,7 @@ index 575ecef..6eecab9 100644
|
|
|
|
|
|
|
|
(module $module3
|
|
(module $module3
|
|
|
(type $out-i32 (func (result i32)))
|
|
(type $out-i32 (func (result i32)))
|
|
|
-@@ -584,6 +586,8 @@
|
|
|
|
|
|
|
+@@ -608,9 +610,11 @@
|
|
|
(func $const-i32-f (type $out-i32) (i32.const 70))
|
|
(func $const-i32-f (type $out-i32) (i32.const 70))
|
|
|
)
|
|
)
|
|
|
|
|
|
|
@@ -135,219 +67,69 @@ index 575ecef..6eecab9 100644
|
|
|
(assert_return (invoke $module1 "call-8") (i32.const 69))
|
|
(assert_return (invoke $module1 "call-8") (i32.const 69))
|
|
|
(assert_return (invoke $module1 "call-9") (i32.const 70))
|
|
(assert_return (invoke $module1 "call-9") (i32.const 70))
|
|
|
+;)
|
|
+;)
|
|
|
-diff --git a/test/core/global.wast b/test/core/global.wast
|
|
|
|
|
-index 9fa5e22..8c4b949 100644
|
|
|
|
|
---- a/test/core/global.wast
|
|
|
|
|
-+++ b/test/core/global.wast
|
|
|
|
|
-@@ -328,10 +328,12 @@
|
|
|
|
|
- "type mismatch"
|
|
|
|
|
- )
|
|
|
|
|
|
|
|
|
|
-+(;
|
|
|
|
|
- (assert_invalid
|
|
|
|
|
- (module (global (import "" "") externref) (global funcref (global.get 0)))
|
|
|
|
|
- "type mismatch"
|
|
|
|
|
- )
|
|
|
|
|
-+;)
|
|
|
|
|
|
|
+ ;; Element segments must match element type of table
|
|
|
|
|
|
|
|
- (assert_invalid
|
|
|
|
|
- (module (global (import "test" "global-i32") i32) (global i32 (global.get 0) (global.get 0)))
|
|
|
|
|
-diff --git a/test/core/imports.wast b/test/core/imports.wast
|
|
|
|
|
-index 35e8c91..a7a459d 100644
|
|
|
|
|
---- a/test/core/imports.wast
|
|
|
|
|
-+++ b/test/core/imports.wast
|
|
|
|
|
-@@ -577,6 +577,7 @@
|
|
|
|
|
- (assert_return (invoke "grow" (i32.const 1)) (i32.const -1))
|
|
|
|
|
- (assert_return (invoke "grow" (i32.const 0)) (i32.const 2))
|
|
|
|
|
-
|
|
|
|
|
-+(; unsupported by multi-module currently
|
|
|
|
|
- (module $Mgm
|
|
|
|
|
- (memory (export "memory") 1) ;; initial size is 1
|
|
|
|
|
- (func (export "grow") (result i32) (memory.grow (i32.const 1)))
|
|
|
|
|
-@@ -596,6 +597,7 @@
|
|
|
|
|
- (func (export "size") (result i32) (memory.size))
|
|
|
|
|
- )
|
|
|
|
|
- (assert_return (invoke $Mgim2 "size") (i32.const 3))
|
|
|
|
|
-+;)
|
|
|
|
|
|
|
+@@ -643,6 +647,7 @@
|
|
|
|
|
|
|
|
-
|
|
|
|
|
- ;; Syntax errors
|
|
|
|
|
-diff --git a/test/core/linking.wast b/test/core/linking.wast
|
|
|
|
|
-index 994e0f4..d0bfb5f 100644
|
|
|
|
|
---- a/test/core/linking.wast
|
|
|
|
|
-+++ b/test/core/linking.wast
|
|
|
|
|
-@@ -64,6 +64,7 @@
|
|
|
|
|
- (export "Mg.set_mut" (func $set_mut))
|
|
|
|
|
- )
|
|
|
|
|
-
|
|
|
|
|
-+(;
|
|
|
|
|
- (assert_return (get $Mg "glob") (i32.const 42))
|
|
|
|
|
- (assert_return (get $Ng "Mg.glob") (i32.const 42))
|
|
|
|
|
- (assert_return (get $Ng "glob") (i32.const 43))
|
|
|
|
|
-@@ -81,6 +82,7 @@
|
|
|
|
|
- (assert_return (get $Ng "Mg.mut_glob") (i32.const 241))
|
|
|
|
|
- (assert_return (invoke $Mg "get_mut") (i32.const 241))
|
|
|
|
|
- (assert_return (invoke $Ng "Mg.get_mut") (i32.const 241))
|
|
|
|
|
-+;)
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
- (assert_unlinkable
|
|
|
|
|
-@@ -165,6 +167,7 @@
|
|
|
|
|
- )
|
|
|
|
|
- )
|
|
|
|
|
|
|
+ ;; Initializing a table with an externref-type element segment
|
|
|
|
|
|
|
|
+(;
|
|
+(;
|
|
|
- (assert_return (invoke $Mt "call" (i32.const 2)) (i32.const 4))
|
|
|
|
|
- (assert_return (invoke $Nt "Mt.call" (i32.const 2)) (i32.const 4))
|
|
|
|
|
- (assert_return (invoke $Nt "call" (i32.const 2)) (i32.const 5))
|
|
|
|
|
-@@ -187,6 +190,7 @@
|
|
|
|
|
-
|
|
|
|
|
- (assert_return (invoke $Nt "call" (i32.const 3)) (i32.const -4))
|
|
|
|
|
- (assert_trap (invoke $Nt "call" (i32.const 4)) "indirect call type mismatch")
|
|
|
|
|
-+;)
|
|
|
|
|
-
|
|
|
|
|
- (module $Ot
|
|
|
|
|
- (type (func (result i32)))
|
|
|
|
|
-@@ -201,6 +205,7 @@
|
|
|
|
|
- )
|
|
|
|
|
- )
|
|
|
|
|
-
|
|
|
|
|
-+(;
|
|
|
|
|
- (assert_return (invoke $Mt "call" (i32.const 3)) (i32.const 4))
|
|
|
|
|
- (assert_return (invoke $Nt "Mt.call" (i32.const 3)) (i32.const 4))
|
|
|
|
|
- (assert_return (invoke $Nt "call Mt.call" (i32.const 3)) (i32.const 4))
|
|
|
|
|
-@@ -225,6 +230,7 @@
|
|
|
|
|
- (assert_trap (invoke $Ot "call" (i32.const 0)) "uninitialized element")
|
|
|
|
|
-
|
|
|
|
|
- (assert_trap (invoke $Ot "call" (i32.const 20)) "undefined element")
|
|
|
|
|
-+;)
|
|
|
|
|
-
|
|
|
|
|
- (module
|
|
|
|
|
- (table (import "Mt" "tab") 0 funcref)
|
|
|
|
|
-@@ -263,6 +269,7 @@
|
|
|
|
|
-
|
|
|
|
|
- ;; Unlike in the v1 spec, active element segments stored before an
|
|
|
|
|
- ;; out-of-bounds access persist after the instantiation failure.
|
|
|
|
|
-+(;
|
|
|
|
|
- (assert_trap
|
|
|
|
|
- (module
|
|
|
|
|
- (table (import "Mt" "tab") 10 funcref)
|
|
|
|
|
-@@ -274,7 +281,9 @@
|
|
|
|
|
- )
|
|
|
|
|
- (assert_return (invoke $Mt "call" (i32.const 7)) (i32.const 0))
|
|
|
|
|
- (assert_trap (invoke $Mt "call" (i32.const 8)) "uninitialized element")
|
|
|
|
|
-+;)
|
|
|
|
|
-
|
|
|
|
|
-+(;
|
|
|
|
|
- (assert_trap
|
|
|
|
|
- (module
|
|
|
|
|
- (table (import "Mt" "tab") 10 funcref)
|
|
|
|
|
-@@ -286,6 +295,7 @@
|
|
|
|
|
- "out of bounds memory access"
|
|
|
|
|
- )
|
|
|
|
|
- (assert_return (invoke $Mt "call" (i32.const 7)) (i32.const 0))
|
|
|
|
|
-+;)
|
|
|
|
|
|
|
+ (module $m
|
|
|
|
|
+ (table $t (export "table") 2 externref)
|
|
|
|
|
+ (func (export "get") (param $i i32) (result externref)
|
|
|
|
|
+@@ -667,9 +672,11 @@
|
|
|
|
|
|
|
|
-
|
|
|
|
|
- (module $Mtable_ex
|
|
|
|
|
-@@ -299,6 +309,7 @@
|
|
|
|
|
- (table (import "Mtable_ex" "t-extern") 1 externref)
|
|
|
|
|
- )
|
|
|
|
|
-
|
|
|
|
|
-+(;
|
|
|
|
|
- (assert_unlinkable
|
|
|
|
|
- (module (table (import "Mtable_ex" "t-func") 1 externref))
|
|
|
|
|
- "incompatible import type"
|
|
|
|
|
-@@ -307,6 +318,7 @@
|
|
|
|
|
- (module (table (import "Mtable_ex" "t-extern") 1 funcref))
|
|
|
|
|
- "incompatible import type"
|
|
|
|
|
- )
|
|
|
|
|
|
|
+ (assert_return (invoke $m "get" (i32.const 0)) (ref.null extern))
|
|
|
|
|
+ (assert_return (invoke $m "get" (i32.const 1)) (ref.extern 137))
|
|
|
+;)
|
|
+;)
|
|
|
|
|
|
|
|
-
|
|
|
|
|
- ;; Memories
|
|
|
|
|
-@@ -346,10 +358,12 @@
|
|
|
|
|
- )
|
|
|
|
|
- )
|
|
|
|
|
|
|
+ ;; Initializing a table with imported funcref global
|
|
|
|
|
|
|
|
+(;
|
|
+(;
|
|
|
- (assert_return (invoke $Mm "load" (i32.const 12)) (i32.const 0xa7))
|
|
|
|
|
- (assert_return (invoke $Nm "Mm.load" (i32.const 12)) (i32.const 0xa7))
|
|
|
|
|
- (assert_return (invoke $Nm "load" (i32.const 12)) (i32.const 0xf2))
|
|
|
|
|
- (assert_return (invoke $Om "load" (i32.const 12)) (i32.const 0xa7))
|
|
|
|
|
-+;)
|
|
|
|
|
-
|
|
|
|
|
- (module
|
|
|
|
|
- (memory (import "Mm" "mem") 0)
|
|
|
|
|
-@@ -372,6 +386,7 @@
|
|
|
|
|
- )
|
|
|
|
|
|
|
+ (module $module4
|
|
|
|
|
+ (func (result i32)
|
|
|
|
|
+ i32.const 42
|
|
|
|
|
+@@ -690,3 +697,4 @@
|
|
|
)
|
|
)
|
|
|
|
|
|
|
|
-+(;
|
|
|
|
|
- (assert_return (invoke $Pm "grow" (i32.const 0)) (i32.const 1))
|
|
|
|
|
- (assert_return (invoke $Pm "grow" (i32.const 2)) (i32.const 1))
|
|
|
|
|
- (assert_return (invoke $Pm "grow" (i32.const 0)) (i32.const 3))
|
|
|
|
|
-@@ -380,6 +395,7 @@
|
|
|
|
|
- (assert_return (invoke $Pm "grow" (i32.const 0)) (i32.const 5))
|
|
|
|
|
- (assert_return (invoke $Pm "grow" (i32.const 1)) (i32.const -1))
|
|
|
|
|
- (assert_return (invoke $Pm "grow" (i32.const 0)) (i32.const 5))
|
|
|
|
|
-+;)
|
|
|
|
|
-
|
|
|
|
|
- (assert_unlinkable
|
|
|
|
|
- (module
|
|
|
|
|
-@@ -403,8 +419,10 @@
|
|
|
|
|
- )
|
|
|
|
|
- "out of bounds memory access"
|
|
|
|
|
- )
|
|
|
|
|
-+(;
|
|
|
|
|
- (assert_return (invoke $Mm "load" (i32.const 0)) (i32.const 97))
|
|
|
|
|
- (assert_return (invoke $Mm "load" (i32.const 327670)) (i32.const 0))
|
|
|
|
|
|
|
+ (assert_return (invoke "call_imported_elem") (i32.const 42))
|
|
|
+;)
|
|
+;)
|
|
|
-
|
|
|
|
|
- (assert_trap
|
|
|
|
|
- (module
|
|
|
|
|
-@@ -416,7 +434,9 @@
|
|
|
|
|
|
|
+\ No newline at end of file
|
|
|
|
|
+diff --git a/test/core/if.wast b/test/core/if.wast
|
|
|
|
|
+index 2ea45f6..6f07304 100644
|
|
|
|
|
+--- a/test/core/if.wast
|
|
|
|
|
++++ b/test/core/if.wast
|
|
|
|
|
+@@ -530,7 +530,10 @@
|
|
|
|
|
+ (func (export "atypical-condition")
|
|
|
|
|
+ i32.const 0
|
|
|
|
|
+ (if (then) (else))
|
|
|
|
|
+- (if (i32.const 1) (i32.eqz) (then) (else))
|
|
|
|
|
++ ;; restore after wabt(> 1.34.0) supports it
|
|
|
|
|
++ (i32.const 1)
|
|
|
|
|
++ (i32.eqz)
|
|
|
|
|
++ (if (then) (else))
|
|
|
)
|
|
)
|
|
|
- "out of bounds table access"
|
|
|
|
|
- )
|
|
|
|
|
-+(;
|
|
|
|
|
- (assert_return (invoke $Mm "load" (i32.const 0)) (i32.const 97))
|
|
|
|
|
-+;)
|
|
|
|
|
-
|
|
|
|
|
- ;; Store is modified if the start function traps.
|
|
|
|
|
- (module $Ms
|
|
|
|
|
-@@ -432,6 +452,7 @@
|
|
|
|
|
)
|
|
)
|
|
|
- (register "Ms" $Ms)
|
|
|
|
|
-
|
|
|
|
|
-+(;
|
|
|
|
|
- (assert_trap
|
|
|
|
|
- (module
|
|
|
|
|
- (import "Ms" "memory" (memory 1))
|
|
|
|
|
-@@ -451,3 +472,4 @@
|
|
|
|
|
|
|
|
|
|
- (assert_return (invoke $Ms "get memory[0]") (i32.const 104)) ;; 'h'
|
|
|
|
|
- (assert_return (invoke $Ms "get table[0]") (i32.const 0xdead))
|
|
|
|
|
-+;)
|
|
|
|
|
diff --git a/test/core/ref_func.wast b/test/core/ref_func.wast
|
|
diff --git a/test/core/ref_func.wast b/test/core/ref_func.wast
|
|
|
-index adb5cb7..590f626 100644
|
|
|
|
|
|
|
+index adb5cb7..6396013 100644
|
|
|
--- a/test/core/ref_func.wast
|
|
--- a/test/core/ref_func.wast
|
|
|
+++ b/test/core/ref_func.wast
|
|
+++ b/test/core/ref_func.wast
|
|
|
-@@ -4,7 +4,8 @@
|
|
|
|
|
|
|
+@@ -4,7 +4,7 @@
|
|
|
(register "M")
|
|
(register "M")
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
- (func $f (import "M" "f") (param i32) (result i32))
|
|
- (func $f (import "M" "f") (param i32) (result i32))
|
|
|
-+ (; aot mode does not support module linking ;)
|
|
|
|
|
+ (func $f (param $x i32) (result i32) (local.get $x))
|
|
+ (func $f (param $x i32) (result i32) (local.get $x))
|
|
|
(func $g (param $x i32) (result i32)
|
|
(func $g (param $x i32) (result i32)
|
|
|
(i32.add (local.get $x) (i32.const 1))
|
|
(i32.add (local.get $x) (i32.const 1))
|
|
|
)
|
|
)
|
|
|
diff --git a/test/core/table_copy.wast b/test/core/table_copy.wast
|
|
diff --git a/test/core/table_copy.wast b/test/core/table_copy.wast
|
|
|
-index 380e84e..f37e745 100644
|
|
|
|
|
|
|
+index 380e84e..59230cf 100644
|
|
|
--- a/test/core/table_copy.wast
|
|
--- a/test/core/table_copy.wast
|
|
|
+++ b/test/core/table_copy.wast
|
|
+++ b/test/core/table_copy.wast
|
|
|
-@@ -14,11 +14,12 @@
|
|
|
|
|
|
|
+@@ -14,11 +14,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -356,16 +138,15 @@ index 380e84e..f37e745 100644
|
|
|
- (import "a" "ef2" (func (result i32)))
|
|
- (import "a" "ef2" (func (result i32)))
|
|
|
- (import "a" "ef3" (func (result i32)))
|
|
- (import "a" "ef3" (func (result i32)))
|
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
|
-+ ;; aot mode does not support module linking
|
|
|
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -106,11 +107,11 @@
|
|
|
|
|
|
|
+@@ -106,11 +106,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -374,15 +155,15 @@ index 380e84e..f37e745 100644
|
|
|
- (import "a" "ef2" (func (result i32)))
|
|
- (import "a" "ef2" (func (result i32)))
|
|
|
- (import "a" "ef3" (func (result i32)))
|
|
- (import "a" "ef3" (func (result i32)))
|
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
|
-+ (func (export "ef0") (result i32) (i32.const 0)) ;; index 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)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 0)) ;; index 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)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -198,11 +199,11 @@
|
|
|
|
|
|
|
+@@ -198,11 +198,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -395,11 +176,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -290,11 +291,11 @@
|
|
|
|
|
|
|
+@@ -290,11 +290,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -412,11 +193,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -382,11 +383,11 @@
|
|
|
|
|
|
|
+@@ -382,11 +382,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -429,11 +210,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -474,11 +475,11 @@
|
|
|
|
|
|
|
+@@ -474,11 +474,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -446,11 +227,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -566,11 +567,11 @@
|
|
|
|
|
|
|
+@@ -566,11 +566,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -463,11 +244,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -658,11 +659,11 @@
|
|
|
|
|
|
|
+@@ -658,11 +658,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -480,11 +261,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -750,11 +751,11 @@
|
|
|
|
|
|
|
+@@ -750,11 +750,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -497,11 +278,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -842,11 +843,11 @@
|
|
|
|
|
|
|
+@@ -842,11 +842,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -514,11 +295,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -934,11 +935,11 @@
|
|
|
|
|
|
|
+@@ -934,11 +934,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -531,11 +312,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -1026,11 +1027,11 @@
|
|
|
|
|
|
|
+@@ -1026,11 +1026,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -548,11 +329,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -1118,11 +1119,11 @@
|
|
|
|
|
|
|
+@@ -1118,11 +1118,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -565,11 +346,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -1210,11 +1211,11 @@
|
|
|
|
|
|
|
+@@ -1210,11 +1210,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -582,11 +363,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -1302,11 +1303,11 @@
|
|
|
|
|
|
|
+@@ -1302,11 +1302,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -599,11 +380,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -1394,11 +1395,11 @@
|
|
|
|
|
|
|
+@@ -1394,11 +1394,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -616,11 +397,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -1486,11 +1487,11 @@
|
|
|
|
|
|
|
+@@ -1486,11 +1486,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -633,11 +414,11 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -1578,11 +1579,11 @@
|
|
|
|
|
|
|
+@@ -1578,11 +1578,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -650,15 +431,15 @@ index 380e84e..f37e745 100644
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
|
+ (func (result i32) (i32.const 3))
|
|
+ (func (result i32) (i32.const 3))
|
|
|
-+ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
|
|
|
|
++ (func (result i32) (i32.const 4)) ;; index 4
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
diff --git a/test/core/table_init.wast b/test/core/table_init.wast
|
|
diff --git a/test/core/table_init.wast b/test/core/table_init.wast
|
|
|
-index 0b2d26f..bdab6a0 100644
|
|
|
|
|
|
|
+index 0b2d26f..3c595e5 100644
|
|
|
--- a/test/core/table_init.wast
|
|
--- a/test/core/table_init.wast
|
|
|
+++ b/test/core/table_init.wast
|
|
+++ b/test/core/table_init.wast
|
|
|
-@@ -14,11 +14,12 @@
|
|
|
|
|
|
|
+@@ -14,11 +14,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -667,7 +448,6 @@ index 0b2d26f..bdab6a0 100644
|
|
|
- (import "a" "ef2" (func (result i32)))
|
|
- (import "a" "ef2" (func (result i32)))
|
|
|
- (import "a" "ef3" (func (result i32)))
|
|
- (import "a" "ef3" (func (result i32)))
|
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
|
-+ ;; aot mode does not support module linking
|
|
|
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
@@ -676,7 +456,7 @@ index 0b2d26f..bdab6a0 100644
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -72,11 +73,12 @@
|
|
|
|
|
|
|
+@@ -72,11 +72,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -685,7 +465,6 @@ index 0b2d26f..bdab6a0 100644
|
|
|
- (import "a" "ef2" (func (result i32)))
|
|
- (import "a" "ef2" (func (result i32)))
|
|
|
- (import "a" "ef3" (func (result i32)))
|
|
- (import "a" "ef3" (func (result i32)))
|
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
|
-+ ;; aot mode does not support module linking
|
|
|
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
@@ -694,7 +473,7 @@ index 0b2d26f..bdab6a0 100644
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -130,11 +132,12 @@
|
|
|
|
|
|
|
+@@ -130,11 +130,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -703,7 +482,6 @@ index 0b2d26f..bdab6a0 100644
|
|
|
- (import "a" "ef2" (func (result i32)))
|
|
- (import "a" "ef2" (func (result i32)))
|
|
|
- (import "a" "ef3" (func (result i32)))
|
|
- (import "a" "ef3" (func (result i32)))
|
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
|
-+ ;; aot mode does not support module linking
|
|
|
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
@@ -712,7 +490,7 @@ index 0b2d26f..bdab6a0 100644
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t0) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -196,11 +199,12 @@
|
|
|
|
|
|
|
+@@ -196,11 +196,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -721,7 +499,6 @@ index 0b2d26f..bdab6a0 100644
|
|
|
- (import "a" "ef2" (func (result i32)))
|
|
- (import "a" "ef2" (func (result i32)))
|
|
|
- (import "a" "ef3" (func (result i32)))
|
|
- (import "a" "ef3" (func (result i32)))
|
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
|
-+ ;; aot mode does not support module linking
|
|
|
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
@@ -730,7 +507,7 @@ index 0b2d26f..bdab6a0 100644
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -254,11 +258,12 @@
|
|
|
|
|
|
|
+@@ -254,11 +254,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -739,7 +516,6 @@ index 0b2d26f..bdab6a0 100644
|
|
|
- (import "a" "ef2" (func (result i32)))
|
|
- (import "a" "ef2" (func (result i32)))
|
|
|
- (import "a" "ef3" (func (result i32)))
|
|
- (import "a" "ef3" (func (result i32)))
|
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
|
-+ ;; aot mode does not support module linking
|
|
|
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
@@ -748,7 +524,7 @@ index 0b2d26f..bdab6a0 100644
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-@@ -312,11 +317,12 @@
|
|
|
|
|
|
|
+@@ -312,11 +312,11 @@
|
|
|
|
|
|
|
|
(module
|
|
(module
|
|
|
(type (func (result i32))) ;; type #0
|
|
(type (func (result i32))) ;; type #0
|
|
@@ -757,7 +533,6 @@ index 0b2d26f..bdab6a0 100644
|
|
|
- (import "a" "ef2" (func (result i32)))
|
|
- (import "a" "ef2" (func (result i32)))
|
|
|
- (import "a" "ef3" (func (result i32)))
|
|
- (import "a" "ef3" (func (result i32)))
|
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
- (import "a" "ef4" (func (result i32))) ;; index 4
|
|
|
-+ ;; aot mode does not support module linking
|
|
|
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
+ (func (result i32) (i32.const 0)) ;; index 0
|
|
|
+ (func (result i32) (i32.const 1))
|
|
+ (func (result i32) (i32.const 1))
|
|
|
+ (func (result i32) (i32.const 2))
|
|
+ (func (result i32) (i32.const 2))
|
|
@@ -766,20 +541,3 @@ index 0b2d26f..bdab6a0 100644
|
|
|
(table $t0 30 30 funcref)
|
|
(table $t0 30 30 funcref)
|
|
|
(table $t1 30 30 funcref)
|
|
(table $t1 30 30 funcref)
|
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
(elem (table $t1) (i32.const 2) func 3 1 4 1)
|
|
|
-diff --git a/test/core/unreached-valid.wast b/test/core/unreached-valid.wast
|
|
|
|
|
-index b7ebabf..4f2abfb 100644
|
|
|
|
|
---- a/test/core/unreached-valid.wast
|
|
|
|
|
-+++ b/test/core/unreached-valid.wast
|
|
|
|
|
-@@ -46,6 +46,7 @@
|
|
|
|
|
-
|
|
|
|
|
- ;; Validation after unreachable
|
|
|
|
|
-
|
|
|
|
|
-+(;
|
|
|
|
|
- (module
|
|
|
|
|
- (func (export "meet-bottom")
|
|
|
|
|
- (block (result f64)
|
|
|
|
|
-@@ -61,3 +62,4 @@
|
|
|
|
|
- )
|
|
|
|
|
-
|
|
|
|
|
- (assert_trap (invoke "meet-bottom") "unreachable")
|
|
|
|
|
-+;)
|
|
|