aboutsummaryrefslogtreecommitdiff
path: root/lld/test/ELF/linkerscript/discard-section.s
blob: a5af9080682971eb5a76bc239326d754859179ff (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