[llvm] Do not replace dead constant references in metadata with undef
[llvm-project.git] / lld / test / ELF / linkerscript / no-space.s
blob7232495a3fd4124787ea27794a523ba8efe331c9
1 # REQUIRES: x86
2 # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o
4 # RUN: echo "SECTIONS {foo 0 : {*(foo*)} .dynsym : {*(.dynsym)} .dynstr : {*(.dynstr)} }" > %t.script
5 # RUN: ld.lld --hash-style=sysv -o %t --script %t.script %t.o -shared
6 # RUN: llvm-readelf -l %t | FileCheck %s
8 # RUN: echo "SECTIONS {foo : {*(foo*)} .dynsym : { *(.dynsym) } .dynstr : { *(.dynstr) } }" > %t.script
9 # RUN: ld.lld --hash-style=sysv -o %t --script %t.script %t.o -shared
10 # RUN: llvm-readelf -l %t | FileCheck %s
12 # There is not enough address space available for the header, so just start the PT_LOAD
13 # after it. Don't create a PT_PHDR as the header is not allocated.
15 # CHECK: Program Headers:
16 # CHECK-NEXT: Type Offset VirtAddr PhysAddr
17 # CHECK-NEXT: LOAD 0x001000 0x0000000000000000 0x0000000000000000
19 # CHECK: Section to Segment mapping:
20 # CHECK-NEXT: Segment Sections...
21 # CHECK-NEXT: 00 foo .dynsym .dynstr .hash
23 .section foo, "a"
24 .quad 0