1# REQUIRES: x86
2
3## .data.foo and .data.bar are combined into .data,
4## so their relocation sections should also be combined.
5
6# RUN: llvm-mc -filetype=obj -triple=x86_64 %s -o %t.o
7# RUN: ld.lld --emit-relocs %t.o -o %t.so -shared
8# RUN: llvm-readobj -r %t.so | FileCheck %s
9
10# CHECK:       Relocations [
11# CHECK-NEXT:    Section ({{.*}}) .rela.dyn {
12# CHECK-NEXT:     [[ADDR1:[0-9a-f]+]] R_X86_64_64 zed 0x0
13# CHECK-NEXT:     [[ADDR2:[0-9a-f]+]] R_X86_64_64 zed 0x0
14# CHECK-NEXT:   }
15# CHECK-NEXT:   Section ({{.*}}) .rela.data {
16# CHECK-NEXT:     [[ADDR1]] R_X86_64_64 zed 0x0
17# CHECK-NEXT:     [[ADDR2]] R_X86_64_64 zed 0x0
18# CHECK-NEXT:   }
19# CHECK-NEXT: ]
20
21.section        .data.foo,"aw",%progbits
22.quad zed
23.section        .data.bar,"aw",%progbits
24.quad zed
25