1# RUN: yaml2obj %s -o %t.so 2# RUN: llvm-objdump -t %t.so | FileCheck %s 3# 4# CHECK: SYMBOL TABLE: 5# CHECK-NEXT: 00000001 g F CODE 00000003 my_func_export 6# CHECK-NEXT: 0000002a g O DATA 00000000 my_global_export 7 8--- !WASM 9FileHeader: 10 Version: 0x1 11Sections: 12 - Type: CUSTOM 13 Name: dylink.0 14 MemorySize: 15 15 MemoryAlignment: 0 16 TableSize: 0 17 TableAlignment: 0 18 Needed: [] 19 - Type: TYPE 20 Signatures: 21 - Index: 0 22 ParamTypes: [] 23 ReturnTypes: [] 24 - Type: IMPORT 25 Imports: 26 - Module: env 27 Field: foo 28 Kind: FUNCTION 29 SigIndex: 0 30 - Module: env 31 Field: bar 32 Kind: GLOBAL 33 GlobalType: I32 34 GlobalMutable: true 35 - Module: env 36 Field: memory 37 Kind: MEMORY 38 Memory: 39 Minimum: 0x1 40 - Type: FUNCTION 41 FunctionTypes: [ 0 ] 42 - Type: GLOBAL 43 Globals: 44 - Index: 1 45 Mutable: false 46 Type: I32 47 InitExpr: 48 Opcode: I32_CONST 49 Value: 42 50 - Type: EXPORT 51 Exports: 52 - Name: my_func_export 53 Kind: FUNCTION 54 Index: 1 55 - Name: my_global_export 56 Kind: GLOBAL 57 Index: 1 58 - Type: CODE 59 Functions: 60 - Index: 1 61 Locals: 62 Body: 00 63 - Type: DATA 64 Segments: 65 - SectionOffset: 0 66 InitFlags: 0 67 Offset: 68 Opcode: I32_CONST 69 Value: 0 70 Content: '' 71