aboutsummaryrefslogtreecommitdiff
path: root/lld/test/ELF/linkerscript/discard-section.s
blob: fbdff5dfbe849932238585cb76876644981d809a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
# REQUIRES: x86
# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t
# RUN: echo "SECTIONS { /DISCARD/ : { *(.aaa*) } }" > %t.script
# RUN: ld.lld -o %t1 --script %t.script %t
# RUN: llvm-objdump --section-headers %t1 | FileCheck %s

# CHECK-NOT: .aaa

.section .aaa,"a"
aab:
  .quad 0

.section .zzz,"a"
  .quad aab