1// REQUIRES: x86
2
3/// Synthesize __start_* and __stop_* even if there exists a definition in a DSO.
4
5// RUN: echo '.globl __start_foo; __start_foo:' | llvm-mc -filetype=obj -triple=x86_64 - -o %t.o
6// RUN: ld.lld -o %t.so -soname=so %t.o -shared
7// RUN: llvm-mc -filetype=obj -triple=x86_64 %s -o %t2.o
8// RUN: ld.lld -o %t %t2.o %t.so
9// RUN: llvm-objdump -s -h %t | FileCheck %s
10
11// CHECK: foo           00000000 0000000000201248
12
13// CHECK: Contents of section .text:
14// CHECK-NEXT: 201240 48122000 00000000
15
16.quad __start_foo
17.section foo,"ax"
18