1# RUN: split-file %s %t 2# RUN: llvm-mc -filetype=obj -triple=wasm32-unknown-unknown %t/a.s -o %t1.o 3# RUN: llvm-mc -filetype=obj -triple=wasm32-unknown-unknown %t/b.s -o %t2.o 4# RUN: wasm-ld -o %t.wasm %t1.o %t2.o 5# RUN: obj2yaml %t.wasm | FileCheck %s 6 7# Ensure two custom funct_attr sections are concatenated together. 8 9# CHECK: - Type: CUSTOM 10# CHECK-NEXT: Name: llvm.func_attr.custom0 11# CHECK-NEXT: Payload: '000000000100000003000000' 12 13#--- a.s 14 15# Function index 3 (after linking) 16 .functype baz () -> () 17# Function index 1 18 .functype foo () -> () 19# Function index 2 20 .functype bar () -> () 21 .functype _start () -> () 22 .globl foo 23 .type foo,@function 24foo: 25 .functype foo () -> () 26 end_function 27 28 .globl bar 29 .type bar,@function 30bar: 31 .functype bar () -> () 32 end_function 33 34 .globl _start 35 .type _start,@function 36_start: 37 .functype _start () -> () 38 call foo 39 call bar 40 call baz 41 end_function 42 43 .section .custom_section.llvm.func_attr.custom0,"",@ 44 .int32 foo@FUNCINDEX 45 .int32 bar@FUNCINDEX 46 47#--- b.s 48 .functype baz () -> () 49 .globl baz 50 .type baz,@function 51baz: 52 .functype baz () -> () 53 end_function 54 55 .section .custom_section.llvm.func_attr.custom0,"",@ 56 .int32 baz@FUNCINDEX 57