Index: test/ELF/aarch64-data-relocs.s =================================================================== --- test/ELF/aarch64-data-relocs.s +++ test/ELF/aarch64-data-relocs.s @@ -1,7 +1,7 @@ // RUN: llvm-mc -filetype=obj -triple=aarch64-none-freebsd %s -o %t // RUN: llvm-mc -filetype=obj -triple=aarch64-none-freebsd %S/Inputs/abs256.s -o %t256.o // RUN: ld.lld %t %t256.o -o %t2 -// RUN: llvm-objdump -s %t2 | FileCheck %s +// RUN: llvm-objdump -s -section=.R_AARCH64_ABS64 -section=.R_AARCH64_PREL64 %t2 | FileCheck %s // REQUIRES: aarch64 .globl _start Index: test/ELF/aarch64-gnu-ifunc-plt.s =================================================================== --- test/ELF/aarch64-gnu-ifunc-plt.s +++ test/ELF/aarch64-gnu-ifunc-plt.s @@ -3,7 +3,7 @@ // RUN: llvm-mc -filetype=obj -triple=aarch64-none-linux-gnu %s -o %t.o // RUN: ld.lld %t.so %t.o -o %tout // RUN: llvm-objdump -d %tout | FileCheck %s --check-prefix=DISASM -// RUN: llvm-objdump -s %tout | FileCheck %s --check-prefix=GOTPLT +// RUN: llvm-objdump -s -section=.got.plt %tout | FileCheck %s --check-prefix=GOTPLT // RUN: llvm-readobj -r -dynamic-table %tout | FileCheck %s // REQUIRES: aarch64 Index: test/ELF/amdgpu-relocs.s =================================================================== --- test/ELF/amdgpu-relocs.s +++ test/ELF/amdgpu-relocs.s @@ -1,7 +1,7 @@ # RUN: llvm-mc -filetype=obj -triple=amdgcn--amdhsa -mcpu=fiji %s -o %t.o # RUN: ld.lld -shared %t.o -o %t.so # RUN: llvm-readobj -r %t.so | FileCheck %s -# RUN: llvm-objdump -s %t.so | FileCheck %s --check-prefix=OBJDUMP +# RUN: llvm-objdump -s --section=nonalloc %t.so | FileCheck %s --check-prefix=OBJDUMP # REQUIRES: amdgpu Index: test/ELF/arm-gnu-ifunc-plt.s =================================================================== --- test/ELF/arm-gnu-ifunc-plt.s +++ test/ELF/arm-gnu-ifunc-plt.s @@ -3,7 +3,7 @@ // RUN: llvm-mc -filetype=obj -triple=armv7a-linux-gnueabihf %s -o %t.o // RUN: ld.lld %t.so %t.o -o %tout // RUN: llvm-objdump -triple=armv7a-linux-gnueabihf -d %tout | FileCheck %s --check-prefix=DISASM -// RUN: llvm-objdump -s %tout | FileCheck %s --check-prefix=GOTPLT +// RUN: llvm-objdump -s -section=.got -section=.got.plt %tout | FileCheck %s --check-prefix=GOTPLT // RUN: llvm-readobj -r -dynamic-table %tout | FileCheck %s // REQUIRES: arm Index: test/ELF/arm-pie-relative.s =================================================================== --- test/ELF/arm-pie-relative.s +++ test/ELF/arm-pie-relative.s @@ -1,7 +1,7 @@ // RUN: llvm-mc -filetype=obj -triple=armv7a-none-linux-gnueabi %s -o %t // RUN: ld.lld %t --pie -o %t2 // RUN: llvm-readobj -r %t2 | FileCheck %s -// RUN: llvm-objdump -s %t2 | FileCheck %s --check-prefix=GOT +// RUN: llvm-objdump -s -section=.got %t2 | FileCheck %s --check-prefix=GOT // REQUIRES: arm // Test that a R_ARM_GOT_BREL relocation with PIE results in a R_ARM_RELATIVE Index: test/ELF/arm-tls-norelax-gd-le.s =================================================================== --- test/ELF/arm-tls-norelax-gd-le.s +++ test/ELF/arm-tls-norelax-gd-le.s @@ -2,7 +2,7 @@ // RUN: ld.lld %t1 --shared -o %t1.so // RUN: llvm-mc %s -o %t.o -filetype=obj -triple=armv7a-linux-gnueabi // RUN: ld.lld %t1.so %t.o -o %t -// RUN: llvm-objdump -s %t | FileCheck %s +// RUN: llvm-objdump -s -section=.got %t | FileCheck %s // REQUIRES: arm // This tls global-dynamic sequence is with respect to a non-preemptible Index: test/ELF/arm-tls-norelax-ld-le.s =================================================================== --- test/ELF/arm-tls-norelax-ld-le.s +++ test/ELF/arm-tls-norelax-ld-le.s @@ -2,7 +2,7 @@ // RUN: ld.lld %t1 --shared -o %t1.so // RUN: llvm-mc %s -o %t.o -filetype=obj -triple=armv7a-linux-gnueabi // RUN: ld.lld %t1.so %t.o -o %t -// RUN: llvm-objdump -s %t | FileCheck %s +// RUN: llvm-objdump -s -section=.got %t | FileCheck %s // REQUIRES: arm .global __tls_get_addr Index: test/ELF/comment-gc.s =================================================================== --- test/ELF/comment-gc.s +++ test/ELF/comment-gc.s @@ -2,7 +2,7 @@ # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %p/Inputs/comment-gc.s -o %t2.o # RUN: ld.lld %t.o %t2.o -o %t1 --gc-sections -shared -# RUN: llvm-objdump -s %t1 | FileCheck %s +# RUN: llvm-objdump -s -section=.comment %t1 | FileCheck %s # CHECK: Contents of section .comment: # CHECK-NEXT: 0000 00666f6f 00626172 004c4c44 20312e30 .foo.bar.LLD 1.0 Index: test/ELF/ctors_dtors_priority.s =================================================================== --- test/ELF/ctors_dtors_priority.s +++ test/ELF/ctors_dtors_priority.s @@ -6,7 +6,7 @@ // RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux \ // RUN: %p/Inputs/ctors_dtors_priority3.s -o %t-crtend.o // RUN: ld.lld %t1 %t2 %t-crtend.o %t-crtbegin.o -o %t.exe -// RUN: llvm-objdump -s %t.exe | FileCheck %s +// RUN: llvm-objdump -s -section=.ctors -section=.dtors %t.exe | FileCheck %s // REQUIRES: x86 .globl _start Index: test/ELF/debug-gc.s =================================================================== --- test/ELF/debug-gc.s +++ test/ELF/debug-gc.s @@ -1,7 +1,7 @@ # REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o # RUN: ld.lld %t.o -o %t1 --gc-sections -# RUN: llvm-objdump -s %t1 | FileCheck %s +# RUN: llvm-objdump -s -section=.debug_str -section=.foo -section=.debug_info %t1 | FileCheck %s # CHECK: Contents of section .debug_str: # CHECK-NEXT: 0000 41414100 42424200 43434300 AAA.BBB.CCC. Index: test/ELF/eh-frame-hdr-icf.s =================================================================== --- test/ELF/eh-frame-hdr-icf.s +++ test/ELF/eh-frame-hdr-icf.s @@ -2,7 +2,7 @@ # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t # RUN: ld.lld %t -o %t2 --icf=all --eh-frame-hdr -# RUN: llvm-objdump -s %t2 | FileCheck %s +# RUN: llvm-objdump -s -section=.eh_frame_hdr %t2 | FileCheck %s # CHECK: Contents of section .eh_frame_hdr: # CHECK-NEXT: 200158 011b033b 1c000000 01000000 a80e0000 Index: test/ELF/init_fini_priority.s =================================================================== --- test/ELF/init_fini_priority.s +++ test/ELF/init_fini_priority.s @@ -1,6 +1,6 @@ // RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t // RUN: ld.lld %t -o %t.exe -// RUN: llvm-objdump -s %t.exe | FileCheck %s +// RUN: llvm-objdump -s -section=.init_array -section=.fini_array %t.exe | FileCheck %s // REQUIRES: x86 .globl _start Index: test/ELF/linkerscript/data-commands.s =================================================================== --- test/ELF/linkerscript/data-commands.s +++ test/ELF/linkerscript/data-commands.s @@ -24,7 +24,7 @@ # RUN: } \ # RUN: }" > %t.script # RUN: ld.lld -o %t %t.o --script %t.script -# RUN: llvm-objdump -s %t | FileCheck %s +# RUN: llvm-objdump -s -section=.foo -section=.bar %t | FileCheck %s # CHECK: Contents of section .foo: # CHECK-NEXT: ff11ff22 11ff4433 2211ff88 77665544 @@ -36,7 +36,7 @@ # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux %s -o %tmips64be # RUN: ld.lld --script %t.script %tmips64be -o %t2 -# RUN: llvm-objdump -s %t2 | FileCheck %s --check-prefix=BE +# RUN: llvm-objdump -s -section=.foo -section=.bar %t2 | FileCheck %s --check-prefix=BE # BE: Contents of section .foo: # BE-NEXT: ff11ff11 22ff1122 3344ff11 22334455 # BE-NEXT: 667788 Index: test/ELF/linkerscript/exclude-multiple.s =================================================================== --- test/ELF/linkerscript/exclude-multiple.s +++ test/ELF/linkerscript/exclude-multiple.s @@ -6,7 +6,7 @@ # RUN: .foo : { *(.foo.1 EXCLUDE_FILE (*file1.o) .foo.2 EXCLUDE_FILE (*file2.o) .foo.3) } \ # RUN: }" > %t1.script # RUN: ld.lld -script %t1.script %tfile1.o %tfile2.o %tfile3.o -o %t1.o -# RUN: llvm-objdump -s %t1.o | FileCheck %s +# RUN: llvm-objdump -s -section=.foo -section=.foo.2 -section=.foo.3 %t1.o | FileCheck %s # CHECK: Contents of section .foo: # CHECK-NEXT: 01000000 00000000 04000000 00000000 Index: test/ELF/linkerscript/fill.s =================================================================== --- test/ELF/linkerscript/fill.s +++ test/ELF/linkerscript/fill.s @@ -12,7 +12,7 @@ # RUN: } \ # RUN: }; " > %t.script # RUN: ld.lld -o %t --script %t.script %t.o -# RUN: llvm-objdump -s %t | FileCheck %s +# RUN: llvm-objdump -s -section=.out %t | FileCheck %s # CHECK: Contents of section .out: # CHECK-NEXT: aa222222 22bb2222 22222222 2222 Index: test/ELF/linkerscript/merge-sections-reloc.s =================================================================== --- test/ELF/linkerscript/merge-sections-reloc.s +++ test/ELF/linkerscript/merge-sections-reloc.s @@ -3,7 +3,7 @@ # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t2.o # RUN: echo "SECTIONS {}" > %t.script # RUN: ld.lld -o %t --script %t.script %t1.o %t2.o -# RUN: llvm-objdump -s %t | FileCheck %s +# RUN: llvm-objdump -s -section=.text %t | FileCheck %s ## Check that sections content is not corrupted. # CHECK: Contents of section .text: Index: test/ELF/linkerscript/sort-init.s =================================================================== --- test/ELF/linkerscript/sort-init.s +++ test/ELF/linkerscript/sort-init.s @@ -2,7 +2,7 @@ # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t1.o # RUN: echo "SECTIONS { .init_array : { *(SORT_BY_INIT_PRIORITY(.init_array.*)) } }" > %t1.script # RUN: ld.lld --script %t1.script %t1.o -o %t2 -# RUN: llvm-objdump -s %t2 | FileCheck %s +# RUN: llvm-objdump -s -section=.init_array %t2 | FileCheck %s # CHECK: Contents of section .init_array: # CHECK-NEXT: 03020000 00000000 010405 Index: test/ELF/linkerscript/sort-nested.s =================================================================== --- test/ELF/linkerscript/sort-nested.s +++ test/ELF/linkerscript/sort-nested.s @@ -6,7 +6,7 @@ ## Check sorting first by alignment and then by name. # RUN: echo "SECTIONS { .aaa : { *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.aaa.*))) } }" > %t1.script # RUN: ld.lld -o %t1 --script %t1.script %t1.o %t2.o -# RUN: llvm-objdump -s %t1 | FileCheck -check-prefix=SORTED_AN %s +# RUN: llvm-objdump -section=.aaa -s %t1 | FileCheck -check-prefix=SORTED_AN %s # SORTED_AN: Contents of section .aaa: # SORTED_AN-NEXT: 01000000 00000000 00000000 00000000 # SORTED_AN-NEXT: 11000000 00000000 00000000 00000000 @@ -16,7 +16,7 @@ ## Check sorting first by name and then by alignment. # RUN: echo "SECTIONS { .aaa : { *(SORT_BY_NAME(SORT_BY_ALIGNMENT(.aaa.*))) } }" > %t2.script # RUN: ld.lld -o %t2 --script %t2.script %t1.o %t2.o -# RUN: llvm-objdump -s %t2 | FileCheck -check-prefix=SORTED_NA %s +# RUN: llvm-objdump -section=.aaa -s %t2 | FileCheck -check-prefix=SORTED_NA %s # SORTED_NA: Contents of section .aaa: # SORTED_NA: 01000000 00000000 00000000 00000000 # SORTED_NA: 11000000 00000000 22000000 00000000 @@ -28,10 +28,10 @@ ## as nested sorting command. # RUN: echo "SECTIONS { .aaa : { *(SORT_BY_ALIGNMENT(.aaa.*)) } }" > %t3.script # RUN: ld.lld --sort-section name -o %t3 --script %t3.script %t1.o %t2.o -# RUN: llvm-objdump -s %t3 | FileCheck -check-prefix=SORTED_AN %s +# RUN: llvm-objdump -s -section=.aaa %t3 | FileCheck -check-prefix=SORTED_AN %s # RUN: echo "SECTIONS { .aaa : { *(SORT_BY_NAME(.aaa.*)) } }" > %t4.script # RUN: ld.lld --sort-section alignment -o %t4 --script %t4.script %t1.o %t2.o -# RUN: llvm-objdump -s %t4 | FileCheck -check-prefix=SORTED_NA %s +# RUN: llvm-objdump -s -section=.aaa %t4 | FileCheck -check-prefix=SORTED_NA %s .global _start _start: Index: test/ELF/linkerscript/sort.s =================================================================== --- test/ELF/linkerscript/sort.s +++ test/ELF/linkerscript/sort.s @@ -5,7 +5,7 @@ # RUN: echo "SECTIONS { .aaa : { *(.aaa.*) } }" > %t1.script # RUN: ld.lld -o %t1 --script %t1.script %t2.o %t1.o -# RUN: llvm-objdump -s %t1 | FileCheck -check-prefix=UNSORTED %s +# RUN: llvm-objdump -s -section=.aaa %t1 | FileCheck -check-prefix=UNSORTED %s # UNSORTED: Contents of section .aaa: # UNSORTED-NEXT: 55000000 00000000 00000000 00000000 # UNSORTED-NEXT: 00000000 00000000 00000000 00000000 @@ -18,7 +18,7 @@ ## Check that SORT works (sorted by name of section). # RUN: echo "SECTIONS { .aaa : { *(SORT(.aaa.*)) } }" > %t2.script # RUN: ld.lld -o %t2 --script %t2.script %t2.o %t1.o -# RUN: llvm-objdump -s %t2 | FileCheck -check-prefix=SORTED_A %s +# RUN: llvm-objdump -s -section=.aaa %t2 | FileCheck -check-prefix=SORTED_A %s # SORTED_A: Contents of section .aaa: # SORTED_A-NEXT: 11000000 00000000 01000000 00000000 # SORTED_A-NEXT: 22000000 00000000 02000000 00000000 @@ -32,7 +32,7 @@ ## section names is stable. # RUN: echo "SECTIONS { .aaa : { *(SORT(.aaa.*)) } }" > %t3.script # RUN: ld.lld -o %t3 --script %t3.script %t1.o %t2.o -# RUN: llvm-objdump -s %t3 | FileCheck -check-prefix=SORTED_B %s +# RUN: llvm-objdump -s -section=.aaa %t3 | FileCheck -check-prefix=SORTED_B %s # SORTED_B: Contents of section .aaa: # SORTED_B-NEXT: 01000000 00000000 00000000 00000000 # SORTED_B-NEXT: 00000000 00000000 00000000 00000000 @@ -45,17 +45,17 @@ ## Check that SORT surrounded with KEEP also works. # RUN: echo "SECTIONS { .aaa : { KEEP (*(SORT(.aaa.*))) } }" > %t3.script # RUN: ld.lld -o %t3 --script %t3.script %t2.o %t1.o -# RUN: llvm-objdump -s %t3 | FileCheck -check-prefix=SORTED_A %s +# RUN: llvm-objdump -s -section=.aaa %t3 | FileCheck -check-prefix=SORTED_A %s ## Check that SORT_BY_NAME works (SORT is alias). # RUN: echo "SECTIONS { .aaa : { *(SORT_BY_NAME(.aaa.*)) } }" > %t4.script # RUN: ld.lld -o %t4 --script %t4.script %t2.o %t1.o -# RUN: llvm-objdump -s %t4 | FileCheck -check-prefix=SORTED_A %s +# RUN: llvm-objdump -s -section=.aaa %t4 | FileCheck -check-prefix=SORTED_A %s ## Check that sections ordered by alignment. # RUN: echo "SECTIONS { .aaa : { *(SORT_BY_ALIGNMENT(.aaa.*)) } }" > %t5.script # RUN: ld.lld -o %t5 --script %t5.script %t1.o %t2.o -# RUN: llvm-objdump -s %t5 | FileCheck -check-prefix=SORTED_ALIGNMENT %s +# RUN: llvm-objdump -s -section=.aaa %t5 | FileCheck -check-prefix=SORTED_ALIGNMENT %s # SORTED_ALIGNMENT: Contents of section .aaa: # SORTED_ALIGNMENT-NEXT: 05000000 00000000 00000000 00000000 # SORTED_ALIGNMENT-NEXT: 00000000 00000000 00000000 00000000 @@ -69,31 +69,31 @@ ## SORT_NONE itself does not sort anything. # RUN: echo "SECTIONS { .aaa : { *(SORT_NONE(.aaa.*)) } }" > %t6.script # RUN: ld.lld -o %t7 --script %t6.script %t2.o %t1.o -# RUN: llvm-objdump -s %t7 | FileCheck -check-prefix=UNSORTED %s +# RUN: llvm-objdump -s -section=.aaa %t7 | FileCheck -check-prefix=UNSORTED %s ## Check --sort-section alignment option. # RUN: echo "SECTIONS { .aaa : { *(.aaa.*) } }" > %t7.script # RUN: ld.lld --sort-section alignment -o %t8 --script %t7.script %t1.o %t2.o -# RUN: llvm-objdump -s %t8 | FileCheck -check-prefix=SORTED_ALIGNMENT %s +# RUN: llvm-objdump -s -section=.aaa %t8 | FileCheck -check-prefix=SORTED_ALIGNMENT %s ## Check --sort-section= form. # RUN: ld.lld --sort-section=alignment -o %t8_1 --script %t7.script %t1.o %t2.o -# RUN: llvm-objdump -s %t8_1 | FileCheck -check-prefix=SORTED_ALIGNMENT %s +# RUN: llvm-objdump -s -section=.aaa %t8_1 | FileCheck -check-prefix=SORTED_ALIGNMENT %s ## Check --sort-section name option. # RUN: echo "SECTIONS { .aaa : { *(.aaa.*) } }" > %t8.script # RUN: ld.lld --sort-section name -o %t9 --script %t8.script %t1.o %t2.o -# RUN: llvm-objdump -s %t9 | FileCheck -check-prefix=SORTED_B %s +# RUN: llvm-objdump -s -section=.aaa %t9 | FileCheck -check-prefix=SORTED_B %s ## SORT_NONE disables the --sort-section. # RUN: echo "SECTIONS { .aaa : { *(SORT_NONE(.aaa.*)) } }" > %t9.script # RUN: ld.lld --sort-section name -o %t10 --script %t9.script %t2.o %t1.o -# RUN: llvm-objdump -s %t10 | FileCheck -check-prefix=UNSORTED %s +# RUN: llvm-objdump -s -section=.aaa %t10 | FileCheck -check-prefix=UNSORTED %s ## SORT_NONE as a inner sort directive. # RUN: echo "SECTIONS { .aaa : { *(SORT_BY_NAME(SORT_NONE(.aaa.*))) } }" > %t10.script # RUN: ld.lld -o %t11 --script %t10.script %t2.o %t1.o -# RUN: llvm-objdump -s %t11 | FileCheck -check-prefix=SORTED_A %s +# RUN: llvm-objdump -s -section=.aaa %t11 | FileCheck -check-prefix=SORTED_A %s .global _start _start: Index: test/ELF/linkerscript/sort2.s =================================================================== --- test/ELF/linkerscript/sort2.s +++ test/ELF/linkerscript/sort2.s @@ -3,7 +3,7 @@ # RUN: echo "SECTIONS { .abc : { *(SORT(.foo.*) .bar.*) } }" > %t1.script # RUN: ld.lld -o %t1 --script %t1.script %tfile1.o -# RUN: llvm-objdump -s %t1 | FileCheck %s +# RUN: llvm-objdump -s -section=.abc %t1 | FileCheck %s # CHECK: Contents of section .abc: # CHECK: 01000000 00000000 02000000 00000000 @@ -14,7 +14,7 @@ # RUN: .abc : { *(SORT(.foo.* EXCLUDE_FILE (*file1.o) .bar.*) .bar.*) } \ # RUN: }" > %t2.script # RUN: ld.lld -o %t2 --script %t2.script %tfile1.o -# RUN: llvm-objdump -s %t2 | FileCheck %s +# RUN: llvm-objdump -s -section=.abc %t2 | FileCheck %s .text .globl _start Index: test/ELF/linkerscript/subalign.s =================================================================== --- test/ELF/linkerscript/subalign.s +++ test/ELF/linkerscript/subalign.s @@ -3,7 +3,7 @@ # RUN: echo "SECTIONS { .aaa : { *(.aaa.*) } }" > %t1.script # RUN: ld.lld -o %t1 --script %t1.script %t1.o -# RUN: llvm-objdump -s %t1 | FileCheck -check-prefix=NOALIGN %s +# RUN: llvm-objdump -s -section=.aaa %t1 | FileCheck -check-prefix=NOALIGN %s # NOALIGN: Contents of section .aaa: # NOALIGN-NEXT: 01000000 00000000 00000000 00000000 # NOALIGN-NEXT: 00000000 00000000 00000000 00000000 @@ -17,7 +17,7 @@ # RUN: echo "SECTIONS { .aaa : SUBALIGN(1) { *(.aaa.*) } }" > %t2.script # RUN: ld.lld -o %t2 --script %t2.script %t1.o -# RUN: llvm-objdump -s %t2 | FileCheck -check-prefix=SUBALIGN %s +# RUN: llvm-objdump -s -section=.aaa %t2 | FileCheck -check-prefix=SUBALIGN %s # SUBALIGN: Contents of section .aaa: # SUBALIGN: 01000000 00000000 02000000 00000000 # SUBALIGN: 03000000 00000000 04000000 00000000 Index: test/ELF/mips-nonalloc.s =================================================================== --- test/ELF/mips-nonalloc.s +++ test/ELF/mips-nonalloc.s @@ -4,7 +4,7 @@ # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ # RUN: %S/Inputs/mips-nonalloc.s -o %t2.o # RUN: ld.lld %t1.o %t2.o -o %t.exe -# RUN: llvm-objdump -s %t.exe | FileCheck %s +# RUN: llvm-objdump -s -section=.debug_info %t.exe | FileCheck %s # REQUIRES: mips Index: test/ELF/mips-relocatable.s =================================================================== --- test/ELF/mips-relocatable.s +++ test/ELF/mips-relocatable.s @@ -2,7 +2,7 @@ # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o # RUN: ld.lld -r -o %t-r.o %t.o -# RUN: llvm-objdump -s -t %t-r.o | FileCheck %s +# RUN: llvm-objdump -s -section=.rodata -t %t-r.o | FileCheck %s # REQUIRES: mips Index: test/ELF/mips-tls-static-64.s =================================================================== --- test/ELF/mips-tls-static-64.s +++ test/ELF/mips-tls-static-64.s @@ -3,7 +3,7 @@ # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux %s -o %t # RUN: ld.lld -static %t -o %t.exe -# RUN: llvm-objdump -s -t %t.exe | FileCheck %s +# RUN: llvm-objdump -s -section=.data -t %t.exe | FileCheck %s # REQUIRES: mips Index: test/ELF/mips-tls-static.s =================================================================== --- test/ELF/mips-tls-static.s +++ test/ELF/mips-tls-static.s @@ -3,7 +3,7 @@ # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t # RUN: ld.lld -static %t -o %t.exe -# RUN: llvm-objdump -s -t %t.exe | FileCheck %s +# RUN: llvm-objdump -s -section=.got -section=.data -t %t.exe | FileCheck %s # REQUIRES: mips Index: test/ELF/no-merge.s =================================================================== --- test/ELF/no-merge.s +++ test/ELF/no-merge.s @@ -2,7 +2,7 @@ # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o # RUN: echo "SECTIONS { .data : {*(.data.*)} }" > %t0.script # RUN: ld.lld %t.o -o %t0.out --script %t0.script -# RUN: llvm-objdump -s %t0.out | FileCheck %s --check-prefix=OPT +# RUN: llvm-objdump -s -section=.data %t0.out | FileCheck %s --check-prefix=OPT # OPT: Contents of section .data: # OPT-NEXT: 0000 01 # OPT-NEXT: Contents of section .data: @@ -11,7 +11,7 @@ # OPT-NEXT: 0003 03 # RUN: ld.lld -O0 %t.o -o %t1.out --script %t0.script -# RUN: llvm-objdump -s %t1.out | FileCheck %s --check-prefix=NOOPT +# RUN: llvm-objdump -s -section=.data %t1.out | FileCheck %s --check-prefix=NOOPT # NOOPT: Contents of section .data: # NOOPT-NEXT: 0000 01610003 Index: test/ELF/relocatable.s =================================================================== --- test/ELF/relocatable.s +++ test/ELF/relocatable.s @@ -4,12 +4,12 @@ # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %p/Inputs/relocatable2.s -o %t3.o # RUN: ld.lld -r %t1.o %t2.o %t3.o -o %t # RUN: llvm-readobj -file-headers -sections -program-headers -symbols -r %t | FileCheck %s -# RUN: llvm-objdump -s -d %t | FileCheck -check-prefix=CHECKTEXT %s +# RUN: llvm-objdump -s -section=.text -d %t | FileCheck -check-prefix=CHECKTEXT %s ## Test --relocatable alias # RUN: ld.lld --relocatable %t1.o %t2.o %t3.o -o %t # RUN: llvm-readobj -file-headers -sections -program-headers -symbols -r %t | FileCheck %s -# RUN: llvm-objdump -s -d %t | FileCheck -check-prefix=CHECKTEXT %s +# RUN: llvm-objdump -s -section=.text -d %t | FileCheck -check-prefix=CHECKTEXT %s ## Verify that we can use our relocation output as input to produce executable # RUN: ld.lld -e main %t -o %texec Index: test/ELF/relocation-local.s =================================================================== --- test/ELF/relocation-local.s +++ test/ELF/relocation-local.s @@ -1,7 +1,7 @@ // Test that relocation of local symbols is working. // RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t // RUN: ld.lld %t -o %t2 -// RUN: llvm-objdump -s -d %t2 | FileCheck %s +// RUN: llvm-objdump -s -section=.text2 -section=.R_X86_64_32S -section=.R_X86_64_64 -d %t2 | FileCheck %s // REQUIRES: x86 Index: test/ELF/startstop-shared2.s =================================================================== --- test/ELF/startstop-shared2.s +++ test/ELF/startstop-shared2.s @@ -3,7 +3,7 @@ // RUN: ld.lld -o %t.so %t.o -shared // RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t2.o // RUN: ld.lld -o %t %t2.o %t.so -// RUN: llvm-objdump -s -h %t | FileCheck %s +// RUN: llvm-objdump -s -section=.text -section=foo -h %t | FileCheck %s // CHECK: foo 00000000 0000000000201008 Index: test/ELF/symbol-ordering-file.s =================================================================== --- test/ELF/symbol-ordering-file.s +++ test/ELF/symbol-ordering-file.s @@ -1,7 +1,7 @@ # REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o # RUN: ld.lld %t.o -o %t.out -# RUN: llvm-objdump -s %t.out| FileCheck %s --check-prefix=BEFORE +# RUN: llvm-objdump -s -section=.foo %t.out| FileCheck %s --check-prefix=BEFORE # BEFORE: Contents of section .foo: # BEFORE-NEXT: 201000 11223344 5566 @@ -16,7 +16,7 @@ # RUN: echo "_foo1" >> %t_order.txt # RUN: ld.lld --symbol-ordering-file %t_order.txt %t.o -o %t2.out -# RUN: llvm-objdump -s %t2.out| FileCheck %s --check-prefix=AFTER +# RUN: llvm-objdump -s -section=.foo %t2.out| FileCheck %s --check-prefix=AFTER # AFTER: Contents of section .foo: # AFTER-NEXT: 201000 44335566 2211