1 ; RUN: llvm-mc -filetype=obj -triple=wasm32-unknown-unknown %p/Inputs/ret32.s -o %t.ret32.o
2 ; RUN: llc -filetype=obj %s -o %t.o
3 ; RUN: wasm-ld -o %t.wasm %t.o %t.ret32.o
4 ; RUN: obj2yaml %t.wasm | FileCheck %s
6 target triple = "wasm32-unknown-unknown"
8 ; Function Attrs: nounwind
9 define hidden void @_start() local_unnamed_addr #0 {
11 %call = tail call i32 @ret32(float 0.000000e+00) #2
15 declare i32 @ret32(float) local_unnamed_addr #1
19 ; CHECK-NEXT: - Index: 0
20 ; CHECK-NEXT: ParamTypes: []
21 ; CHECK-NEXT: ReturnTypes: []
22 ; CHECK-NEXT: - Index: 1
23 ; CHECK-NEXT: ParamTypes:
25 ; CHECK-NEXT: ReturnTypes:
27 ; CHECK: - Type: FUNCTION
28 ; CHECK-NEXT: FunctionTypes: [ 0, 1 ]
30 ; CHECK-NEXT: Functions:
31 ; CHECK-NEXT: - Index: 0
33 ; CHECK-NEXT: Body: 43000000001081808080001A0B
34 ; CHECK-NEXT: - Index: 1
36 ; CHECK-NEXT: Body: 41000B
37 ; CHECK-NEXT: - Type: CUSTOM
38 ; CHECK-NEXT: Name: name
39 ; CHECK-NEXT: FunctionNames:
40 ; CHECK-NEXT: - Index: 0
41 ; CHECK-NEXT: Name: _start
42 ; CHECK-NEXT: - Index: 1
43 ; CHECK-NEXT: Name: ret32
44 ; CHECK-NEXT: GlobalNames:
45 ; CHECK-NEXT: - Index: 0
46 ; CHECK-NEXT: Name: __stack_pointer