diff options
Diffstat (limited to 'test/lit/passes/merge-similar-functions_all-features.wast')
-rw-r--r-- | test/lit/passes/merge-similar-functions_all-features.wast | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/test/lit/passes/merge-similar-functions_all-features.wast b/test/lit/passes/merge-similar-functions_all-features.wast index 661a55f66..ddc9a200f 100644 --- a/test/lit/passes/merge-similar-functions_all-features.wast +++ b/test/lit/passes/merge-similar-functions_all-features.wast @@ -2,22 +2,22 @@ ;; RUN: foreach %s %t wasm-opt --all-features --merge-similar-functions -S -o - | filecheck %s (module - ;; CHECK: (type $none_=>_none (func)) + ;; CHECK: (type $0 (func)) ;; CHECK: (type $[i8] (array i8)) (type $[i8] (array i8)) - ;; CHECK: (type $arrayref_=>_none (func (param arrayref))) + ;; CHECK: (type $2 (func (param arrayref))) - ;; CHECK: (type $ref|eq|_=>_none (func (param (ref eq)))) + ;; CHECK: (type $3 (func (param (ref eq)))) - ;; CHECK: (func $take-ref-null-array (type $arrayref_=>_none) (param $0 arrayref) + ;; CHECK: (func $take-ref-null-array (type $2) (param $0 arrayref) ;; CHECK-NEXT: (unreachable) ;; CHECK-NEXT: ) (func $take-ref-null-array (param (ref null array)) (unreachable) ) - ;; CHECK: (func $take-ref-eq (type $ref|eq|_=>_none) (param $0 (ref eq)) + ;; CHECK: (func $take-ref-eq (type $3) (param $0 (ref eq)) ;; CHECK-NEXT: (unreachable) ;; CHECK-NEXT: ) (func $take-ref-eq (param (ref eq)) @@ -30,7 +30,7 @@ ;; But in general, type B and C don't have a common subtype, so ;; we can't merge call instructions of func X and Y. - ;; CHECK: (func $no-call-subtyping-same-operand-0 (type $none_=>_none) + ;; CHECK: (func $no-call-subtyping-same-operand-0 (type $0) ;; CHECK-NEXT: (nop) ;; CHECK-NEXT: (nop) ;; CHECK-NEXT: (nop) @@ -61,7 +61,7 @@ (array.new_fixed $[i8] 0) ) ) - ;; CHECK: (func $no-call-subtyping-same-operand-1 (type $none_=>_none) + ;; CHECK: (func $no-call-subtyping-same-operand-1 (type $0) ;; CHECK-NEXT: (nop) ;; CHECK-NEXT: (nop) ;; CHECK-NEXT: (nop) @@ -96,13 +96,13 @@ ;; Test that we can merge properly when there is a return_call. (module - ;; CHECK: (type $none_=>_i32 (func (result i32))) + ;; CHECK: (type $0 (func (result i32))) - ;; CHECK: (type $ref|none_->_i32|_=>_i32 (func (param (ref $none_=>_i32)) (result i32))) + ;; CHECK: (type $1 (func (param (ref $0)) (result i32))) ;; CHECK: (elem declare func $return_a $return_b) - ;; CHECK: (func $return_call_a (type $none_=>_i32) (result i32) + ;; CHECK: (func $return_call_a (type $0) (result i32) ;; CHECK-NEXT: (call $byn$mgfn-shared$return_call_a ;; CHECK-NEXT: (ref.func $return_a) ;; CHECK-NEXT: ) @@ -114,7 +114,7 @@ (return_call $return_a) ) - ;; CHECK: (func $return_call_b (type $none_=>_i32) (result i32) + ;; CHECK: (func $return_call_b (type $0) (result i32) ;; CHECK-NEXT: (call $byn$mgfn-shared$return_call_a ;; CHECK-NEXT: (ref.func $return_b) ;; CHECK-NEXT: ) @@ -127,7 +127,7 @@ (return_call $return_b) ) - ;; CHECK: (func $return_a (type $none_=>_i32) (result i32) + ;; CHECK: (func $return_a (type $0) (result i32) ;; CHECK-NEXT: (i32.const 0) ;; CHECK-NEXT: ) (func $return_a (result i32) @@ -135,7 +135,7 @@ (i32.const 0) ) - ;; CHECK: (func $return_b (type $none_=>_i32) (result i32) + ;; CHECK: (func $return_b (type $0) (result i32) ;; CHECK-NEXT: (i32.const 1) ;; CHECK-NEXT: ) (func $return_b (result i32) @@ -143,7 +143,7 @@ (i32.const 1) ) ) -;; CHECK: (func $byn$mgfn-shared$return_call_a (type $ref|none_->_i32|_=>_i32) (param $0 (ref $none_=>_i32)) (result i32) +;; CHECK: (func $byn$mgfn-shared$return_call_a (type $1) (param $0 (ref $0)) (result i32) ;; CHECK-NEXT: (nop) ;; CHECK-NEXT: (nop) ;; CHECK-NEXT: (nop) @@ -162,7 +162,7 @@ ;; CHECK-NEXT: (nop) ;; CHECK-NEXT: (nop) ;; CHECK-NEXT: (nop) -;; CHECK-NEXT: (return_call_ref $none_=>_i32 +;; CHECK-NEXT: (return_call_ref $0 ;; CHECK-NEXT: (local.get $0) ;; CHECK-NEXT: ) ;; CHECK-NEXT: ) |