A CommonInputSection is a section containing all common symbols. That was an input section but was abstracted in a different way than the synthetic input sections because it was written before the synthetic input section was invented. This patch rewrites CommonInputSection as a synthetic input section so that it behaves better with other sections. llvm-svn: 286053
22 lines
598 B
ArmAsm
22 lines
598 B
ArmAsm
# REQUIRES: x86
|
|
# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t
|
|
# RUN: echo "SECTIONS { . = SIZEOF_HEADERS; " > %t.script
|
|
# RUN: echo ".text : { *(.text*) }" >> %t.script
|
|
# RUN: echo ".bss1 : { *(.bss) }" >> %t.script
|
|
# RUN: echo ".bss2 : { *(COMMON) }" >> %t.script
|
|
# RUN: echo "}" >> %t.script
|
|
|
|
# RUN: ld.lld -o %t1 --script %t.script %t
|
|
# RUN: llvm-objdump -section-headers %t1 | FileCheck %s
|
|
# CHECK: .bss1 00000004 0000000000000122 BSS
|
|
# CHECK-NEXT: .bss2 00000080 0000000000000128 BSS
|
|
|
|
.globl _start
|
|
_start:
|
|
jmp _start
|
|
|
|
.bss
|
|
.zero 4
|
|
|
|
.comm q,128,8
|