Skip to content

Commit

Permalink
[ELF] readobj -elf-output-style=GNU -> readelf
Browse files Browse the repository at this point in the history
Style change for consistency. NFC

llvm-svn: 335494
  • Loading branch information
MaskRay committed Jun 25, 2018
1 parent 85e200e commit 65c5007
Show file tree
Hide file tree
Showing 12 changed files with 15 additions and 16 deletions.
2 changes: 1 addition & 1 deletion lld/test/ELF/dynsec-at-beginning.s
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t

# RUN: ld.lld --hash-style=gnu -o %t1 %t -shared
# RUN: llvm-readobj -elf-output-style=GNU -s %t1 | FileCheck %s
# RUN: llvm-readelf -s %t1 | FileCheck %s

# Dynamic symbol and dynamic strtab sections are at the beginning of
# SHF_ALLOC sections.
Expand Down
5 changes: 2 additions & 3 deletions lld/test/ELF/linkerscript/implicit-program-header.test
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@
# RUN: echo '.section .text,"ax"; .quad 0' > %t.s
# RUN: echo '.section .foo,"ax"; .quad 0' >> %t.s
# RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %t.s -o %t.o
# RUN: ld.lld --hash-style=sysv -o %t1 --script %s \
# RUN: %t.o -shared
# RUN: llvm-readobj -elf-output-style=GNU -l %t1 | FileCheck %s
# RUN: ld.lld --hash-style=sysv -o %t1 --script %s %t.o -shared
# RUN: llvm-readelf -l %t1 | FileCheck %s

# CHECK: Segment Sections...
# CHECK-NEXT: 00 .text .hash .dynamic
Expand Down
4 changes: 2 additions & 2 deletions lld/test/ELF/linkerscript/no-space.s
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@

# RUN: echo "SECTIONS {foo 0 : {*(foo*)} .dynsym : {*(.dynsym)} .dynstr : {*(.dynstr)} }" > %t.script
# RUN: ld.lld --hash-style=sysv -o %t --script %t.script %t.o -shared
# RUN: llvm-readobj -elf-output-style=GNU -l %t | FileCheck %s
# RUN: llvm-readelf -l %t | FileCheck %s

# RUN: echo "SECTIONS {foo : {*(foo*)} .dynsym : { *(.dynsym) } .dynstr : { *(.dynstr) } }" > %t.script
# RUN: ld.lld --hash-style=sysv -o %t --script %t.script %t.o -shared
# RUN: llvm-readobj -elf-output-style=GNU -l %t | FileCheck %s
# RUN: llvm-readelf -l %t | FileCheck %s

# There is not enough address space available for the header, so just start the PT_LOAD
# after it. Don't create a PT_PHDR as the header is not allocated.
Expand Down
2 changes: 1 addition & 1 deletion lld/test/ELF/linkerscript/non-alloc-segment.s
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# RUN: .foo : {*(.foo)} :foo \
# RUN: }" > %t.script
# RUN: ld.lld -o %t --script %t.script %t.o
# RUN: llvm-readobj -elf-output-style=GNU -s -l %t | FileCheck %s
# RUN: llvm-readelf -s -l %t | FileCheck %s
# RUN: llvm-readobj -l %t | FileCheck --check-prefix=PHDR %s

# CHECK: Program Headers:
Expand Down
2 changes: 1 addition & 1 deletion lld/test/ELF/linkerscript/non-alloc.s
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

# RUN: echo "SECTIONS { .foo 0 : {*(foo)} }" > %t.script
# RUN: ld.lld --hash-style=sysv -o %t1 --script %t.script %t -shared
# RUN: llvm-readobj -elf-output-style=GNU -s -l %t1 | FileCheck %s
# RUN: llvm-readelf -s -l %t1 | FileCheck %s

# Test that we create all necessary PT_LOAD. We use to stop at the first
# non-alloc, causing us to not create PT_LOAD for linker generated sections.
Expand Down
2 changes: 1 addition & 1 deletion lld/test/ELF/linkerscript/orphan-phdrs.s
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
# RUN: .rw : { *(.rw) } \
# RUN: }" > %t.script
# RUN: ld.lld -o %t --script %t.script %t.o
# RUN: llvm-readobj -elf-output-style=GNU -s -l %t | FileCheck %s
# RUN: llvm-readelf -s -l %t | FileCheck %s

## Check that the orphan section is placed correctly and belongs to
## the correct segment.
Expand Down
4 changes: 2 additions & 2 deletions lld/test/ELF/linkerscript/segment-none.s
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# RUN: .foo : {*(.foo)} :NONE \
# RUN: }" > %t.script
# RUN: ld.lld -o %t --script %t.script %t.o
# RUN: llvm-readobj -elf-output-style=GNU -s -l %t | FileCheck %s
# RUN: llvm-readelf -s -l %t | FileCheck %s

## Test that section .foo is placed in segment NONE when assigned to segment
## NONE in the linker script and segment NONE is defined.
Expand All @@ -19,7 +19,7 @@
# RUN: .foo : {*(.foo)} :NONE \
# RUN: }" > %t.script
# RUN: ld.lld -o %t --script %t.script %t.o
# RUN: llvm-readobj -elf-output-style=GNU -s -l %t | FileCheck --check-prefix=DEFINED %s
# RUN: llvm-readelf -s -l %t | FileCheck --check-prefix=DEFINED %s

# CHECK: Section to Segment mapping:
# CHECK-NEXT: Segment Sections...
Expand Down
2 changes: 1 addition & 1 deletion lld/test/ELF/linkerscript/sort-non-script.s
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

# RUN: echo "SECTIONS { foo : {*(foo)} }" > %t.script
# RUN: ld.lld --hash-style=sysv -o %t1 --script %t.script %t -shared
# RUN: llvm-readobj -elf-output-style=GNU -s %t1 | FileCheck %s
# RUN: llvm-readelf -s %t1 | FileCheck %s

# CHECK: .dynsym {{.*}} A
# CHECK-NEXT: .dynstr {{.*}} A
Expand Down
2 changes: 1 addition & 1 deletion lld/test/ELF/lto/data-ordering-lto.s
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# RUN: echo "pat " >> %t_order_lto.txt

# RUN: ld.lld --symbol-ordering-file %t_order_lto.txt %t.o %t.bc -o %t2.out
# RUN: llvm-readobj -elf-output-style=GNU -t %t2.out| FileCheck %s
# RUN: llvm-readelf -t %t2.out| FileCheck %s

# Check that the order is tin -> dipsy -> pat.

Expand Down
2 changes: 1 addition & 1 deletion lld/test/ELF/lto/symbol-ordering-lto.s
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# RUN: echo "pat " >> %t_order_lto.txt

# RUN: ld.lld --symbol-ordering-file %t_order_lto.txt %t.o %t.bc -o %t2.out
# RUN: llvm-readobj -elf-output-style=GNU -t %t2.out| FileCheck %s
# RUN: llvm-readelf -t %t2.out| FileCheck %s

# Check that the order is tin -> _start -> pat.

Expand Down
2 changes: 1 addition & 1 deletion lld/test/ELF/pr34660.s
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# RUN: llvm-mc -filetype=obj -triple=aarch64-linux-none %s -o %t.o
# RUN: ld.lld --hash-style=sysv -shared %t.o -o %t
# RUN: llvm-objdump %t -d | FileCheck %s --check-prefix=DISASM
# RUN: llvm-readobj -elf-output-style=GNU %t -t | FileCheck %s --check-prefix=SYM
# RUN: llvm-readelf %t -t | FileCheck %s --check-prefix=SYM

# It would be much easier to understand/read this test if llvm-objdump would print
# the immediates in hex.
Expand Down
2 changes: 1 addition & 1 deletion lld/test/ELF/sort-norosegment.s
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t

# RUN: ld.lld --hash-style=sysv -no-rosegment -o %t1 %t -shared
# RUN: llvm-readobj -elf-output-style=GNU -s %t1 | FileCheck %s
# RUN: llvm-readelf -s %t1 | FileCheck %s

# CHECK: .dynsym {{.*}} A
# CHECK-NEXT: .dynstr {{.*}} A
Expand Down

0 comments on commit 65c5007

Please sign in to comment.