diff options
| author | Shiva Chen <shiva0217@gmail.com> | 2018-02-02 06:01:02 +0000 |
|---|---|---|
| committer | Shiva Chen <shiva0217@gmail.com> | 2018-02-02 06:01:02 +0000 |
| commit | 53489ada12e9e27a4863ad96adf7a64edf16eef3 (patch) | |
| tree | 496f699a1fafb80029f722cd252e744581f72b71 /llvm/test | |
| parent | 76c5ce518493669e23c73c02e616b4a5ca46ef63 (diff) | |
| download | bcm5719-llvm-53489ada12e9e27a4863ad96adf7a64edf16eef3.tar.gz bcm5719-llvm-53489ada12e9e27a4863ad96adf7a64edf16eef3.zip | |
[RISCV] Add ELFObjectFileBase::getRISCVFeatures let llvm-objdump could get RISCV target feature
llvm-objdump could get C feature by ELF::EF_RISCV_RVC e_flag,
so then we don't have to add -mattr=+c on the command line.
Differential Revision: https://reviews.llvm.org/D42629
llvm-svn: 324058
Diffstat (limited to 'llvm/test')
| -rw-r--r-- | llvm/test/MC/RISCV/cnop.s | 2 | ||||
| -rw-r--r-- | llvm/test/MC/RISCV/fixups-compressed.s | 2 | ||||
| -rw-r--r-- | llvm/test/MC/RISCV/rv32c-only-valid.s | 2 | ||||
| -rw-r--r-- | llvm/test/MC/RISCV/rv32c-valid.s | 4 | ||||
| -rw-r--r-- | llvm/test/MC/RISCV/rv32dc-valid.s | 2 | ||||
| -rw-r--r-- | llvm/test/MC/RISCV/rv32fc-valid.s | 2 | ||||
| -rw-r--r-- | llvm/test/MC/RISCV/rv64c-valid.s | 2 | ||||
| -rw-r--r-- | llvm/test/MC/RISCV/rv64dc-valid.s | 2 |
8 files changed, 9 insertions, 9 deletions
diff --git a/llvm/test/MC/RISCV/cnop.s b/llvm/test/MC/RISCV/cnop.s index 8d526263724..ff2acee8868 100644 --- a/llvm/test/MC/RISCV/cnop.s +++ b/llvm/test/MC/RISCV/cnop.s @@ -1,5 +1,5 @@ # RUN: llvm-mc -filetype=obj -triple riscv32 -mattr=+c < %s \ -# RUN: | llvm-objdump -mattr=+c -d - | FileCheck -check-prefix=CHECK-INST %s +# RUN: | llvm-objdump -d - | FileCheck -check-prefix=CHECK-INST %s # alpha and main are 8 byte alignment # but the alpha function's size is 6 diff --git a/llvm/test/MC/RISCV/fixups-compressed.s b/llvm/test/MC/RISCV/fixups-compressed.s index bf6cbfc3556..65e4c773eca 100644 --- a/llvm/test/MC/RISCV/fixups-compressed.s +++ b/llvm/test/MC/RISCV/fixups-compressed.s @@ -1,7 +1,7 @@ # RUN: llvm-mc %s -triple riscv32 -mattr=+c -show-encoding \ # RUN: | FileCheck -check-prefix=CHECK-FIXUP %s # RUN: llvm-mc -triple riscv32 -filetype=obj -mattr=+c < %s \ -# RUN: | llvm-objdump -mattr=+c -d - | FileCheck -check-prefix=CHECK-INSTR %s +# RUN: | llvm-objdump -d - | FileCheck -check-prefix=CHECK-INSTR %s .LBB0_2: # CHECK-FIXUP: fixup A - offset: 0, value: .LBB0_2, kind: fixup_riscv_rvc_jump diff --git a/llvm/test/MC/RISCV/rv32c-only-valid.s b/llvm/test/MC/RISCV/rv32c-only-valid.s index dc985fc1a5e..9767ebc6161 100644 --- a/llvm/test/MC/RISCV/rv32c-only-valid.s +++ b/llvm/test/MC/RISCV/rv32c-only-valid.s @@ -1,7 +1,7 @@ # RUN: llvm-mc -triple=riscv32 -mattr=+c -riscv-no-aliases -show-encoding < %s \ # RUN: | FileCheck -check-prefixes=CHECK,CHECK-INST %s # RUN: llvm-mc -filetype=obj -triple riscv32 -mattr=+c -riscv-no-aliases < %s \ -# RUN: | llvm-objdump -mattr=+c -d - | FileCheck -check-prefix=CHECK-INST %s +# RUN: | llvm-objdump -d - | FileCheck -check-prefix=CHECK-INST %s # RUN: not llvm-mc -triple riscv32 \ # RUN: -riscv-no-aliases -show-encoding < %s 2>&1 \ # RUN: | FileCheck -check-prefixes=CHECK-NO-EXT %s diff --git a/llvm/test/MC/RISCV/rv32c-valid.s b/llvm/test/MC/RISCV/rv32c-valid.s index a58959dd398..029dbdeaaae 100644 --- a/llvm/test/MC/RISCV/rv32c-valid.s +++ b/llvm/test/MC/RISCV/rv32c-valid.s @@ -3,10 +3,10 @@ # RUN: llvm-mc -triple=riscv64 -mattr=+c -riscv-no-aliases -show-encoding < %s \ # RUN: | FileCheck -check-prefixes=CHECK,CHECK-INST %s # RUN: llvm-mc -filetype=obj -triple riscv32 -mattr=+c < %s \ -# RUN: | llvm-objdump -mattr=+c -riscv-no-aliases -d - \ +# RUN: | llvm-objdump -riscv-no-aliases -d - \ # RUN: | FileCheck -check-prefix=CHECK-INST %s # RUN: llvm-mc -filetype=obj -triple riscv64 -mattr=+c < %s \ -# RUN: | llvm-objdump -mattr=+c -riscv-no-aliases -d - \ +# RUN: | llvm-objdump -riscv-no-aliases -d - \ # RUN: | FileCheck -check-prefix=CHECK-INST %s # TODO: more exhaustive testing of immediate encoding. diff --git a/llvm/test/MC/RISCV/rv32dc-valid.s b/llvm/test/MC/RISCV/rv32dc-valid.s index 507b39170ec..764bcbd2fb1 100644 --- a/llvm/test/MC/RISCV/rv32dc-valid.s +++ b/llvm/test/MC/RISCV/rv32dc-valid.s @@ -1,7 +1,7 @@ # RUN: llvm-mc %s -triple=riscv32 -mattr=+c,+d -riscv-no-aliases -show-encoding \ # RUN: | FileCheck -check-prefixes=CHECK,CHECK-INST %s # RUN: llvm-mc -filetype=obj -triple=riscv32 -mattr=+c,+d < %s \ -# RUN: | llvm-objdump -mattr=+c,+d -riscv-no-aliases -d - \ +# RUN: | llvm-objdump -mattr=+d -riscv-no-aliases -d - \ # RUN: | FileCheck -check-prefix=CHECK-INST %s # RUN: not llvm-mc -triple riscv32 -mattr=+c\ # RUN: -riscv-no-aliases -show-encoding < %s 2>&1 \ diff --git a/llvm/test/MC/RISCV/rv32fc-valid.s b/llvm/test/MC/RISCV/rv32fc-valid.s index b07bef9d87c..87d86c13799 100644 --- a/llvm/test/MC/RISCV/rv32fc-valid.s +++ b/llvm/test/MC/RISCV/rv32fc-valid.s @@ -1,7 +1,7 @@ # RUN: llvm-mc %s -triple=riscv32 -mattr=+c,+f -riscv-no-aliases -show-encoding \ # RUN: | FileCheck -check-prefixes=CHECK,CHECK-INST %s # RUN: llvm-mc -filetype=obj -triple=riscv32 -mattr=+c,+f < %s \ -# RUN: | llvm-objdump -mattr=+c,+f -riscv-no-aliases -d - \ +# RUN: | llvm-objdump -mattr=+f -riscv-no-aliases -d - \ # RUN: | FileCheck -check-prefix=CHECK-INST %s # RUN: not llvm-mc -triple riscv32 -mattr=+c \ # RUN: -riscv-no-aliases -show-encoding < %s 2>&1 \ diff --git a/llvm/test/MC/RISCV/rv64c-valid.s b/llvm/test/MC/RISCV/rv64c-valid.s index 5e7b901ad0e..c436fe5414c 100644 --- a/llvm/test/MC/RISCV/rv64c-valid.s +++ b/llvm/test/MC/RISCV/rv64c-valid.s @@ -1,7 +1,7 @@ # RUN: llvm-mc -triple=riscv64 -mattr=+c -riscv-no-aliases -show-encoding < %s \ # RUN: | FileCheck -check-prefixes=CHECK,CHECK-INST %s # RUN: llvm-mc -filetype=obj -triple riscv64 -mattr=+c < %s \ -# RUN: | llvm-objdump -mattr=+c -riscv-no-aliases -d - \ +# RUN: | llvm-objdump -riscv-no-aliases -d - \ # RUN: | FileCheck -check-prefix=CHECK-INST %s # RUN: not llvm-mc -triple riscv64 \ # RUN: -riscv-no-aliases -show-encoding < %s 2>&1 \ diff --git a/llvm/test/MC/RISCV/rv64dc-valid.s b/llvm/test/MC/RISCV/rv64dc-valid.s index 43d39df0dcc..c9ef4cbf289 100644 --- a/llvm/test/MC/RISCV/rv64dc-valid.s +++ b/llvm/test/MC/RISCV/rv64dc-valid.s @@ -1,7 +1,7 @@ # RUN: llvm-mc %s -triple=riscv64 -mattr=+c,+d -riscv-no-aliases -show-encoding \ # RUN: | FileCheck -check-prefixes=CHECK,CHECK-INST %s # RUN: llvm-mc -filetype=obj -triple=riscv64 -mattr=+c,+d < %s \ -# RUN: | llvm-objdump -mattr=+c,+d -riscv-no-aliases -d - \ +# RUN: | llvm-objdump -mattr=+d -riscv-no-aliases -d - \ # RUN: | FileCheck -check-prefix=CHECK-INST %s # RUN: not llvm-mc -triple riscv64 -mattr=+c\ # RUN: -riscv-no-aliases -show-encoding < %s 2>&1 \ |

