1 # RUN: llvm-mc -filetype=obj -triple=wasm32-unknown-unknown %s -o %t.o
2 # RUN: wasm-ld -o %t1.wasm %t.o
3 # RUN: obj2yaml %t1.wasm | FileCheck %s
8 .functype f1 () -> (i32)
10 # Same import module/name/type as `f1`, should be de-duped.
12 .import_module f2, env
14 .functype f2 () -> (i32)
16 # Same import module/name, but different type. Should not be de-duped.
18 .import_module f3, env
20 .functype f3 () -> (f32)
24 .functype _start () -> ()
35 # CHECK-NEXT: Signatures:
36 # CHECK-NEXT: - Index: 0
37 # CHECK-NEXT: ParamTypes: []
38 # CHECK-NEXT: ReturnTypes:
40 # CHECK-NEXT: - Index: 1
41 # CHECK-NEXT: ParamTypes: []
42 # CHECK-NEXT: ReturnTypes:
44 # CHECK-NEXT: - Index: 2
45 # CHECK-NEXT: ParamTypes: []
46 # CHECK-NEXT: ReturnTypes: []
47 # CHECK-NEXT: - Type: IMPORT
48 # CHECK-NEXT: Imports:
49 # CHECK-NEXT: - Module: env
50 # CHECK-NEXT: Field: f
51 # CHECK-NEXT: Kind: FUNCTION
52 # CHECK-NEXT: SigIndex: 0
53 # CHECK-NEXT: - Module: env
54 # CHECK-NEXT: Field: f
55 # CHECK-NEXT: Kind: FUNCTION
56 # CHECK-NEXT: SigIndex: 1