[llvm] aa3df8d - [test] Avoid llvm-readelf/llvm-readobj one-dash long options and deprecated aliases (e.g. --file-headers)
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 15 10:26:27 PDT 2021
Author: Fangrui Song
Date: 2021-07-15T10:26:21-07:00
New Revision: aa3df8ddcd52ec5e40e73cf8d25471145e3913cb
URL: https://github.com/llvm/llvm-project/commit/aa3df8ddcd52ec5e40e73cf8d25471145e3913cb
DIFF: https://github.com/llvm/llvm-project/commit/aa3df8ddcd52ec5e40e73cf8d25471145e3913cb.diff
LOG: [test] Avoid llvm-readelf/llvm-readobj one-dash long options and deprecated aliases (e.g. --file-headers)
Added:
Modified:
compiler-rt/test/asan/TestCases/Windows/delay_dbghelp.cpp
lld/test/COFF/resource-objs.test
llvm/test/CodeGen/AArch64/win64-jumptable.ll
llvm/test/CodeGen/AMDGPU/amdgpu-reloc-const.ll
llvm/test/CodeGen/AMDGPU/code-object-v3.ll
llvm/test/CodeGen/AMDGPU/elf-header-flags-mach.ll
llvm/test/CodeGen/AMDGPU/elf-header-flags-sramecc.ll
llvm/test/CodeGen/AMDGPU/hsa-metadata-kernel-code-props-v3.ll
llvm/test/CodeGen/PowerPC/aix-return55.ll
llvm/test/CodeGen/PowerPC/aix-xcoff-data-sections.ll
llvm/test/CodeGen/PowerPC/aix-xcoff-explicit-section.ll
llvm/test/CodeGen/PowerPC/aix-xcoff-mergeable-const.ll
llvm/test/DebugInfo/PDB/annotation.test
llvm/test/MC/AMDGPU/hsa-gfx10-v3.s
llvm/test/MC/AMDGPU/hsa-v3.s
llvm/test/MC/AMDGPU/hsa-v4.s
llvm/test/MC/AMDGPU/reloc.s
llvm/test/MC/ARM/mappingsymbols.s
llvm/test/MC/ELF/comdat-name-number.s
llvm/test/MC/MachO/loc.s
llvm/test/MC/MachO/reloc-pcrel-offset.s
llvm/test/MC/WebAssembly/debug-info.ll
llvm/test/MC/WebAssembly/debug-info64.ll
llvm/test/MC/WebAssembly/func-address.ll
llvm/test/lit.cfg.py
llvm/test/tools/llvm-objcopy/ELF/compress-debug-sections-groups.test
llvm/test/tools/llvm-objcopy/ELF/group-big-endian.test
llvm/test/tools/llvm-objcopy/ELF/group-reorder.test
llvm/test/tools/llvm-objcopy/ELF/group-unchanged.test
llvm/test/tools/llvm-objcopy/ELF/group.test
llvm/test/tools/llvm-objcopy/ELF/strip-dwo-groups.test
llvm/test/tools/llvm-objcopy/MachO/remove-swift-symbols.test
llvm/test/tools/llvm-readobj/ELF/demangle.test
llvm/test/tools/llvm-readobj/ELF/groups.test
llvm/test/tools/llvm-readobj/ELF/packed-relocs.test
llvm/test/tools/obj2yaml/ELF/program-headers.yaml
llvm/test/tools/yaml2obj/ELF/comdat-broken.yaml
llvm/test/tools/yaml2obj/ELF/duplicate-section-names.yaml
Removed:
################################################################################
diff --git a/compiler-rt/test/asan/TestCases/Windows/delay_dbghelp.cpp b/compiler-rt/test/asan/TestCases/Windows/delay_dbghelp.cpp
index 81cd2d389c3b4..53c06e006da07 100644
--- a/compiler-rt/test/asan/TestCases/Windows/delay_dbghelp.cpp
+++ b/compiler-rt/test/asan/TestCases/Windows/delay_dbghelp.cpp
@@ -1,6 +1,6 @@
// Build an executable with ASan, then extract the DLLs that it depends on.
// RUN: %clang_cl_asan %s -Fe%t.exe
-// RUN: llvm-readobj -coff-imports %t.exe | grep Name: | sed -e 's/ *Name: *//' > %t
+// RUN: llvm-readobj --coff-imports %t.exe | grep Name: | sed -e 's/ *Name: *//' > %t
//
// Make sure the binary doesn't depend on dbghelp directly.
// RUN: not grep dbghelp.dll %t
diff --git a/lld/test/COFF/resource-objs.test b/lld/test/COFF/resource-objs.test
index d28cc14d81796..08fc503d3141a 100644
--- a/lld/test/COFF/resource-objs.test
+++ b/lld/test/COFF/resource-objs.test
@@ -1,5 +1,5 @@
# RUN: lld-link /out:%t.exe /dll /noentry %S/Inputs/id.res.o
-# RUN: llvm-readobj -file-headers %t.exe | FileCheck %s
+# RUN: llvm-readobj --file-header %t.exe | FileCheck %s
CHECK: ResourceTableRVA: 0x1000
CHECK: ResourceTableSize: 0x80
diff --git a/llvm/test/CodeGen/AArch64/win64-jumptable.ll b/llvm/test/CodeGen/AArch64/win64-jumptable.ll
index 7c4efa22f609f..4c19ee877243d 100644
--- a/llvm/test/CodeGen/AArch64/win64-jumptable.ll
+++ b/llvm/test/CodeGen/AArch64/win64-jumptable.ll
@@ -1,5 +1,5 @@
; RUN: llc -o - %s -mtriple=aarch64-windows -aarch64-enable-compress-jump-tables=0 | FileCheck %s
-; RUN: llc -o - %s -mtriple=aarch64-windows -aarch64-enable-compress-jump-tables=0 -filetype=obj | llvm-readobj -unwind - | FileCheck %s -check-prefix=UNWIND
+; RUN: llc -o - %s -mtriple=aarch64-windows -aarch64-enable-compress-jump-tables=0 -filetype=obj | llvm-readobj --unwind - | FileCheck %s -check-prefix=UNWIND
define void @f(i32 %x) {
entry:
diff --git a/llvm/test/CodeGen/AMDGPU/amdgpu-reloc-const.ll b/llvm/test/CodeGen/AMDGPU/amdgpu-reloc-const.ll
index ec7fce8be299d..365e1dbcdbb4a 100644
--- a/llvm/test/CodeGen/AMDGPU/amdgpu-reloc-const.ll
+++ b/llvm/test/CodeGen/AMDGPU/amdgpu-reloc-const.ll
@@ -1,8 +1,8 @@
; RUN: llc -march=amdgcn -verify-machineinstrs < %s | FileCheck -check-prefix=GCN %s
-; RUN: llc -mtriple=amdgcn--amdpal -mcpu=gfx900 -filetype=obj -o %t.o < %s && llvm-readobj -relocations %t.o | FileCheck --check-prefix=ELF %s
+; RUN: llc -mtriple=amdgcn--amdpal -mcpu=gfx900 -filetype=obj -o %t.o < %s && llvm-readobj -r %t.o | FileCheck --check-prefix=ELF %s
; RUN: llc -global-isel -march=amdgcn -verify-machineinstrs < %s | FileCheck -check-prefix=GCN %s
-; RUN: llc -global-isel -mtriple=amdgcn--amdpal -mcpu=gfx900 -filetype=obj -o %t.o < %s && llvm-readobj -relocations %t.o | FileCheck --check-prefix=ELF %s
+; RUN: llc -global-isel -mtriple=amdgcn--amdpal -mcpu=gfx900 -filetype=obj -o %t.o < %s && llvm-readobj -r %t.o | FileCheck --check-prefix=ELF %s
; GCN-LABEL: {{^}}ps_main:
; GCN: v_mov_b32_{{.*}} v[[relocreg:[0-9]+]], doff_0_0_b at abs32@lo
diff --git a/llvm/test/CodeGen/AMDGPU/code-object-v3.ll b/llvm/test/CodeGen/AMDGPU/code-object-v3.ll
index 7d0dd5f0ee0bf..c2140c202f4d1 100644
--- a/llvm/test/CodeGen/AMDGPU/code-object-v3.ll
+++ b/llvm/test/CodeGen/AMDGPU/code-object-v3.ll
@@ -1,5 +1,5 @@
; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 < %s | FileCheck --check-prefixes=ALL-ASM,OSABI-AMDHSA-ASM %s
-; RUN: llc -filetype=obj -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 < %s | llvm-readelf --notes -relocations -sections -symbols - | FileCheck --check-prefix=OSABI-AMDHSA-ELF %s
+; RUN: llc -filetype=obj -mtriple=amdgcn-amd-amdhsa -mcpu=gfx803 < %s | llvm-readelf -S -r -s --notes - | FileCheck --check-prefix=OSABI-AMDHSA-ELF %s
; ALL-ASM-LABEL: {{^}}fadd:
diff --git a/llvm/test/CodeGen/AMDGPU/elf-header-flags-mach.ll b/llvm/test/CodeGen/AMDGPU/elf-header-flags-mach.ll
index e8d89ed0879a6..329dbc6d024e7 100644
--- a/llvm/test/CodeGen/AMDGPU/elf-header-flags-mach.ll
+++ b/llvm/test/CodeGen/AMDGPU/elf-header-flags-mach.ll
@@ -1,69 +1,69 @@
-; RUN: llc -filetype=obj -march=r600 -mcpu=r600 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,R600 %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=r630 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,R630 %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=rs880 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RS880 %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=rv670 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV670 %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=rv710 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV710 %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=rv730 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV730 %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=rv770 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,RV770 %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=cedar < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CEDAR %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=cypress < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CYPRESS %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=juniper < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,JUNIPER %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=redwood < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,REDWOOD %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=sumo < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,SUMO %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=barts < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,BARTS %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=caicos < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CAICOS %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=cayman < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,CAYMAN %s
-; RUN: llc -filetype=obj -march=r600 -mcpu=turks < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-R600,TURKS %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx600 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX600 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=tahiti < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX600 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx601 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=pitcairn < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=verde < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx602 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX602 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=hainan < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX602 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=oland < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX602 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx700 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX700 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=kaveri < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX700 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx701 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX701 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=hawaii < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX701 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx702 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX702 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx703 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=kabini < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=mullins < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx704 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX704 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=bonaire < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX704 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx705 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX705 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx801 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX801 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=carrizo < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX801 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx802 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=iceland < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=tonga < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx803 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=fiji < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=polaris10 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=polaris11 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx805 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX805 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=tongapro < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX805 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx810 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX810 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=stoney < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX810 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx900 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX900 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx902 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX902 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx904 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX904 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX906 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx908 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX908 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx909 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX909 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx90a < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX90A %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx90c < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX90C %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1010 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1010 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1011 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1011 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1012 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1012 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1013 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1013 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1030 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1030 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1031 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1031 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1032 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1032 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1033 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1033 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1034 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1034 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1035 < %s | llvm-readobj -file-headers - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1035 %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=r600 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,R600 %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=r630 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,R630 %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=rs880 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,RS880 %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=rv670 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,RV670 %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=rv710 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,RV710 %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=rv730 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,RV730 %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=rv770 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,RV770 %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=cedar < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,CEDAR %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=cypress < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,CYPRESS %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=juniper < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,JUNIPER %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=redwood < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,REDWOOD %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=sumo < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,SUMO %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=barts < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,BARTS %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=caicos < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,CAICOS %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=cayman < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,CAYMAN %s
+; RUN: llc -filetype=obj -march=r600 -mcpu=turks < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-R600,TURKS %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx600 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX600 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=tahiti < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX600 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx601 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=pitcairn < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=verde < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX601 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx602 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX602 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=hainan < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX602 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=oland < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX602 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx700 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX700 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=kaveri < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX700 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx701 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX701 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=hawaii < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX701 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx702 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX702 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx703 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=kabini < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=mullins < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX703 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx704 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX704 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=bonaire < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX704 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx705 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX705 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx801 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX801 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=carrizo < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX801 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx802 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=iceland < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=tonga < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX802 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx803 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=fiji < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=polaris10 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=polaris11 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX803 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx805 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX805 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=tongapro < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX805 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx810 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX810 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=stoney < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX810 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx900 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX900 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx902 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX902 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx904 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX904 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX906 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx908 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX908 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx909 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX909 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx90a < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX90A %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx90c < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX90C %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1010 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1010 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1011 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1011 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1012 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1012 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1013 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1013 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1030 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1030 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1031 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1031 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1032 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1032 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1033 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1033 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1034 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1034 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx1035 < %s | llvm-readobj --file-header - | FileCheck --check-prefixes=ALL,ARCH-GCN,GFX1035 %s
; FIXME: With the default attributes the eflags are not accurate for
; xnack and sramecc. Subsequent Target-ID patches will address this.
diff --git a/llvm/test/CodeGen/AMDGPU/elf-header-flags-sramecc.ll b/llvm/test/CodeGen/AMDGPU/elf-header-flags-sramecc.ll
index 69662de040326..144061dfdf829 100644
--- a/llvm/test/CodeGen/AMDGPU/elf-header-flags-sramecc.ll
+++ b/llvm/test/CodeGen/AMDGPU/elf-header-flags-sramecc.ll
@@ -3,11 +3,11 @@
; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 -mattr=+sramecc < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=SRAM-ECC-GFX906 %s
; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx906 -mattr=+sramecc,+xnack < %s | llvm-readobj --file-headers - | FileCheck --check-prefixes=SRAM-ECC-XNACK-GFX906 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx908 < %s | llvm-readobj -file-headers - | FileCheck --check-prefix=SRAM-ECC-GFX908 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx908 -mattr=+sramecc < %s | llvm-readobj -file-headers - | FileCheck --check-prefix=SRAM-ECC-GFX908 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx908 < %s | llvm-readobj --file-header - | FileCheck --check-prefix=SRAM-ECC-GFX908 %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx908 -mattr=+sramecc < %s | llvm-readobj --file-header - | FileCheck --check-prefix=SRAM-ECC-GFX908 %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx90a < %s | llvm-readobj -file-headers - | FileCheck --check-prefix=SRAM-ECC-GFX90A %s
-; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx90a < %s | llvm-readobj -file-headers - | FileCheck --check-prefix=SRAM-ECC-GFX90A %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx90a < %s | llvm-readobj --file-header - | FileCheck --check-prefix=SRAM-ECC-GFX90A %s
+; RUN: llc -filetype=obj -march=amdgcn -mcpu=gfx90a < %s | llvm-readobj --file-header - | FileCheck --check-prefix=SRAM-ECC-GFX90A %s
; NO-SRAM-ECC-GFX906: Flags [
; NO-SRAM-ECC-GFX906-NEXT: EF_AMDGPU_FEATURE_XNACK_V3 (0x100)
diff --git a/llvm/test/CodeGen/AMDGPU/hsa-metadata-kernel-code-props-v3.ll b/llvm/test/CodeGen/AMDGPU/hsa-metadata-kernel-code-props-v3.ll
index bd16b9e0585d3..0c5555547eec4 100644
--- a/llvm/test/CodeGen/AMDGPU/hsa-metadata-kernel-code-props-v3.ll
+++ b/llvm/test/CodeGen/AMDGPU/hsa-metadata-kernel-code-props-v3.ll
@@ -1,7 +1,7 @@
-; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 --amdhsa-code-object-version=3 -enable-misched=0 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes - | FileCheck --check-prefixes=CHECK,GFX700,WAVE64 %s
-; RUN: llc -mattr=-xnack -mtriple=amdgcn-amd-amdhsa --amdhsa-code-object-version=3 -mcpu=gfx803 -enable-misched=0 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes - | FileCheck --check-prefixes=CHECK,GFX803,WAVE64 %s
-; RUN: llc -mattr=-xnack -mtriple=amdgcn-amd-amdhsa --amdhsa-code-object-version=3 -mcpu=gfx900 -enable-misched=0 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes - | FileCheck --check-prefixes=CHECK,GFX900,WAVE64 %s
-; RUN: llc -mattr=-xnack -mtriple=amdgcn-amd-amdhsa --amdhsa-code-object-version=3 -mcpu=gfx1010 -enable-misched=0 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes - | FileCheck --check-prefixes=CHECK,GFX1010,WAVE32 %s
+; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 --amdhsa-code-object-version=3 -enable-misched=0 -filetype=obj -o - < %s | llvm-readelf --notes - | FileCheck --check-prefixes=CHECK,GFX700,WAVE64 %s
+; RUN: llc -mattr=-xnack -mtriple=amdgcn-amd-amdhsa --amdhsa-code-object-version=3 -mcpu=gfx803 -enable-misched=0 -filetype=obj -o - < %s | llvm-readelf --notes - | FileCheck --check-prefixes=CHECK,GFX803,WAVE64 %s
+; RUN: llc -mattr=-xnack -mtriple=amdgcn-amd-amdhsa --amdhsa-code-object-version=3 -mcpu=gfx900 -enable-misched=0 -filetype=obj -o - < %s | llvm-readelf --notes - | FileCheck --check-prefixes=CHECK,GFX900,WAVE64 %s
+; RUN: llc -mattr=-xnack -mtriple=amdgcn-amd-amdhsa --amdhsa-code-object-version=3 -mcpu=gfx1010 -enable-misched=0 -filetype=obj -o - < %s | llvm-readelf --notes - | FileCheck --check-prefixes=CHECK,GFX1010,WAVE32 %s
@var = addrspace(1) global float 0.0
diff --git a/llvm/test/CodeGen/PowerPC/aix-return55.ll b/llvm/test/CodeGen/PowerPC/aix-return55.ll
index 5daf3d1b6d38f..c16b75bb68d8d 100644
--- a/llvm/test/CodeGen/PowerPC/aix-return55.ll
+++ b/llvm/test/CodeGen/PowerPC/aix-return55.ll
@@ -3,7 +3,7 @@
; RUN: llc -mcpu=pwr4 -mattr=-altivec -mtriple=powerpc-ibm-aix-xcoff \
; RUN: -verify-machineinstrs -data-sections=false -xcoff-traceback-table=false -filetype=obj -o %t.o < %s
; RUN: llvm-objdump -D %t.o | FileCheck --check-prefix=CHECKOBJ %s
-; RUN: llvm-readobj -sections %t.o | FileCheck --check-prefix=CHECKSECT %s
+; RUN: llvm-readobj -S %t.o | FileCheck --check-prefix=CHECKSECT %s
; RUN: not --crash llc -mtriple powerpc64-ibm-aix-xcoff -filetype=obj < %s 2>&1 | \
; RUN: FileCheck --check-prefix=XCOFF64 %s
diff --git a/llvm/test/CodeGen/PowerPC/aix-xcoff-data-sections.ll b/llvm/test/CodeGen/PowerPC/aix-xcoff-data-sections.ll
index ded35b94840b5..83b5c06ce6074 100644
--- a/llvm/test/CodeGen/PowerPC/aix-xcoff-data-sections.ll
+++ b/llvm/test/CodeGen/PowerPC/aix-xcoff-data-sections.ll
@@ -6,7 +6,7 @@
; RUN: llc -verify-machineinstrs -mcpu=pwr4 -mattr=-altivec -mtriple powerpc-ibm-aix-xcoff \
; RUN: -filetype=obj -data-sections -xcoff-traceback-table=false -o %t.o < %s
; RUN: llvm-objdump -D --symbol-description %t.o | FileCheck --check-prefix=CHECKOBJ %s
-; RUN: llvm-readobj -syms %t.o | FileCheck --check-prefix=CHECKSYM %s
+; RUN: llvm-readobj -s %t.o | FileCheck --check-prefix=CHECKSYM %s
;; Test to see if the default is correct for -data-sections on AIX.
; RUN: llc -verify-machineinstrs -mcpu=pwr4 -mattr=-altivec -mtriple powerpc-ibm-aix-xcoff \
@@ -17,7 +17,7 @@
; RUN: llc -verify-machineinstrs -mcpu=pwr4 -mattr=-altivec -mtriple powerpc-ibm-aix-xcoff \
; RUN: -xcoff-traceback-table=false -filetype=obj -o %t.o < %s
; RUN: llvm-objdump -D --symbol-description %t.o | FileCheck --check-prefix=CHECKOBJ %s
-; RUN: llvm-readobj -syms %t.o | FileCheck --check-prefix=CHECKSYM %s
+; RUN: llvm-readobj -s %t.o | FileCheck --check-prefix=CHECKSYM %s
;; Test to see if the default is correct for -data-sections on AIX.
; RUN: llc -verify-machineinstrs -mcpu=pwr4 -mattr=-altivec -mtriple powerpc-ibm-aix-xcoff \
@@ -29,7 +29,7 @@
; RUN: llc -verify-machineinstrs -mcpu=pwr4 -mattr=-altivec -mtriple powerpc-ibm-aix-xcoff \
; RUN: -xcoff-traceback-table=false -filetype=obj -o %t.o < %s
; RUN: llvm-objdump -D --symbol-description %t.o | FileCheck --check-prefix=CHECKOBJ %s
-; RUN: llvm-readobj -syms %t.o | FileCheck --check-prefix=CHECKSYM %s
+; RUN: llvm-readobj -s %t.o | FileCheck --check-prefix=CHECKSYM %s
@ivar = local_unnamed_addr global i32 35, align 4
@const_ivar = constant i32 35, align 4
diff --git a/llvm/test/CodeGen/PowerPC/aix-xcoff-explicit-section.ll b/llvm/test/CodeGen/PowerPC/aix-xcoff-explicit-section.ll
index 4bdac1c998ea3..3c159fd848fcc 100644
--- a/llvm/test/CodeGen/PowerPC/aix-xcoff-explicit-section.ll
+++ b/llvm/test/CodeGen/PowerPC/aix-xcoff-explicit-section.ll
@@ -5,7 +5,7 @@
; RUN: llc -verify-machineinstrs -mcpu=pwr4 -mattr=-altivec -mtriple powerpc-ibm-aix-xcoff \
; RUN: -xcoff-traceback-table=false -filetype=obj -o %t.o < %s
; RUN: llvm-objdump -D --symbol-description %t.o | FileCheck --check-prefix=CHECKOBJ %s
-; RUN: llvm-readobj -syms %t.o | FileCheck --check-prefix=CHECKSYM %s
+; RUN: llvm-readobj -s %t.o | FileCheck --check-prefix=CHECKSYM %s
@ext_const = constant i32 1, section ".ext_const_sec", align 4
@ext_var = global i32 1, section ".ext_var_sec", align 4
diff --git a/llvm/test/CodeGen/PowerPC/aix-xcoff-mergeable-const.ll b/llvm/test/CodeGen/PowerPC/aix-xcoff-mergeable-const.ll
index a296ed649e49f..255472d65c341 100644
--- a/llvm/test/CodeGen/PowerPC/aix-xcoff-mergeable-const.ll
+++ b/llvm/test/CodeGen/PowerPC/aix-xcoff-mergeable-const.ll
@@ -9,7 +9,7 @@
; RUN: llc -verify-machineinstrs -mcpu=pwr4 -mattr=-altivec -mtriple powerpc-ibm-aix-xcoff \
; RUN: -xcoff-traceback-table=false -data-sections=false -filetype=obj -o %t.o < %s
; RUN: llvm-objdump -D %t.o | FileCheck --check-prefix=CHECKOBJ %s
-; RUN: llvm-readobj -syms %t.o | FileCheck --check-prefix=CHECKSYM %s
+; RUN: llvm-readobj -s %t.o | FileCheck --check-prefix=CHECKSYM %s
%struct.Merge_cnst32 = type { i64, i32, i64, i32 }
%struct.Merge_cnst16 = type { i64, i32 }
diff --git a/llvm/test/DebugInfo/PDB/annotation.test b/llvm/test/DebugInfo/PDB/annotation.test
index f1c9357c36ad2..fcab095683a3f 100644
--- a/llvm/test/DebugInfo/PDB/annotation.test
+++ b/llvm/test/DebugInfo/PDB/annotation.test
@@ -1,6 +1,6 @@
# RUN: yaml2obj %s -o %t.obj
# RUN: llvm-pdbutil dump --symbols %t.obj | FileCheck %s
-# RUN: llvm-readobj -codeview %t.obj | FileCheck %s --check-prefix=READOBJ
+# RUN: llvm-readobj --codeview %t.obj | FileCheck %s --check-prefix=READOBJ
# CHECK: S_ANNOTATION [size = 20]
# CHECK-NEXT: addr = 0001:0042
diff --git a/llvm/test/MC/AMDGPU/hsa-gfx10-v3.s b/llvm/test/MC/AMDGPU/hsa-gfx10-v3.s
index 6de81f57bf710..b7a7ad824851e 100644
--- a/llvm/test/MC/AMDGPU/hsa-gfx10-v3.s
+++ b/llvm/test/MC/AMDGPU/hsa-gfx10-v3.s
@@ -1,6 +1,6 @@
// RUN: llvm-mc -triple amdgcn-amd-amdhsa -mcpu=gfx1010 --amdhsa-code-object-version=3 -mattr=+xnack < %s | FileCheck --check-prefix=ASM %s
// RUN: llvm-mc -triple amdgcn-amd-amdhsa -mcpu=gfx1010 --amdhsa-code-object-version=3 -mattr=+xnack -filetype=obj < %s > %t
-// RUN: llvm-readobj -elf-output-style=GNU -sections -symbols -relocations %t | FileCheck --check-prefix=READOBJ %s
+// RUN: llvm-readelf -S -r -s %t | FileCheck --check-prefix=READOBJ %s
// RUN: llvm-objdump -s -j .rodata %t | FileCheck --check-prefix=OBJDUMP %s
// READOBJ: Section Headers
diff --git a/llvm/test/MC/AMDGPU/hsa-v3.s b/llvm/test/MC/AMDGPU/hsa-v3.s
index c98a7da36e623..76b82d4ae3321 100644
--- a/llvm/test/MC/AMDGPU/hsa-v3.s
+++ b/llvm/test/MC/AMDGPU/hsa-v3.s
@@ -1,6 +1,6 @@
// RUN: llvm-mc -triple amdgcn-amd-amdhsa -mcpu=gfx904 --amdhsa-code-object-version=3 -mattr=+xnack < %s | FileCheck --check-prefix=ASM %s
// RUN: llvm-mc -triple amdgcn-amd-amdhsa -mcpu=gfx904 --amdhsa-code-object-version=3 -mattr=+xnack -filetype=obj < %s > %t
-// RUN: llvm-readelf -sections -symbols -relocations %t | FileCheck --check-prefix=READOBJ %s
+// RUN: llvm-readelf -S -r -s %t | FileCheck --check-prefix=READOBJ %s
// RUN: llvm-objdump -s -j .rodata %t | FileCheck --check-prefix=OBJDUMP %s
// READOBJ: Section Headers
diff --git a/llvm/test/MC/AMDGPU/hsa-v4.s b/llvm/test/MC/AMDGPU/hsa-v4.s
index b1941184150ed..61dbf75c3fa93 100644
--- a/llvm/test/MC/AMDGPU/hsa-v4.s
+++ b/llvm/test/MC/AMDGPU/hsa-v4.s
@@ -1,6 +1,6 @@
// RUN: llvm-mc -triple amdgcn-amd-amdhsa -mcpu=gfx904 --amdhsa-code-object-version=4 -mattr=+xnack < %s | FileCheck --check-prefix=ASM %s
// RUN: llvm-mc -triple amdgcn-amd-amdhsa -mcpu=gfx904 --amdhsa-code-object-version=4 -mattr=+xnack -filetype=obj < %s > %t
-// RUN: llvm-readelf -sections -symbols -relocations %t | FileCheck --check-prefix=READOBJ %s
+// RUN: llvm-readelf -S -r -s %t | FileCheck --check-prefix=READOBJ %s
// RUN: llvm-objdump -s -j .rodata %t | FileCheck --check-prefix=OBJDUMP %s
// READOBJ: Section Headers
diff --git a/llvm/test/MC/AMDGPU/reloc.s b/llvm/test/MC/AMDGPU/reloc.s
index cdb2f154459fa..62cccb13e9060 100644
--- a/llvm/test/MC/AMDGPU/reloc.s
+++ b/llvm/test/MC/AMDGPU/reloc.s
@@ -1,4 +1,4 @@
-// RUN: llvm-mc -filetype=obj -triple amdgcn-- -mcpu=kaveri -show-encoding %s | llvm-readobj -relocations - | FileCheck %s
+// RUN: llvm-mc -filetype=obj -triple amdgcn-- -mcpu=kaveri -show-encoding %s | llvm-readobj -r - | FileCheck %s
// CHECK: Relocations [
// CHECK: .rel.text {
diff --git a/llvm/test/MC/ARM/mappingsymbols.s b/llvm/test/MC/ARM/mappingsymbols.s
index 55a6be3c7bc66..a651f46df798c 100644
--- a/llvm/test/MC/ARM/mappingsymbols.s
+++ b/llvm/test/MC/ARM/mappingsymbols.s
@@ -1,40 +1,40 @@
# Check section containing code and data with permission executable for the section.
@ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/1.s
-@ RUN: llvm-readelf -symbols %t.o | FileCheck %s
+@ RUN: llvm-readelf -s %t.o | FileCheck %s
# Check section containing code and data with no permissions for the section.
@ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/2.s
-@ RUN: llvm-readelf -symbols %t.o | FileCheck %s
+@ RUN: llvm-readelf -s %t.o | FileCheck %s
# Check section containing code and data with read/write permissions for the section.
@ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/3.s
-@ RUN: llvm-readelf -symbols %t.o | FileCheck %s
+@ RUN: llvm-readelf -s %t.o | FileCheck %s
# Check section containing data with no permissions for the section.
@ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/4.s
-@ RUN: llvm-readelf -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
+@ RUN: llvm-readelf -s %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
# Check section containing only data with read/write permissions for the section.
@ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/5.s
-@ RUN: llvm-readelf -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
+@ RUN: llvm-readelf -s %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
# Check section containing the ident string with no permissions for the section.
@ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/ident.s
-@ RUN: llvm-readelf -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
+@ RUN: llvm-readelf -s %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
# Check section containing the attributes with no permissions for the section.
@ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/attr.s
-@ RUN: llvm-readelf -symbols %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
+@ RUN: llvm-readelf -s %t.o | FileCheck %s -check-prefix=MAPPINGSYMBOLS
# Check section containing code and data with no permissions for the section.
# data comes before code.
@ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/6.s
-@ RUN: llvm-readelf -symbols %t.o | FileCheck %s -check-prefix=MIX
+@ RUN: llvm-readelf -s %t.o | FileCheck %s -check-prefix=MIX
# Check section containing code and data with no permissions for the section.
# data comes before code.
@ RUN: llvm-mc -triple armv7-none-linux -filetype=obj -o %t.o %p/Inputs/7.s
-@ RUN: llvm-readelf -symbols %t.o | FileCheck %s
+@ RUN: llvm-readelf -s %t.o | FileCheck %s
#CHECK-DAG: $a
#CHECK-DAG: $d
diff --git a/llvm/test/MC/ELF/comdat-name-number.s b/llvm/test/MC/ELF/comdat-name-number.s
index 48220d484c924..6bfa30e4d28e5 100644
--- a/llvm/test/MC/ELF/comdat-name-number.s
+++ b/llvm/test/MC/ELF/comdat-name-number.s
@@ -1,5 +1,5 @@
// RUN: llvm-mc -triple x86_64-pc-linux-gnu %s -filetype=obj -o %t.o
-// RUN: llvm-readobj --elf-section-groups %t.o | FileCheck %s
+// RUN: llvm-readobj --section-groups %t.o | FileCheck %s
// Test that we can handle numeric COMDAT names.
diff --git a/llvm/test/MC/MachO/loc.s b/llvm/test/MC/MachO/loc.s
index 10dfc5d55d706..261fc12cb26e2 100644
--- a/llvm/test/MC/MachO/loc.s
+++ b/llvm/test/MC/MachO/loc.s
@@ -1,4 +1,4 @@
-// RUN: llvm-mc -triple i386-apple-darwin9 %s -filetype=obj -o - | llvm-readobj -r -S --sd - | FileCheck %s
+// RUN: llvm-mc -triple i386-apple-darwin9 %s -filetype=obj -o - | llvm-readobj -S -r --sd - | FileCheck %s
.file 2 "foo"
.file 1 "bar"
.loc 2 64 0
diff --git a/llvm/test/MC/MachO/reloc-pcrel-offset.s b/llvm/test/MC/MachO/reloc-pcrel-offset.s
index 5711069167c47..a16584d8bfac4 100644
--- a/llvm/test/MC/MachO/reloc-pcrel-offset.s
+++ b/llvm/test/MC/MachO/reloc-pcrel-offset.s
@@ -1,4 +1,4 @@
-// RUN: llvm-mc -n -triple i386-apple-darwin9 %s -filetype=obj -o - | llvm-readobj -r -S --sd - | FileCheck %s
+// RUN: llvm-mc -n -triple i386-apple-darwin9 %s -filetype=obj -o - | llvm-readobj -S -r --sd - | FileCheck %s
.data
.long 0
diff --git a/llvm/test/MC/WebAssembly/debug-info.ll b/llvm/test/MC/WebAssembly/debug-info.ll
index 167d912c84a2b..a4a9ed9ed1936 100644
--- a/llvm/test/MC/WebAssembly/debug-info.ll
+++ b/llvm/test/MC/WebAssembly/debug-info.ll
@@ -1,4 +1,4 @@
-; RUN: llc -filetype=obj %s -o - | llvm-readobj -r -S --symbols - | FileCheck %s
+; RUN: llc -filetype=obj %s -o - | llvm-readobj -S -r --symbols - | FileCheck %s
; CHECK: Format: WASM
; CHECK-NEXT:Arch: wasm32
diff --git a/llvm/test/MC/WebAssembly/debug-info64.ll b/llvm/test/MC/WebAssembly/debug-info64.ll
index c35938ea767e5..a8d9a24a1f2b6 100644
--- a/llvm/test/MC/WebAssembly/debug-info64.ll
+++ b/llvm/test/MC/WebAssembly/debug-info64.ll
@@ -1,4 +1,4 @@
-; RUN: llc -filetype=obj %s -o - | llvm-readobj -r -S --symbols - | FileCheck %s
+; RUN: llc -filetype=obj %s -o - | llvm-readobj -S -r --symbols - | FileCheck %s
; CHECK: Format: WASM
; CHECK-NEXT: Arch: wasm64
diff --git a/llvm/test/MC/WebAssembly/func-address.ll b/llvm/test/MC/WebAssembly/func-address.ll
index 281325e6b9fd9..7ec1e38debf0a 100644
--- a/llvm/test/MC/WebAssembly/func-address.ll
+++ b/llvm/test/MC/WebAssembly/func-address.ll
@@ -1,4 +1,4 @@
-; RUN: llc -O2 -filetype=obj %s -o - | llvm-readobj -r -S --expand-relocs - | FileCheck %s
+; RUN: llc -O2 -filetype=obj %s -o - | llvm-readobj -S -r --expand-relocs - | FileCheck %s
target triple = "wasm32-unknown-unknown"
diff --git a/llvm/test/lit.cfg.py b/llvm/test/lit.cfg.py
index 887be9abaa122..07ec33abd4ce1 100644
--- a/llvm/test/lit.cfg.py
+++ b/llvm/test/lit.cfg.py
@@ -253,7 +253,7 @@ def have_cxx_shared_library():
try:
readobj_cmd = subprocess.Popen(
- [readobj_exe, '-needed-libs', readobj_exe], stdout=subprocess.PIPE)
+ [readobj_exe, '--needed-libs', readobj_exe], stdout=subprocess.PIPE)
except OSError:
print('could not exec llvm-readobj')
return False
diff --git a/llvm/test/tools/llvm-objcopy/ELF/compress-debug-sections-groups.test b/llvm/test/tools/llvm-objcopy/ELF/compress-debug-sections-groups.test
index e99cc0d7ee32d..4eeef6e6d30fe 100644
--- a/llvm/test/tools/llvm-objcopy/ELF/compress-debug-sections-groups.test
+++ b/llvm/test/tools/llvm-objcopy/ELF/compress-debug-sections-groups.test
@@ -7,22 +7,22 @@
## Check compression of debug sections.
# RUN: llvm-objcopy --compress-debug-sections %t.o %t-compressed.o
-# RUN: llvm-readobj -S --elf-section-groups %t-compressed.o | \
+# RUN: llvm-readobj -S --section-groups %t-compressed.o | \
# RUN: FileCheck %s --check-prefixes=CHECK,COMPRESS
## Check zlib-gnu compression of debug sections.
# RUN: llvm-objcopy --compress-debug-sections=zlib-gnu %t.o %t-compressed-gnu.o
-# RUN: llvm-readobj -S --elf-section-groups %t-compressed-gnu.o | \
+# RUN: llvm-readobj -S --section-groups %t-compressed-gnu.o | \
# RUN: FileCheck %s --check-prefixes=CHECK,COMPRESSZLIB
## Check decompression of debug sections.
# RUN: llvm-objcopy --decompress-debug-sections %t-compressed.o %t-decompressed.o
-# RUN: llvm-readobj --elf-section-groups %t-decompressed.o | \
+# RUN: llvm-readobj --section-groups %t-decompressed.o | \
# RUN: FileCheck %s --check-prefixes=CHECK,DECOMPRESS
## Check decompression of zlib-gnu debug sections.
# RUN: llvm-objcopy --decompress-debug-sections %t-compressed-gnu.o %t-decompressed-gnu.o
-# RUN: llvm-readobj --elf-section-groups %t-decompressed-gnu.o | \
+# RUN: llvm-readobj --section-groups %t-decompressed-gnu.o | \
# RUN: FileCheck %s --check-prefixes=CHECK,DECOMPRESS
# COMPRESSZLIB: Name: .zdebug_in_group
diff --git a/llvm/test/tools/llvm-objcopy/ELF/group-big-endian.test b/llvm/test/tools/llvm-objcopy/ELF/group-big-endian.test
index b8932736acc52..f33af0b211ffc 100644
--- a/llvm/test/tools/llvm-objcopy/ELF/group-big-endian.test
+++ b/llvm/test/tools/llvm-objcopy/ELF/group-big-endian.test
@@ -1,6 +1,6 @@
# RUN: yaml2obj %s -o %t
# RUN: llvm-objcopy --remove-section=.text.bar %t %t2
-# RUN: llvm-readobj --elf-section-groups %t2 | FileCheck %s
+# RUN: llvm-readobj --section-groups %t2 | FileCheck %s
# In this test the section .text.bar is getting removed, as a result,
# the indices of the sections which go after .text.bar will change,
diff --git a/llvm/test/tools/llvm-objcopy/ELF/group-reorder.test b/llvm/test/tools/llvm-objcopy/ELF/group-reorder.test
index 6e0d4b9518cc8..ce163da90c105 100644
--- a/llvm/test/tools/llvm-objcopy/ELF/group-reorder.test
+++ b/llvm/test/tools/llvm-objcopy/ELF/group-reorder.test
@@ -1,7 +1,7 @@
# RUN: yaml2obj %s -o %t.o
# RUN: llvm-objcopy %t.o %t.2.o
-# RUN: llvm-readelf --elf-section-groups --sections %t.o | FileCheck %s --check-prefix=IN
-# RUN: llvm-readelf --elf-section-groups --sections %t.2.o | FileCheck %s --check-prefix=OUT
+# RUN: llvm-readelf --section-groups --sections %t.o | FileCheck %s --check-prefix=IN
+# RUN: llvm-readelf --section-groups --sections %t.2.o | FileCheck %s --check-prefix=OUT
# In this test, .group gets moved to the beginning. Run readelf -gS on input as
# well as output to make sure it really moved, as well as to verify that we
diff --git a/llvm/test/tools/llvm-objcopy/ELF/group-unchanged.test b/llvm/test/tools/llvm-objcopy/ELF/group-unchanged.test
index e7d9664fe2f39..c82423c9b63ad 100644
--- a/llvm/test/tools/llvm-objcopy/ELF/group-unchanged.test
+++ b/llvm/test/tools/llvm-objcopy/ELF/group-unchanged.test
@@ -1,6 +1,6 @@
# RUN: yaml2obj %s -o %t
# RUN: llvm-objcopy --remove-section=.text.bar %t %t2
-# RUN: llvm-readobj --elf-section-groups %t2 | FileCheck %s
+# RUN: llvm-readobj --section-groups %t2 | FileCheck %s
# In this test the section .text.bar is getting removed, since this section
# goes after all the sections comprising a group, the content of the
diff --git a/llvm/test/tools/llvm-objcopy/ELF/group.test b/llvm/test/tools/llvm-objcopy/ELF/group.test
index 49032e6e5eb40..806653d644404 100644
--- a/llvm/test/tools/llvm-objcopy/ELF/group.test
+++ b/llvm/test/tools/llvm-objcopy/ELF/group.test
@@ -1,6 +1,6 @@
# RUN: yaml2obj %s -o %t
# RUN: llvm-objcopy --remove-section=.text.bar %t %t1
-# RUN: llvm-readobj --elf-section-groups %t1 | FileCheck %s
+# RUN: llvm-readobj --section-groups %t1 | FileCheck %s
# In this test the section .text.bar is getting removed, as a result,
# the indices of the sections which go after .text.bar will change,
diff --git a/llvm/test/tools/llvm-objcopy/ELF/strip-dwo-groups.test b/llvm/test/tools/llvm-objcopy/ELF/strip-dwo-groups.test
index e3bdc357ca0b9..77727ca942220 100644
--- a/llvm/test/tools/llvm-objcopy/ELF/strip-dwo-groups.test
+++ b/llvm/test/tools/llvm-objcopy/ELF/strip-dwo-groups.test
@@ -1,6 +1,6 @@
# RUN: yaml2obj %s -o %t
# RUN: llvm-objcopy --strip-dwo %t
-# RUN: llvm-readobj --symbols -S --elf-section-groups %t | FileCheck %s
+# RUN: llvm-readobj --symbols -S --section-groups %t | FileCheck %s
## `llvm-objcopy --strip-dwo` strips out dwo sections, as a result, the index of
## the symbol table, the indices of the symbols and the indices of the sections
diff --git a/llvm/test/tools/llvm-objcopy/MachO/remove-swift-symbols.test b/llvm/test/tools/llvm-objcopy/MachO/remove-swift-symbols.test
index 1d55648a540bd..b2e977e7f4c35 100644
--- a/llvm/test/tools/llvm-objcopy/MachO/remove-swift-symbols.test
+++ b/llvm/test/tools/llvm-objcopy/MachO/remove-swift-symbols.test
@@ -3,19 +3,19 @@
# RUN: -D SECTION_NAME=__objc_imageinfo -D SECTION_SIZE=8 \
# RUN: -D SECTION_CONTENT=0000000040070105 %s -o %t1
# RUN: llvm-strip -x -T %t1
-# RUN: llvm-readobj -symbols %t1 | FileCheck --check-prefix=NO-SWIFT-SYMBOLS %s
+# RUN: llvm-readobj -s %t1 | FileCheck --check-prefix=NO-SWIFT-SYMBOLS %s
# RUN: yaml2obj -D FLAGS=0x00200085 -D SEGMENT_NAME=__DATA_CONST \
# RUN: -D SECTION_NAME=__objc_imageinfo -D SECTION_SIZE=8 \
# RUN: -D SECTION_CONTENT=0000000040070105 %s -o %t2
# RUN: llvm-strip -x -T %t2
-# RUN: llvm-readobj -symbols %t2 | FileCheck --check-prefix=NO-SWIFT-SYMBOLS %s
+# RUN: llvm-readobj -s %t2 | FileCheck --check-prefix=NO-SWIFT-SYMBOLS %s
# RUN: yaml2obj -D FLAGS=0x00200085 -D SEGMENT_NAME=__DATA_DIRTY \
# RUN: -D SECTION_NAME=__objc_imageinfo -D SECTION_SIZE=8 \
# RUN: -D SECTION_CONTENT=0000000040070105 %s -o %t3
# RUN: llvm-strip -x -T %t3
-# RUN: llvm-readobj -symbols %t3 | FileCheck --check-prefix=NO-SWIFT-SYMBOLS %s
+# RUN: llvm-readobj -s %t3 | FileCheck --check-prefix=NO-SWIFT-SYMBOLS %s
# NO-SWIFT-SYMBOLS: Symbols [
# NO-SWIFT-SYMBOLS-NEXT: Symbol {
@@ -37,13 +37,13 @@
# RUN: -D SECTION_NAME=__not_objc_imageinfo -D SECTION_SIZE=8 \
# RUN: -D SECTION_CONTENT=0000000040070105 %s -o %t4
# RUN: llvm-strip -x -T %t4
-# RUN: llvm-readobj -symbols %t4 | FileCheck --check-prefix=SWIFT-SYMBOLS %s
+# RUN: llvm-readobj -s %t4 | FileCheck --check-prefix=SWIFT-SYMBOLS %s
# RUN: yaml2obj -D FLAGS=0x00200085 -D SEGMENT_NAME=__NOT_DATA \
# RUN: -D SECTION_NAME=__objc_imageinfo -D SECTION_SIZE=8 \
# RUN: -D SECTION_CONTENT=0000000040070105 %s -o %t5
# RUN: llvm-strip -x -T %t5
-# RUN: llvm-readobj -symbols %t5 | FileCheck --check-prefix=SWIFT-SYMBOLS %s
+# RUN: llvm-readobj -s %t5 | FileCheck --check-prefix=SWIFT-SYMBOLS %s
## Verify that -T does not remove (public) Swift symbols when swift_version is zero.
@@ -51,7 +51,7 @@
# RUN: -D SECTION_NAME=__objc_imageinfo -D SECTION_SIZE=8 \
# RUN: -D SECTION_CONTENT=0000000000000000 %s -o %t6
# RUN: llvm-strip -x -T %t6
-# RUN: llvm-readobj -symbols %t6 | FileCheck --check-prefix=SWIFT-SYMBOLS %s
+# RUN: llvm-readobj -s %t6 | FileCheck --check-prefix=SWIFT-SYMBOLS %s
## Verify that -T does not remove (public) Swift symbols when the binary
## contains invalid (too small) __objc_imageinfo.
@@ -60,7 +60,7 @@
# RUN: -D SECTION_NAME=__objc_imageinfo -D SECTION_SIZE=4 \
# RUN: -D SECTION_CONTENT=00000000 %s -o %t7
# RUN: llvm-strip -x -T %t7
-# RUN: llvm-readobj -symbols %t7 | FileCheck --check-prefix=SWIFT-SYMBOLS %s
+# RUN: llvm-readobj -s %t7 | FileCheck --check-prefix=SWIFT-SYMBOLS %s
## Verify that -T does not remove (public) Swift symbols
## when the flag MH_DYLDLINK is not set.
@@ -69,7 +69,7 @@
# RUN: -D SECTION_NAME=__objc_imageinfo -D SECTION_SIZE=8 \
# RUN: -D SECTION_CONTENT=0000000040070105 %s -o %t8
# RUN: llvm-strip -x -T %t8
-# RUN: llvm-readobj -symbols %t8 | FileCheck --check-prefix=SWIFT-SYMBOLS %s
+# RUN: llvm-readobj -s %t8 | FileCheck --check-prefix=SWIFT-SYMBOLS %s
# SWIFT-SYMBOLS: Symbols [
# SWIFT-SYMBOLS-NEXT: Symbol {
diff --git a/llvm/test/tools/llvm-readobj/ELF/demangle.test b/llvm/test/tools/llvm-readobj/ELF/demangle.test
index c0786a10259de..e348e594fffa4 100644
--- a/llvm/test/tools/llvm-readobj/ELF/demangle.test
+++ b/llvm/test/tools/llvm-readobj/ELF/demangle.test
@@ -5,20 +5,20 @@
## Check LLVM output style.
# RUN: llvm-readobj --symbols --relocations --dyn-symbols --dyn-relocations \
-# RUN: --elf-section-groups --cg-profile --addrsig \
+# RUN: --section-groups --cg-profile --addrsig \
# RUN: --demangle %t.so > %t.llvm.long
# RUN: llvm-readobj --symbols --relocations --dyn-symbols --dyn-relocations \
-# RUN: --elf-section-groups --cg-profile --addrsig \
+# RUN: --section-groups --cg-profile --addrsig \
# RUN: -C %t.so > %t.llvm.short
# RUN: FileCheck %s --input-file %t.llvm.long --check-prefixes=LLVM-COMMON,LLVM-DEMANGLE
# RUN:
diff %t.llvm.long %t.llvm.short
## Check that default is no demangling.
# RUN: llvm-readobj --symbols --relocations --dyn-symbols --dyn-relocations \
-# RUN: --elf-section-groups --cg-profile --addrsig \
+# RUN: --section-groups --cg-profile --addrsig \
# RUN: %t.so > %t.llvm.default
# RUN: llvm-readobj --symbols --relocations --dyn-symbols --dyn-relocations \
-# RUN: --elf-section-groups --cg-profile --addrsig \
+# RUN: --section-groups --cg-profile --addrsig \
# RUN: --no-demangle %t.so > %t.llvm.nodemangle
# RUN: FileCheck %s --input-file %t.llvm.default --check-prefixes=LLVM-COMMON,LLVM-MANGLED
# RUN:
diff %t.llvm.default %t.llvm.nodemangle
@@ -68,17 +68,17 @@
## Check GNU output style.
# RUN: llvm-readelf --symbols --relocations --dyn-symbols --dyn-relocations \
-# RUN: --elf-section-groups --addrsig --demangle %t.so > %t.gnu.long
+# RUN: --section-groups --addrsig --demangle %t.so > %t.gnu.long
# RUN: llvm-readelf --symbols --relocations --dyn-symbols --dyn-relocations \
-# RUN: --elf-section-groups --addrsig -C %t.so > %t.gnu.short
+# RUN: --section-groups --addrsig -C %t.so > %t.gnu.short
# RUN: FileCheck %s --input-file %t.gnu.long --check-prefixes=GNU-COMMON,GNU-DEMANGLE
# RUN:
diff %t.gnu.long %t.gnu.short
## Check that default is no demangling.
# RUN: llvm-readelf --symbols --relocations --dyn-symbols --dyn-relocations \
-# RUN: --elf-section-groups --addrsig %t.so > %t.gnu.default
+# RUN: --section-groups --addrsig %t.so > %t.gnu.default
# RUN: llvm-readelf --symbols --relocations --dyn-symbols --dyn-relocations \
-# RUN: --elf-section-groups --addrsig --no-demangle %t.so > %t.gnu.nodemangle
+# RUN: --section-groups --addrsig --no-demangle %t.so > %t.gnu.nodemangle
# RUN: FileCheck %s --input-file %t.gnu.default --check-prefixes=GNU-COMMON,GNU-MANGLED
# RUN:
diff %t.gnu.default %t.gnu.nodemangle
diff --git a/llvm/test/tools/llvm-readobj/ELF/groups.test b/llvm/test/tools/llvm-readobj/ELF/groups.test
index f0ddeb55be3d0..afa5fb05b91ea 100644
--- a/llvm/test/tools/llvm-readobj/ELF/groups.test
+++ b/llvm/test/tools/llvm-readobj/ELF/groups.test
@@ -3,6 +3,7 @@
# RUN: yaml2obj %s -o %t.o
# RUN: llvm-readobj -g %t.o | FileCheck %s
+# RUN: llvm-readobj --elf-section-groups %t.o | FileCheck %s
# RUN: llvm-readelf -g %t.o | FileCheck --check-prefix=GNU %s
# CHECK: Groups {
@@ -96,8 +97,8 @@ Symbols:
## in two group sections at the same time.
# RUN: yaml2obj %s -DMEMBER2=.text.foo -o %t.dup.o
-# RUN: llvm-readobj --elf-section-groups %t.dup.o 2>&1 | FileCheck %s -DFILE=%t.dup.o --check-prefix=DUP-LLVM
-# RUN: llvm-readelf --elf-section-groups %t.dup.o 2>&1 | FileCheck %s -DFILE=%t.dup.o --check-prefix=DUP-GNU
+# RUN: llvm-readobj --section-groups %t.dup.o 2>&1 | FileCheck %s -DFILE=%t.dup.o --check-prefix=DUP-LLVM
+# RUN: llvm-readelf --section-groups %t.dup.o 2>&1 | FileCheck %s -DFILE=%t.dup.o --check-prefix=DUP-GNU
# DUP-LLVM: Group {
# DUP-LLVM-NEXT: Name: .group
@@ -142,9 +143,9 @@ Symbols:
## Check we report a warning in this case. Check we don't print the same warning message twice.
# RUN: yaml2obj %s -DSYMTABLINK=0xFF -o %t.symtab.o
-# RUN: llvm-readobj --elf-section-groups %t.symtab.o 2>&1 | \
+# RUN: llvm-readobj --section-groups %t.symtab.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.symtab.o %s --check-prefix=SYMTAB-LLVM --implicit-check-not=warning:
-# RUN: llvm-readelf --elf-section-groups %t.symtab.o 2>&1 | \
+# RUN: llvm-readelf --section-groups %t.symtab.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.symtab.o %s --check-prefix=SYMTAB-GNU --implicit-check-not=warning:
# SYMTAB-LLVM: Groups {
@@ -195,9 +196,9 @@ Symbols:
## when we are unable to read a signature symbol.
# RUN: yaml2obj %s -DSYMTAB1=0xFF -DSYMTAB2=0x1 -o %t.symtab2.o
-# RUN: llvm-readobj --elf-section-groups %t.symtab2.o 2>&1 | \
+# RUN: llvm-readobj --section-groups %t.symtab2.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.symtab2.o %s --check-prefix=SIGNATURE-LLVM --implicit-check-not=warning:
-# RUN: llvm-readelf --elf-section-groups %t.symtab2.o 2>&1 | \
+# RUN: llvm-readelf --section-groups %t.symtab2.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.symtab2.o %s --check-prefix=SIGNATURE-GNU --implicit-check-not=warning:
# SIGNATURE: Groups {
@@ -246,9 +247,9 @@ Symbols:
## In both cases we are unable to read the section group flag and dump it as 0.
# RUN: yaml2obj %s -DSECSIZE1=0x0 -DSECSIZE2=0x1 -o %t.secsize.o
-# RUN: llvm-readobj --elf-section-groups %t.secsize.o 2>&1 | \
+# RUN: llvm-readobj --section-groups %t.secsize.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.secsize.o %s --check-prefix=CONTENT-LLVM --implicit-check-not=warning:
-# RUN: llvm-readelf --elf-section-groups %t.secsize.o 2>&1 | \
+# RUN: llvm-readelf --section-groups %t.secsize.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.secsize.o %s --check-prefix=CONTENT-GNU --implicit-check-not=warning:
# CONTENT-LLVM: Groups {
@@ -288,9 +289,9 @@ Symbols:
## Check that we emit a warning when we are unable to read the group section name or the name of a member.
# RUN: yaml2obj %s -DGROUP1SHNAME=0xAAAA -DTEXTBARSHNAME=0xBBBB -o %t.name.o
-# RUN: llvm-readobj --elf-section-groups %t.name.o 2>&1 | \
+# RUN: llvm-readobj --section-groups %t.name.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.name.o %s --check-prefix=NAME-LLVM --implicit-check-not=warning:
-# RUN: llvm-readelf --elf-section-groups %t.name.o 2>&1 | \
+# RUN: llvm-readelf --section-groups %t.name.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.name.o %s --check-prefix=NAME-GNU --implicit-check-not=warning:
# NAME-LLVM: Groups {
@@ -338,9 +339,9 @@ Symbols:
## Check we report a warning then the section index of a section group member is invalid.
# RUN: yaml2obj %s -DMEMBER1=0xEE -DMEMBER2=0xFF -o %t.member.index.o
-# RUN: llvm-readobj --elf-section-groups %t.member.index.o 2>&1 | \
+# RUN: llvm-readobj --section-groups %t.member.index.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.member.index.o %s --check-prefix=MEMBER-LLVM --implicit-check-not=warning:
-# RUN: llvm-readelf --elf-section-groups %t.member.index.o 2>&1 | \
+# RUN: llvm-readelf --section-groups %t.member.index.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.member.index.o %s --check-prefix=MEMBER-GNU --implicit-check-not=warning:
# MEMBER-LLVM: Groups {
@@ -390,9 +391,9 @@ Symbols:
## We set the content of the string table to '0061626300' ('\0abc\0') to fixup the size of the string table.
## This makes it easier to test the boundary conditions.
# RUN: yaml2obj %s -DSTRTABCONTENT="0061626300" -DSYM1STNAME=4 -DSYM2STNAME=5 -o %t.signame.o
-# RUN: llvm-readobj --elf-section-groups %t.signame.o 2>&1 | \
+# RUN: llvm-readobj --section-groups %t.signame.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.signame.o %s --check-prefixes=SIGNAME1-WARN,SIGNAME1-LLVM --implicit-check-not=warning:
-# RUN: llvm-readelf --elf-section-groups %t.signame.o 2>&1 | \
+# RUN: llvm-readelf --section-groups %t.signame.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.signame.o %s --check-prefixes=SIGNAME1-WARN,SIGNAME1-GNU --implicit-check-not=warning:
# SIGNAME1-WARN: warning: '[[FILE]]': unable to get the name of the symbol with index 2: st_name (0x5) is past the end of the string table of size 0x5
@@ -406,9 +407,9 @@ Symbols:
## Check we report a warning when the string table that contains the signature symbol name is not null-terminated.
# RUN: yaml2obj %s -DSTRTABCONTENT="0061626361" -DSYM1STNAME=4 -DSYM2STNAME=5 -o %t.signame2.o
-# RUN: llvm-readobj --elf-section-groups %t.signame2.o 2>&1 | \
+# RUN: llvm-readobj --section-groups %t.signame2.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.signame2.o %s --check-prefixes=SIGNAME2-WARN,SIGNAME2-LLVM --implicit-check-not=warning:
-# RUN: llvm-readelf --elf-section-groups %t.signame2.o 2>&1 | \
+# RUN: llvm-readelf --section-groups %t.signame2.o 2>&1 | \
# RUN: FileCheck -DFILE=%t.signame2.o %s --check-prefixes=SIGNAME2-WARN,SIGNAME2-GNU --implicit-check-not=warning:
# SIGNAME2-WARN: warning: '[[FILE]]': unable to get the string table for SHT_SYMTAB section with index 7: SHT_STRTAB string table section [index 8] is non-null terminated
diff --git a/llvm/test/tools/llvm-readobj/ELF/packed-relocs.test b/llvm/test/tools/llvm-readobj/ELF/packed-relocs.test
index 43ba16856a78f..d209a00fdd560 100644
--- a/llvm/test/tools/llvm-readobj/ELF/packed-relocs.test
+++ b/llvm/test/tools/llvm-readobj/ELF/packed-relocs.test
@@ -174,7 +174,7 @@ Symbols:
# LLVM3-NEXT: 0x1218 R_X86_64_64 sym2 0x8
# LLVM3-NEXT: }
-# RUN: yaml2obj --docnum=3 %s | llvm-readelf -relocations - | FileCheck --check-prefix=GNU3 %s
+# RUN: yaml2obj --docnum=3 %s | llvm-readelf -r - | FileCheck --check-prefix=GNU3 %s
# GNU3: Relocation section '.rela.dyn' at offset 0x40 contains 6 entries:
# GNU3: 0000000000001100 0000000000000008 R_X86_64_RELATIVE 0
# GNU3-NEXT: 0000000000001180 0000000000000008 R_X86_64_RELATIVE 8
diff --git a/llvm/test/tools/obj2yaml/ELF/program-headers.yaml b/llvm/test/tools/obj2yaml/ELF/program-headers.yaml
index d3907bc7431c1..e9c12a21a0bc6 100644
--- a/llvm/test/tools/obj2yaml/ELF/program-headers.yaml
+++ b/llvm/test/tools/obj2yaml/ELF/program-headers.yaml
@@ -563,7 +563,7 @@ Sections:
## 2) '.bar1' ends at 0x79, which is the starting file offset of both '.empty.bar2'
## and '.empty.zed'. We should only include '.empty.bar2', because the VA of the
## '.empty.zed' section is outside the segment's virtual space.
-# RUN: llvm-readelf -sections %t7 | FileCheck %s --check-prefix=ZERO-SIZE-MAPPING
+# RUN: llvm-readelf -S %t7 | FileCheck %s --check-prefix=ZERO-SIZE-MAPPING
# ZERO-SIZE-MAPPING: Section Headers:
# ZERO-SIZE-MAPPING-NEXT: [Nr] Name Type Address Off Size
diff --git a/llvm/test/tools/yaml2obj/ELF/comdat-broken.yaml b/llvm/test/tools/yaml2obj/ELF/comdat-broken.yaml
index 28894e122e47a..e43f5ee353e77 100644
--- a/llvm/test/tools/yaml2obj/ELF/comdat-broken.yaml
+++ b/llvm/test/tools/yaml2obj/ELF/comdat-broken.yaml
@@ -1,5 +1,5 @@
# RUN: yaml2obj %s -o %t
-# RUN: llvm-readobj --sections --elf-section-groups %t | FileCheck %s
+# RUN: llvm-readobj --sections --section-groups %t | FileCheck %s
--- !ELF
FileHeader:
diff --git a/llvm/test/tools/yaml2obj/ELF/duplicate-section-names.yaml b/llvm/test/tools/yaml2obj/ELF/duplicate-section-names.yaml
index 30be4868b4901..1475093450df7 100644
--- a/llvm/test/tools/yaml2obj/ELF/duplicate-section-names.yaml
+++ b/llvm/test/tools/yaml2obj/ELF/duplicate-section-names.yaml
@@ -2,7 +2,7 @@
## containing sections with duplicate names (but
diff erent name suffixes).
# RUN: yaml2obj --docnum=1 %s -o %t1
-# RUN: llvm-readelf -sections %t1 | FileCheck %s --check-prefix=CASE1
+# RUN: llvm-readelf -S %t1 | FileCheck %s --check-prefix=CASE1
# CASE1: [Nr] Name Type
# CASE1: [ 1] .foo1 PROGBITS
@@ -120,7 +120,7 @@ Symbols:
## reference sections and symbols with name suffixes.
# RUN: yaml2obj --docnum=5 %s -o %t5
-# RUN: llvm-readobj --elf-section-groups %t5 | FileCheck %s --check-prefix=CASE5
+# RUN: llvm-readobj --section-groups %t5 | FileCheck %s --check-prefix=CASE5
# CASE5: Groups {
# CASE5-NEXT: Group {
More information about the llvm-commits
mailing list