[llvm] Do not replace dead constant references in metadata with undef
[llvm-project.git] / lld / test / ELF / linkerscript / merge-sections-syms.s
blobed9e7d3d523fecf03e6f169e54b7615bc3667b3b
1 # REQUIRES: x86
2 # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o
4 # RUN: echo "SECTIONS { \
5 # RUN: . = SIZEOF_HEADERS; \
6 # RUN: .rodata : { *(.aaa) *(.bbb) A = .; *(.ccc) B = .; } \
7 # RUN: }" > %t.script
8 # RUN: ld.lld -o %t.so --script %t.script %t.o -shared
9 # RUN: llvm-nm -D %t.so | FileCheck %s
11 # CHECK: 000000000000025e R A
12 # CHECK: 000000000000025f R B
14 .section .aaa,"a"
15 .byte 11
17 .section .bbb,"aMS",@progbits,1
18 .asciz "foo"
20 .section .ccc,"a"
21 .byte 33