1# Test the --export of optional linker-synthetic symbols works. 2# Specifically the __start_xxx and __end_xx symbols. 3 4# RUN: llvm-mc -filetype=obj -triple=wasm32-unknown-unknown %s -o %t.o 5# RUN: wasm-ld --export=__start_foo %t.o -o %t.wasm 6# RUN: obj2yaml %t.wasm | FileCheck %s 7 8 .globl _start 9_start: 10 .functype _start () -> () 11 i32.const 0 12 i32.load foo 13 drop 14 end_function 15 16 .globl foo 17 .section foo,"",@ 18foo: 19 .int32 42 20 .size foo, 4 21 22# CHECK: - Type: EXPORT 23# CHECK-NEXT: Exports: 24# CHECK-NEXT: - Name: memory 25# CHECK-NEXT: Kind: MEMORY 26# CHECK-NEXT: Index: 0 27# CHECK-NEXT: - Name: _start 28# CHECK-NEXT: Kind: FUNCTION 29# CHECK-NEXT: Index: 0 30# CHECK-NEXT: - Name: __start_foo 31# CHECK-NEXT: Kind: GLOBAL 32# CHECK-NEXT: Index: 1 33