From eb75b8f8f7ad508890f78e87aebe949dc1989ef5 Mon Sep 17 00:00:00 2001 From: Fangrui Song Date: Tue, 26 Jun 2018 16:58:19 +0000 Subject: [PATCH] [ELF] Move `# REQUIRES:` line to the top llvm-svn: 335625 --- lld/test/ELF/aarch64-condb-reloc.s | 2 +- lld/test/ELF/aarch64-relocs.s | 2 +- lld/test/ELF/aarch64-tls-gdle.s | 2 +- lld/test/ELF/aarch64-tls-ie.s | 2 +- lld/test/ELF/aarch64-tls-iele.s | 2 +- lld/test/ELF/aarch64-tls-le.s | 2 +- lld/test/ELF/aarch64-tstbr14-reloc.s | 2 +- lld/test/ELF/amdgpu-elf-flags-err.s | 3 +-- lld/test/ELF/amdgpu-elf-flags.s | 3 +-- lld/test/ELF/amdgpu-globals.s | 3 +-- lld/test/ELF/amdgpu-kernels.s | 3 +-- lld/test/ELF/amdgpu-relocs.s | 3 +-- lld/test/ELF/archive.s | 2 +- lld/test/ELF/basic-aarch64.s | 2 +- lld/test/ELF/basic-freebsd.s | 2 +- lld/test/ELF/basic-mips.s | 3 +-- lld/test/ELF/basic-ppc.s | 2 +- lld/test/ELF/basic-ppc64.s | 2 +- lld/test/ELF/basic-sparcv9.s | 2 +- lld/test/ELF/basic32.s | 2 +- lld/test/ELF/basic64be.s | 2 +- lld/test/ELF/cgprofile-bad-clusters.s | 3 +-- lld/test/ELF/corrupted-version-reference.s | 2 +- lld/test/ELF/dynstr-no-rosegment.s | 2 +- lld/test/ELF/eh-frame-hdr-abs-fde.s | 3 +-- lld/test/ELF/emulation.s | 3 +-- lld/test/ELF/gc-sections-metadata-startstop.s | 2 +- lld/test/ELF/mips-26-mask.s | 3 +-- lld/test/ELF/mips-26-n32-n64.s | 3 +-- lld/test/ELF/mips-26.s | 3 +-- lld/test/ELF/mips-32.s | 3 +-- lld/test/ELF/mips-64-disp.s | 3 +-- lld/test/ELF/mips-64-got.s | 3 +-- lld/test/ELF/mips-64-gprel-so.s | 3 +-- lld/test/ELF/mips-64-rels.s | 3 +-- lld/test/ELF/mips-64.s | 3 +-- lld/test/ELF/mips-call-hilo.s | 3 +-- lld/test/ELF/mips-call16.s | 3 +-- lld/test/ELF/mips-dynamic.s | 3 +-- lld/test/ELF/mips-dynsym-sort.s | 3 +-- lld/test/ELF/mips-elf-abi.s | 3 +-- lld/test/ELF/mips-elf-flags-err.s | 3 +-- lld/test/ELF/mips-elf-flags.s | 3 +-- lld/test/ELF/mips-gnu-hash.s | 3 +-- lld/test/ELF/mips-got-extsym.s | 3 +-- lld/test/ELF/mips-got-hilo.s | 3 +-- lld/test/ELF/mips-got-page-script.s | 3 +-- lld/test/ELF/mips-got-page.s | 3 +-- lld/test/ELF/mips-got-redundant.s | 3 +-- lld/test/ELF/mips-got-relocs.s | 3 +-- lld/test/ELF/mips-got-script.s | 3 +-- lld/test/ELF/mips-got-string.s | 3 +-- lld/test/ELF/mips-got-weak.s | 3 +-- lld/test/ELF/mips-got16-relocatable.s | 3 +-- lld/test/ELF/mips-got16.s | 3 +-- lld/test/ELF/mips-gp-disp-ver.s | 3 +-- lld/test/ELF/mips-gp-disp.s | 3 +-- lld/test/ELF/mips-gp-ext.s | 3 +-- lld/test/ELF/mips-gp-local.s | 3 +-- lld/test/ELF/mips-gp-lowest.s | 3 +-- lld/test/ELF/mips-gprel-sec.s | 3 +-- lld/test/ELF/mips-gprel32-relocs-gp0.s | 3 +-- lld/test/ELF/mips-gprel32-relocs.s | 3 +-- lld/test/ELF/mips-higher-highest.s | 3 +-- lld/test/ELF/mips-hilo-gp-disp.s | 3 +-- lld/test/ELF/mips-hilo-hi-only.s | 3 +-- lld/test/ELF/mips-hilo.s | 3 +-- lld/test/ELF/mips-lo16-not-relative.s | 3 +-- lld/test/ELF/mips-merge-abiflags.s | 2 +- lld/test/ELF/mips-mgot.s | 3 +-- lld/test/ELF/mips-micro-got.s | 3 +-- lld/test/ELF/mips-micro-got64.s | 3 +-- lld/test/ELF/mips-micro-jal.s | 3 +-- lld/test/ELF/mips-micro-plt.s | 3 +-- lld/test/ELF/mips-micro-relocs.s | 3 +-- lld/test/ELF/mips-micro-thunks.s | 3 +-- lld/test/ELF/mips-n32-emul.s | 3 +-- lld/test/ELF/mips-n32-rels.s | 3 +-- lld/test/ELF/mips-nonalloc.s | 3 +-- lld/test/ELF/mips-options.s | 3 +-- lld/test/ELF/mips-out-of-bounds-call16-reloc.s | 2 +- lld/test/ELF/mips-pc-relocs.s | 3 +-- lld/test/ELF/mips-plt-copy.s | 3 +-- lld/test/ELF/mips-plt-r6.s | 3 +-- lld/test/ELF/mips-reginfo.s | 3 +-- lld/test/ELF/mips-relocatable.s | 3 +-- lld/test/ELF/mips-sto-pic-flag.s | 3 +-- lld/test/ELF/mips-sto-plt.s | 3 +-- lld/test/ELF/mips-tls-64.s | 3 +-- lld/test/ELF/mips-tls-hilo.s | 3 +-- lld/test/ELF/mips-tls-static-64.s | 3 +-- lld/test/ELF/mips-tls-static.s | 3 +-- lld/test/ELF/mips-tls.s | 3 +-- lld/test/ELF/mips-xgot-order.s | 3 +-- lld/test/ELF/mips64-eh-abs-reloc.s | 2 +- lld/test/ELF/no-inhibit-exec.s | 2 +- lld/test/ELF/ppc-relocs.s | 2 +- lld/test/ELF/program-header-layout.s | 2 +- lld/test/ELF/reproduce-error.s | 2 +- lld/test/ELF/reproduce.s | 2 +- lld/test/ELF/resolution-end.s | 2 +- lld/test/ELF/section-layout.s | 2 +- lld/test/ELF/section-name.s | 2 +- lld/test/ELF/undefined-opt.s | 2 +- 104 files changed, 104 insertions(+), 178 deletions(-) diff --git a/lld/test/ELF/aarch64-condb-reloc.s b/lld/test/ELF/aarch64-condb-reloc.s index 23c16c2db898..8a7581480544 100644 --- a/lld/test/ELF/aarch64-condb-reloc.s +++ b/lld/test/ELF/aarch64-condb-reloc.s @@ -1,3 +1,4 @@ +# REQUIRES: aarch64 # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-freebsd %p/Inputs/aarch64-condb-reloc.s -o %t1 # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-freebsd %s -o %t2 # RUN: ld.lld %t1 %t2 -o %t @@ -5,7 +6,6 @@ # RUN: ld.lld -shared %t1 %t2 -o %t3 # RUN: llvm-objdump -d %t3 | FileCheck -check-prefix=DSO %s # RUN: llvm-readobj -s -r %t3 | FileCheck -check-prefix=DSOREL %s -# REQUIRES: aarch64 # 0x11024 - 36 = 0x11000 # 0x11028 - 24 = 0x11010 diff --git a/lld/test/ELF/aarch64-relocs.s b/lld/test/ELF/aarch64-relocs.s index 9d02bd599b25..79caabcb6bb5 100644 --- a/lld/test/ELF/aarch64-relocs.s +++ b/lld/test/ELF/aarch64-relocs.s @@ -1,8 +1,8 @@ +# REQUIRES: aarch64 # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-freebsd %s -o %t # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-freebsd %p/Inputs/uabs_label.s -o %t2.o # RUN: ld.lld %t %t2.o -o %t2 # RUN: llvm-objdump -d %t2 | FileCheck %s -# REQUIRES: aarch64 .section .R_AARCH64_ADR_PREL_LO21,"ax",@progbits .globl _start diff --git a/lld/test/ELF/aarch64-tls-gdle.s b/lld/test/ELF/aarch64-tls-gdle.s index a111cacefd29..6763c50838da 100644 --- a/lld/test/ELF/aarch64-tls-gdle.s +++ b/lld/test/ELF/aarch64-tls-gdle.s @@ -1,9 +1,9 @@ +# REQUIRES: aarch64 # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-linux %p/Inputs/aarch64-tls-ie.s -o %ttlsie.o # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-linux %s -o %tmain.o # RUN: ld.lld %tmain.o %ttlsie.o -o %tout # RUN: llvm-objdump -d %tout | FileCheck %s # RUN: llvm-readobj -s -r %tout | FileCheck -check-prefix=RELOC %s -# REQUIRES: aarch64 #Local-Dynamic to Initial-Exec relax creates no #RELOC: Relocations [ diff --git a/lld/test/ELF/aarch64-tls-ie.s b/lld/test/ELF/aarch64-tls-ie.s index 8b7431093a26..f4dec2b0bebe 100644 --- a/lld/test/ELF/aarch64-tls-ie.s +++ b/lld/test/ELF/aarch64-tls-ie.s @@ -1,3 +1,4 @@ +# REQUIRES: aarch64 // REQUIRES: aarch64 # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-freebsd %p/Inputs/aarch64-tls-ie.s -o %tdso.o # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-freebsd %s -o %tmain.o @@ -5,7 +6,6 @@ # RUN: ld.lld --hash-style=sysv %tmain.o %tdso.so -o %tout # RUN: llvm-objdump -d %tout | FileCheck %s # RUN: llvm-readobj -s -r %tout | FileCheck -check-prefix=RELOC %s -# REQUIRES: aarch64 #RELOC: Section { #RELOC: Index: diff --git a/lld/test/ELF/aarch64-tls-iele.s b/lld/test/ELF/aarch64-tls-iele.s index 208b5cdd5446..c97a578f8dc2 100644 --- a/lld/test/ELF/aarch64-tls-iele.s +++ b/lld/test/ELF/aarch64-tls-iele.s @@ -1,9 +1,9 @@ +# REQUIRES: aarch64 # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-linux %p/Inputs/aarch64-tls-ie.s -o %ttlsie.o # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-linux %s -o %tmain.o # RUN: ld.lld %tmain.o %ttlsie.o -o %tout # RUN: llvm-objdump -d %tout | FileCheck %s # RUN: llvm-readobj -s -r %tout | FileCheck -check-prefix=RELOC %s -# REQUIRES: aarch64 # Initial-Exec to Local-Exec relax creates no dynamic relocations. # RELOC: Relocations [ diff --git a/lld/test/ELF/aarch64-tls-le.s b/lld/test/ELF/aarch64-tls-le.s index df943f7f091a..e5b1c208a185 100644 --- a/lld/test/ELF/aarch64-tls-le.s +++ b/lld/test/ELF/aarch64-tls-le.s @@ -1,8 +1,8 @@ +# REQUIRES: aarch64 # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-freebsd %s -o %tmain.o # RUN: ld.lld %tmain.o -o %tout # RUN: llvm-objdump -d %tout | FileCheck %s # RUN: llvm-readobj -s -r %tout | FileCheck -check-prefix=RELOC %s -# REQUIRES: aarch64 #Local-Dynamic to Initial-Exec relax creates no #RELOC: Relocations [ diff --git a/lld/test/ELF/aarch64-tstbr14-reloc.s b/lld/test/ELF/aarch64-tstbr14-reloc.s index c0a0a543a6c5..779ca6b808a8 100644 --- a/lld/test/ELF/aarch64-tstbr14-reloc.s +++ b/lld/test/ELF/aarch64-tstbr14-reloc.s @@ -1,3 +1,4 @@ +# REQUIRES: aarch64 # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-freebsd %p/Inputs/aarch64-tstbr14-reloc.s -o %t1 # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-freebsd %s -o %t2 # RUN: ld.lld %t1 %t2 -o %t @@ -5,7 +6,6 @@ # RUN: ld.lld -shared %t1 %t2 -o %t3 # RUN: llvm-objdump -d %t3 | FileCheck -check-prefix=DSO %s # RUN: llvm-readobj -s -r %t3 | FileCheck -check-prefix=DSOREL %s -# REQUIRES: aarch64 # 0x1101c - 28 = 0x20000 # 0x11020 - 16 = 0x20010 diff --git a/lld/test/ELF/amdgpu-elf-flags-err.s b/lld/test/ELF/amdgpu-elf-flags-err.s index e30c90ee8266..d02f19566633 100644 --- a/lld/test/ELF/amdgpu-elf-flags-err.s +++ b/lld/test/ELF/amdgpu-elf-flags-err.s @@ -1,7 +1,6 @@ +# REQUIRES: amdgpu # RUN: llvm-mc -triple amdgcn-amd-amdhsa -mcpu=gfx802 -filetype=obj %S/Inputs/amdgpu-kernel-0.s -o %t-0.o # RUN: llvm-mc -triple amdgcn-amd-amdhsa -mcpu=gfx803 -filetype=obj %S/Inputs/amdgpu-kernel-1.s -o %t-1.o # RUN: not ld.lld -shared %t-0.o %t-1.o -o %t.so 2>&1 | FileCheck %s -# REQUIRES: amdgpu - # CHECK: error: incompatible e_flags: {{.*}}-1.o diff --git a/lld/test/ELF/amdgpu-elf-flags.s b/lld/test/ELF/amdgpu-elf-flags.s index b97263f2679f..d062dac748ea 100644 --- a/lld/test/ELF/amdgpu-elf-flags.s +++ b/lld/test/ELF/amdgpu-elf-flags.s @@ -1,10 +1,9 @@ +# REQUIRES: amdgpu # RUN: llvm-mc -triple amdgcn-amd-amdhsa -mcpu=gfx803 -filetype=obj %S/Inputs/amdgpu-kernel-0.s -o %t-0.o # RUN: llvm-mc -triple amdgcn-amd-amdhsa -mcpu=gfx803 -filetype=obj %S/Inputs/amdgpu-kernel-1.s -o %t-1.o # RUN: ld.lld -shared %t-0.o %t-1.o -o %t.so # RUN: llvm-readobj -file-headers %t.so | FileCheck %s -# REQUIRES: amdgpu - # CHECK: Flags [ # CHECK: EF_AMDGPU_MACH_AMDGCN_GFX803 (0x2A) # CHECK: ] diff --git a/lld/test/ELF/amdgpu-globals.s b/lld/test/ELF/amdgpu-globals.s index e32159b332e7..eadc4ef1e0d6 100644 --- a/lld/test/ELF/amdgpu-globals.s +++ b/lld/test/ELF/amdgpu-globals.s @@ -1,9 +1,8 @@ +# REQUIRES: amdgpu # RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri %s -o %t.o # RUN: ld.lld -shared %t.o -o %t # RUN: llvm-readobj -sections -symbols -program-headers %t | FileCheck %s -# REQUIRES: amdgpu - .type glob0, @object .data .globl glob0 diff --git a/lld/test/ELF/amdgpu-kernels.s b/lld/test/ELF/amdgpu-kernels.s index c76613f1a336..01b1ef2757fb 100644 --- a/lld/test/ELF/amdgpu-kernels.s +++ b/lld/test/ELF/amdgpu-kernels.s @@ -1,9 +1,8 @@ +# REQUIRES: amdgpu # RUN: llvm-mc -filetype=obj -triple amdgcn--amdhsa -mcpu=kaveri %s -o %t.o # RUN: ld.lld -shared %t.o -o %t # RUN: llvm-readobj -sections -symbols -program-headers %t | FileCheck %s -# REQUIRES: amdgpu - .hsa_code_object_version 1,0 .hsa_code_object_isa 7,0,0,"AMD","AMDGPU" diff --git a/lld/test/ELF/amdgpu-relocs.s b/lld/test/ELF/amdgpu-relocs.s index 775a262d5eb1..492190ad9433 100644 --- a/lld/test/ELF/amdgpu-relocs.s +++ b/lld/test/ELF/amdgpu-relocs.s @@ -1,10 +1,9 @@ +# REQUIRES: amdgpu # RUN: llvm-mc -filetype=obj -triple=amdgcn--amdhsa -mcpu=fiji %s -o %t.o # RUN: ld.lld --hash-style=sysv -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 -# REQUIRES: amdgpu - .text kernel0: diff --git a/lld/test/ELF/archive.s b/lld/test/ELF/archive.s index 3953c28a1792..da637bd5f51f 100644 --- a/lld/test/ELF/archive.s +++ b/lld/test/ELF/archive.s @@ -1,3 +1,4 @@ +# REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %S/Inputs/archive.s -o %t2 # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %S/Inputs/archive2.s -o %t3 @@ -10,7 +11,6 @@ # RUN: llvm-ar --format=gnu rcsT %t.thin %t2 %t3 %t4 # RUN: ld.lld %t %t.thin %t5 -o %t.out # RUN: llvm-nm %t.out | FileCheck %s -# REQUIRES: x86 # Nothing here. Just needed for the linker to create a undefined _start symbol. diff --git a/lld/test/ELF/basic-aarch64.s b/lld/test/ELF/basic-aarch64.s index 6527d3dc0def..efbe0080844f 100644 --- a/lld/test/ELF/basic-aarch64.s +++ b/lld/test/ELF/basic-aarch64.s @@ -1,8 +1,8 @@ +# REQUIRES: aarch64 # RUN: llvm-mc -filetype=obj -triple=aarch64-unknown-freebsd %s -o %t # RUN: ld.lld %t -o %t2 # RUN: llvm-readobj -file-headers -sections -program-headers -symbols %t2 \ # RUN: | FileCheck %s -# REQUIRES: aarch64 # exits with return code 42 on FreeBSD/AArch64 .globl _start diff --git a/lld/test/ELF/basic-freebsd.s b/lld/test/ELF/basic-freebsd.s index 375fdb5f8078..f614bb64b069 100644 --- a/lld/test/ELF/basic-freebsd.s +++ b/lld/test/ELF/basic-freebsd.s @@ -1,9 +1,9 @@ +# REQUIRES: x86 # Verify that OSABI is set to the correct value. # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-freebsd %s -o %t # RUN: ld.lld %t -o %t2 # RUN: llvm-readobj -file-headers %t2 | FileCheck %s -# REQUIRES: x86 .globl _start _start: diff --git a/lld/test/ELF/basic-mips.s b/lld/test/ELF/basic-mips.s index edc91b46a953..9ecabff47f6a 100644 --- a/lld/test/ELF/basic-mips.s +++ b/lld/test/ELF/basic-mips.s @@ -1,10 +1,9 @@ +# REQUIRES: mips # RUN: llvm-mc -filetype=obj -triple=mipsel-unknown-linux %s -o %t.o # RUN: ld.lld %t.o -o %t.exe # RUN: llvm-readobj -file-headers -sections -program-headers -symbols %t.exe \ # RUN: | FileCheck %s -# REQUIRES: mips - # Exits with return code 1 on Linux. .globl __start __start: diff --git a/lld/test/ELF/basic-ppc.s b/lld/test/ELF/basic-ppc.s index 2e52514606a0..f1557c3b85cf 100644 --- a/lld/test/ELF/basic-ppc.s +++ b/lld/test/ELF/basic-ppc.s @@ -1,7 +1,7 @@ +# REQUIRES: ppc # RUN: llvm-mc -filetype=obj -triple=powerpc-unknown-freebsd %s -o %t # RUN: ld.lld --hash-style=sysv -discard-all -shared %t -o %t2 # RUN: llvm-readobj -file-headers -sections -section-data -program-headers %t2 | FileCheck %s -# REQUIRES: ppc # exits with return code 42 on FreeBSD .text diff --git a/lld/test/ELF/basic-ppc64.s b/lld/test/ELF/basic-ppc64.s index fd933b8c8177..723996d76726 100644 --- a/lld/test/ELF/basic-ppc64.s +++ b/lld/test/ELF/basic-ppc64.s @@ -1,7 +1,7 @@ +# REQUIRES: ppc # # RUN: llvm-mc -filetype=obj -triple=powerpc64le-unknown-linux %s -o %t # RUN: ld.lld --hash-style=sysv -discard-all -shared %t -o %t2 # RUN: llvm-readobj -file-headers -sections -section-data -program-headers %t2 | FileCheck %s -# REQUIRES: ppc .abiversion 2 # Exits with return code 55 on linux. .text diff --git a/lld/test/ELF/basic-sparcv9.s b/lld/test/ELF/basic-sparcv9.s index 75c20476a43b..272fe01cfc40 100644 --- a/lld/test/ELF/basic-sparcv9.s +++ b/lld/test/ELF/basic-sparcv9.s @@ -1,8 +1,8 @@ +# REQUIRES: sparc # RUN: llvm-mc -filetype=obj -triple=sparc64-unknown-openbsd %s -o %t # RUN: ld.lld %t -o %t2 # RUN: llvm-readobj -file-headers -sections -program-headers -symbols %t2 \ # RUN: | FileCheck %s -# REQUIRES: sparc # exits with return code 42 on OpenBSD/sparc64 .global _start diff --git a/lld/test/ELF/basic32.s b/lld/test/ELF/basic32.s index 071a06332f0a..72058dc6b168 100644 --- a/lld/test/ELF/basic32.s +++ b/lld/test/ELF/basic32.s @@ -1,7 +1,7 @@ +# REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=i686-unknown-linux %s -o %t # RUN: ld.lld %t -o %t2 # RUN: llvm-readobj -file-headers -sections -program-headers %t2 | FileCheck %s -# REQUIRES: x86 # exits with return code 42 on linux .globl _start diff --git a/lld/test/ELF/basic64be.s b/lld/test/ELF/basic64be.s index 670bc0b06889..2bef1545153e 100644 --- a/lld/test/ELF/basic64be.s +++ b/lld/test/ELF/basic64be.s @@ -1,7 +1,7 @@ +# REQUIRES: ppc # RUN: llvm-mc -filetype=obj -triple=powerpc64-unknown-linux %s -o %t # RUN: ld.lld -discard-all %t -o %t2 # RUN: llvm-readobj -file-headers -sections -section-data -program-headers %t2 | FileCheck %s -# REQUIRES: ppc # exits with return code 42 on linux .text diff --git a/lld/test/ELF/cgprofile-bad-clusters.s b/lld/test/ELF/cgprofile-bad-clusters.s index 77bfe691725a..a6a09bd04252 100644 --- a/lld/test/ELF/cgprofile-bad-clusters.s +++ b/lld/test/ELF/cgprofile-bad-clusters.s @@ -1,8 +1,7 @@ +# REQUIRES: x86 # This test checks that CallGraphSort ignores edges that would form "bad" # clusters. -# REQUIRES: x86 - # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t # RUN: echo "A C 1" > %t.call_graph # RUN: echo "E B 4" >> %t.call_graph diff --git a/lld/test/ELF/corrupted-version-reference.s b/lld/test/ELF/corrupted-version-reference.s index d37f272f445d..1b41d7210159 100644 --- a/lld/test/ELF/corrupted-version-reference.s +++ b/lld/test/ELF/corrupted-version-reference.s @@ -1,6 +1,6 @@ +# REQUIRES: mips # RUN: llvm-mc -triple=mips64-unknown-freebsd %s -filetype=obj -o %t.o # RUN: not ld.lld %t.o %S/Inputs/corrupt-version-reference.so -o %t.exe 2>&1 | FileCheck %s -# REQUIRES: mips # CHECK: error: corrupt input file: version definition index 9 for symbol __cxa_finalize is out of bounds # CHECK: >>> defined in {{.+}}/corrupt-version-reference.so diff --git a/lld/test/ELF/dynstr-no-rosegment.s b/lld/test/ELF/dynstr-no-rosegment.s index 0e12721dac44..bad6300801e2 100644 --- a/lld/test/ELF/dynstr-no-rosegment.s +++ b/lld/test/ELF/dynstr-no-rosegment.s @@ -1,6 +1,6 @@ +# REQUIRES: x86 # Verify that a .dynstr in the .text segment has null byte terminators -# REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o # RUN: ld.lld %t.o -no-rosegment -o %t.so -shared # RUN: llvm-objdump %t.so -s -j .dynstr | FileCheck %s diff --git a/lld/test/ELF/eh-frame-hdr-abs-fde.s b/lld/test/ELF/eh-frame-hdr-abs-fde.s index c3dc862ceb49..7f75058d4b35 100644 --- a/lld/test/ELF/eh-frame-hdr-abs-fde.s +++ b/lld/test/ELF/eh-frame-hdr-abs-fde.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check reading PC values of FDEs and writing lookup table in the .eh_frame_hdr # if CIE augmentation string has 'L' token and PC values are encoded using # absolute (not relative) format. @@ -6,8 +7,6 @@ # RUN: ld.lld --eh-frame-hdr %t.o -o %t # RUN: llvm-objdump -s -dwarf=frames %t | FileCheck %s -# REQUIRES: mips - # CHECK: Contents of section .eh_frame_hdr: # CHECK-NEXT: 10128 011b033b 00000010 00000001 0000fed8 # ^-- 0x20000 - 0x10138 diff --git a/lld/test/ELF/emulation.s b/lld/test/ELF/emulation.s index 1a2af0f17f9f..98f78b8ec1df 100644 --- a/lld/test/ELF/emulation.s +++ b/lld/test/ELF/emulation.s @@ -1,3 +1,4 @@ +# REQUIRES: x86,ppc,mips,aarch64 # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-freebsd %s -o %tx64 # RUN: ld.lld -m elf_amd64_fbsd %tx64 -o %t2x64 # RUN: llvm-readobj -file-headers %t2x64 | FileCheck --check-prefix=AMD64 %s @@ -391,7 +392,5 @@ # AARCH64-NEXT: Flags [ (0x0) # AARCH64-NEXT: ] -# REQUIRES: x86,ppc,mips,aarch64 - .globl _start _start: diff --git a/lld/test/ELF/gc-sections-metadata-startstop.s b/lld/test/ELF/gc-sections-metadata-startstop.s index 10c0b5477b25..ede1899698c4 100644 --- a/lld/test/ELF/gc-sections-metadata-startstop.s +++ b/lld/test/ELF/gc-sections-metadata-startstop.s @@ -1,5 +1,5 @@ -# LINK_ORDER cnamed sections are not kept alive by the __start_* reference. # REQUIRES: x86 +# LINK_ORDER cnamed sections are not kept alive by the __start_* reference. # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o # RUN: ld.lld --gc-sections %t.o -o %t diff --git a/lld/test/ELF/mips-26-mask.s b/lld/test/ELF/mips-26-mask.s index 4cf56cfe338c..874d5c4b2338 100644 --- a/lld/test/ELF/mips-26-mask.s +++ b/lld/test/ELF/mips-26-mask.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check reading/writing implicit addend for R_MIPS_26 relocation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o # RUN: ld.lld %t.o -o %t.exe # RUN: llvm-objdump -d %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Disassembly of section .text: # CHECK: __start: # CHECK-NEXT: 20000: 0e 00 80 00 jal 134348800 diff --git a/lld/test/ELF/mips-26-n32-n64.s b/lld/test/ELF/mips-26-n32-n64.s index 246bf1e9510b..92f533152da3 100644 --- a/lld/test/ELF/mips-26-n32-n64.s +++ b/lld/test/ELF/mips-26-n32-n64.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_26 relocation handling in case of N64 ABIs. # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux \ @@ -11,8 +12,6 @@ # RUN: llvm-objdump -d %t.exe | FileCheck %s --check-prefixes=CHECK,HAZARDPLT -# REQUIRES: mips - # CHECK: Disassembly of section .text: # CHECK-NEXT: __start: # CHECK-NEXT: 20000: 0c 00 80 0c jal 131120 diff --git a/lld/test/ELF/mips-26.s b/lld/test/ELF/mips-26.s index 749920b88c8b..882129b1fa9e 100644 --- a/lld/test/ELF/mips-26.s +++ b/lld/test/ELF/mips-26.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_26 relocation handling. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t1.o @@ -9,8 +10,6 @@ # RUN: llvm-readobj -dynamic-table -s -r -mips-plt-got %t.exe \ # RUN: | FileCheck -check-prefix=REL %s -# REQUIRES: mips - # CHECK: Disassembly of section .text: # CHECK-NEXT: bar: # CHECK-NEXT: 20000: 0c 00 80 06 jal 131096 diff --git a/lld/test/ELF/mips-32.s b/lld/test/ELF/mips-32.s index ef97afcc0313..7efcfcd65167 100644 --- a/lld/test/ELF/mips-32.s +++ b/lld/test/ELF/mips-32.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_32 relocation calculation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t-be.o @@ -14,8 +15,6 @@ # RUN: llvm-readobj -r -dynamic-table -mips-plt-got %t-el.so \ # RUN: | FileCheck -check-prefix=REL %s -# REQUIRES: mips - .globl __start __start: nop diff --git a/lld/test/ELF/mips-64-disp.s b/lld/test/ELF/mips-64-disp.s index 29b62dcd050a..5d5049c4cae7 100644 --- a/lld/test/ELF/mips-64-disp.s +++ b/lld/test/ELF/mips-64-disp.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_GOT_DISP relocations against various kind of symbols. # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux \ @@ -8,8 +9,6 @@ # RUN: llvm-objdump -d -t %t.exe | FileCheck %s # RUN: llvm-readobj -r -mips-plt-got %t.exe | FileCheck -check-prefix=GOT %s -# REQUIRES: mips - # CHECK: __start: # CHECK-NEXT: 20000: 24 42 80 40 addiu $2, $2, -32704 # CHECK-NEXT: 20004: 24 42 80 20 addiu $2, $2, -32736 diff --git a/lld/test/ELF/mips-64-got.s b/lld/test/ELF/mips-64-got.s index f2b4d5b07ab5..e1b1f3475470 100644 --- a/lld/test/ELF/mips-64-got.s +++ b/lld/test/ELF/mips-64-got.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check MIPS N64 ABI GOT relocations # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux \ @@ -8,8 +9,6 @@ # RUN: llvm-objdump -d -t %t.exe | FileCheck %s # RUN: llvm-readobj -r -mips-plt-got %t.exe | FileCheck -check-prefix=GOT %s -# REQUIRES: mips - # CHECK: __start: # CHECK-NEXT: 20000: df 82 80 20 ld $2, -32736($gp) diff --git a/lld/test/ELF/mips-64-gprel-so.s b/lld/test/ELF/mips-64-gprel-so.s index 437238ef5f26..d741dd907137 100644 --- a/lld/test/ELF/mips-64-gprel-so.s +++ b/lld/test/ELF/mips-64-gprel-so.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check setup of GP relative offsets in a function's prologue. # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux %s -o %t.o # RUN: ld.lld %t.o -shared -o %t.so # RUN: llvm-objdump -d -t %t.so | FileCheck %s -# REQUIRES: mips - # CHECK: Disassembly of section .text: # CHECK-NEXT: foo: # CHECK-NEXT: 10000: 3c 1c 00 01 lui $gp, 1 diff --git a/lld/test/ELF/mips-64-rels.s b/lld/test/ELF/mips-64-rels.s index 78671554b1cb..e641b326ce56 100644 --- a/lld/test/ELF/mips-64-rels.s +++ b/lld/test/ELF/mips-64-rels.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check handling multiple MIPS N64 ABI relocations packed # into the single relocation record. @@ -6,8 +7,6 @@ # RUN: llvm-objdump -d -s -t %t.exe | FileCheck %s # RUN: llvm-readobj -r %t.exe | FileCheck -check-prefix=REL %s -# REQUIRES: mips - # CHECK: __start: # CHECK-NEXT: 20000: 3c 1c 00 01 lui $gp, 1 # ^-- 0x20000 - 0x37ff0 diff --git a/lld/test/ELF/mips-64.s b/lld/test/ELF/mips-64.s index 501988ddb8be..e37b75c070ec 100644 --- a/lld/test/ELF/mips-64.s +++ b/lld/test/ELF/mips-64.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_64 relocation calculation. # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux %s -o %t.o @@ -5,8 +6,6 @@ # RUN: llvm-objdump -t %t.so | FileCheck -check-prefix=SYM %s # RUN: llvm-readobj -r -dynamic-table -mips-plt-got %t.so | FileCheck %s -# REQUIRES: mips - .global __start __start: nop diff --git a/lld/test/ELF/mips-call-hilo.s b/lld/test/ELF/mips-call-hilo.s index 2504612f9e34..9c7633a8464d 100644 --- a/lld/test/ELF/mips-call-hilo.s +++ b/lld/test/ELF/mips-call-hilo.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_CALL_HI16 / R_MIPS_CALL_LO16 relocations calculation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o @@ -5,8 +6,6 @@ # RUN: llvm-objdump -d %t.so | FileCheck %s # RUN: llvm-readobj -r -mips-plt-got %t.so | FileCheck -check-prefix=GOT %s -# REQUIRES: mips - # CHECK: Disassembly of section .text: # CHECK-NEXT: foo: # CHECK-NEXT: 10000: 3c 02 00 00 lui $2, 0 diff --git a/lld/test/ELF/mips-call16.s b/lld/test/ELF/mips-call16.s index 4a5d0bf3f871..7b3da0c41ff0 100644 --- a/lld/test/ELF/mips-call16.s +++ b/lld/test/ELF/mips-call16.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_CALL16 relocation calculation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o @@ -6,8 +7,6 @@ # RUN: llvm-readobj -mips-plt-got -symbols %t.exe \ # RUN: | FileCheck -check-prefix=GOT %s -# REQUIRES: mips - .text .globl __start __start: diff --git a/lld/test/ELF/mips-dynamic.s b/lld/test/ELF/mips-dynamic.s index 820776be6eeb..ebc2625970cb 100644 --- a/lld/test/ELF/mips-dynamic.s +++ b/lld/test/ELF/mips-dynamic.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check MIPS specific .dynamic section entries. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o @@ -20,8 +21,6 @@ # RUN: llvm-readobj -sections -dyn-symbols -dynamic-table %t.so \ # RUN: | FileCheck -check-prefix=DSO %s -# REQUIRES: mips - # EXE: Sections [ # EXE: Name: .dynamic # EXE-NEXT: Type: SHT_DYNAMIC diff --git a/lld/test/ELF/mips-dynsym-sort.s b/lld/test/ELF/mips-dynsym-sort.s index 7d4559cf9335..d1b935b63cff 100644 --- a/lld/test/ELF/mips-dynsym-sort.s +++ b/lld/test/ELF/mips-dynsym-sort.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check the order of dynamic symbols for the MIPS target. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t-be.o @@ -8,8 +9,6 @@ # RUN: ld.lld -shared %t-el.o -o %t-el.so # RUN: llvm-readobj -symbols -dyn-symbols %t-el.so | FileCheck %s -# REQUIRES: mips - .data .globl v1,v2,v3 v1: diff --git a/lld/test/ELF/mips-elf-abi.s b/lld/test/ELF/mips-elf-abi.s index 8721b48ae66a..86c02f34f6a5 100644 --- a/lld/test/ELF/mips-elf-abi.s +++ b/lld/test/ELF/mips-elf-abi.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check EI_ABIVERSION flags # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o @@ -10,8 +11,6 @@ # RUN: ld.lld -r -o %t.rel %t.o # RUN: llvm-readobj -h %t.rel | FileCheck -check-prefix=REL %s -# REQUIRES: mips - # DSO: ABIVersion: 0 # EXE: ABIVersion: 1 # PIE: ABIVersion: 0 diff --git a/lld/test/ELF/mips-elf-flags-err.s b/lld/test/ELF/mips-elf-flags-err.s index e1ac8c5e015e..aecc4ad5af57 100644 --- a/lld/test/ELF/mips-elf-flags-err.s +++ b/lld/test/ELF/mips-elf-flags-err.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check MIPS ELF ISA flag calculation if input files have different ISAs. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ @@ -57,8 +58,6 @@ # RUN: %s -o %t2.o # RUN: not ld.lld %t1.o %t2.o -o %t.exe 2>&1 | FileCheck -check-prefix=NAN %s -# REQUIRES: mips - .option pic0 .text .global __start diff --git a/lld/test/ELF/mips-elf-flags.s b/lld/test/ELF/mips-elf-flags.s index d2b3d929e2f5..68f4cc3008e4 100644 --- a/lld/test/ELF/mips-elf-flags.s +++ b/lld/test/ELF/mips-elf-flags.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check generation of MIPS specific ELF header flags. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ @@ -41,8 +42,6 @@ # RUN: ld.lld %t.o %t-mm.o -o %t.exe # RUN: llvm-readobj -h -mips-abi-flags %t.exe | FileCheck -check-prefix=MICRO %s -# REQUIRES: mips - .text .globl __start __start: diff --git a/lld/test/ELF/mips-gnu-hash.s b/lld/test/ELF/mips-gnu-hash.s index 288d54043fc1..48abbc11f931 100644 --- a/lld/test/ELF/mips-gnu-hash.s +++ b/lld/test/ELF/mips-gnu-hash.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Shouldn't allow the GNU hash style to be selected with the MIPS target. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t-be.o @@ -8,8 +9,6 @@ # CHECK: the .gnu.hash section is not compatible with the MIPS target. -# REQUIRES: mips - .globl __start __start: nop diff --git a/lld/test/ELF/mips-got-extsym.s b/lld/test/ELF/mips-got-extsym.s index 3af4ba07b234..ea57d77a0353 100644 --- a/lld/test/ELF/mips-got-extsym.s +++ b/lld/test/ELF/mips-got-extsym.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check creation of GOT entries for global symbols in case of executable # file linking. Symbols defined in DSO should get entries in the global part # of the GOT. Symbols defined in the executable itself should get local GOT @@ -10,8 +11,6 @@ # RUN: ld.lld %t.o %t.so -o %t.exe # RUN: llvm-readobj -dt -t -mips-plt-got %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Symbols [ # CHECK: Symbol { # CHECK: Name: _foo diff --git a/lld/test/ELF/mips-got-hilo.s b/lld/test/ELF/mips-got-hilo.s index fa7e752d9f91..1ae24f3472fe 100644 --- a/lld/test/ELF/mips-got-hilo.s +++ b/lld/test/ELF/mips-got-hilo.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_GOT_HI16 / R_MIPS_GOT_LO16 relocations calculation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o @@ -5,8 +6,6 @@ # RUN: llvm-objdump -d %t.so | FileCheck %s # RUN: llvm-readobj -r -mips-plt-got %t.so | FileCheck -check-prefix=GOT %s -# REQUIRES: mips - # CHECK: Disassembly of section .text: # CHECK-NEXT: foo: # CHECK-NEXT: 10000: 3c 02 00 00 lui $2, 0 diff --git a/lld/test/ELF/mips-got-page-script.s b/lld/test/ELF/mips-got-page-script.s index 056e4fda77c2..0ec19fc14ad4 100644 --- a/lld/test/ELF/mips-got-page-script.s +++ b/lld/test/ELF/mips-got-page-script.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check calculation of MIPS GOT page address entries number # when a linker script is provided. @@ -8,8 +9,6 @@ # RUN: ld.lld -shared --script %t.script -o %t.so %t.o # RUN: llvm-readobj -t -mips-plt-got %t.so | FileCheck %s -# REQUIRES: mips - # CHECK: Name: foo1 # CHECK-NEXT: Value: 0x10000 # CHECK: Name: foo2 diff --git a/lld/test/ELF/mips-got-page.s b/lld/test/ELF/mips-got-page.s index e2dc485ba661..46ddf4a7122c 100644 --- a/lld/test/ELF/mips-got-page.s +++ b/lld/test/ELF/mips-got-page.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check the case when small section (less that 0x10000 bytes) occupies # two adjacent 0xffff-bytes pages. We need to create two GOT entries # for R_MIPS_GOT_PAGE relocations. @@ -6,8 +7,6 @@ # RUN: ld.lld --section-start .rodata=0x27FFC -shared -o %t.so %t.o # RUN: llvm-readobj -t -mips-plt-got %t.so | FileCheck %s -# REQUIRES: mips - # CHECK: Name: bar # CHECK-NEXT: Value: 0x28000 # ^ page-address = (0x28000 + 0x8000) & ~0xffff = 0x30000 diff --git a/lld/test/ELF/mips-got-redundant.s b/lld/test/ELF/mips-got-redundant.s index b4c6a2b31a0e..24138ca19995 100644 --- a/lld/test/ELF/mips-got-redundant.s +++ b/lld/test/ELF/mips-got-redundant.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check number of redundant entries in the local part of MIPS GOT. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o # RUN: ld.lld %t.o -shared -o %t.so # RUN: llvm-readobj -mips-plt-got %t.so | FileCheck %s -# REQUIRES: mips - # CHECK: Local entries [ # CHECK-NEXT: Entry { # CHECK-NEXT: Address: diff --git a/lld/test/ELF/mips-got-relocs.s b/lld/test/ELF/mips-got-relocs.s index 5b443e51938a..d085df06524a 100644 --- a/lld/test/ELF/mips-got-relocs.s +++ b/lld/test/ELF/mips-got-relocs.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_GOT16 relocation calculation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t-be.o @@ -30,8 +31,6 @@ # RUN: llvm-readobj -relocations %t-el.so | FileCheck -check-prefix=NORELOC %s # RUN: llvm-readobj -sections %t-el.so | FileCheck -check-prefix=SHFLAGS %s -# REQUIRES: mips - .text .globl __start __start: diff --git a/lld/test/ELF/mips-got-script.s b/lld/test/ELF/mips-got-script.s index c4d827f428c9..6590c59e1cda 100644 --- a/lld/test/ELF/mips-got-script.s +++ b/lld/test/ELF/mips-got-script.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check number of got entries is adjusted for linker script-added space. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o @@ -5,8 +6,6 @@ # RUN: ld.lld %t.o -shared -o %t.so -T %t.script # RUN: llvm-readobj -mips-plt-got -dynamic-table %t.so | FileCheck %s -# REQUIRES: mips - # CHECK: 0x7000000A MIPS_LOCAL_GOTNO 4 # ^-- 2 * header + 2 local entries # CHECK: Local entries [ diff --git a/lld/test/ELF/mips-got-string.s b/lld/test/ELF/mips-got-string.s index aec80ddad118..714a429ec753 100644 --- a/lld/test/ELF/mips-got-string.s +++ b/lld/test/ELF/mips-got-string.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check R_MIPS_GOT16 relocation against merge section. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux -o %t.o %s # RUN: ld.lld -shared -o %t.so %t.o # RUN: llvm-readobj -t -mips-plt-got %t.so | FileCheck %s -# REQUIRES: mips - # CHECK: Symbol { # CHECK: Name: $.str # CHECK-NEXT: Value: 0x105 diff --git a/lld/test/ELF/mips-got-weak.s b/lld/test/ELF/mips-got-weak.s index d09e1269eb4a..478e294f02f3 100644 --- a/lld/test/ELF/mips-got-weak.s +++ b/lld/test/ELF/mips-got-weak.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_GOT16 relocation against weak symbols. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o @@ -8,8 +9,6 @@ # RUN: llvm-readobj -r -dt -dynamic-table -mips-plt-got %t2.so \ # RUN: | FileCheck -check-prefixes=CHECK,SYM %s -# REQUIRES: mips - # CHECK: Relocations [ # CHECK-NEXT: ] diff --git a/lld/test/ELF/mips-got16-relocatable.s b/lld/test/ELF/mips-got16-relocatable.s index bbacfdbaa682..04b7cbb8e904 100644 --- a/lld/test/ELF/mips-got16-relocatable.s +++ b/lld/test/ELF/mips-got16-relocatable.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check writing updated addend for R_MIPS_GOT16 relocation, # when produce a relocatable output. @@ -7,8 +8,6 @@ # RUN: ld.lld -shared -o %t.so %t # RUN: llvm-objdump -d %t.so | FileCheck -check-prefix=SO %s -# REQUIRES: mips - # OBJ: Disassembly of section .text: # OBJ-NEXT: .text: # OBJ-NEXT: 0: 8f 99 00 00 lw $25, 0($gp) diff --git a/lld/test/ELF/mips-got16.s b/lld/test/ELF/mips-got16.s index 6ad7b2b0d46e..cf0847da53d3 100644 --- a/lld/test/ELF/mips-got16.s +++ b/lld/test/ELF/mips-got16.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_GOT16 relocation calculation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o @@ -5,8 +6,6 @@ # RUN: llvm-objdump -d -t %t.so | FileCheck %s # RUN: llvm-readobj -r -mips-plt-got %t.so | FileCheck -check-prefix=GOT %s -# REQUIRES: mips - # CHECK: Disassembly of section .text: # CHECK-NEXT: __start: # CHECK-NEXT: 10000: 8f 88 80 18 lw $8, -32744($gp) diff --git a/lld/test/ELF/mips-gp-disp-ver.s b/lld/test/ELF/mips-gp-disp-ver.s index 134a056a3620..8eaee19daf19 100644 --- a/lld/test/ELF/mips-gp-disp-ver.s +++ b/lld/test/ELF/mips-gp-disp-ver.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # MIPS BFD linker puts _gp_disp symbol into DSO files and assigns zero # version definition index to it. This value means 'unversioned local symbol' # while _gp_disp is a section global symbol. We have to handle this bug @@ -7,8 +8,6 @@ # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o # RUN: ld.lld %t.o %S/Inputs/mips-gp-dips-corrupt-ver.so -# REQUIRES: mips - .global __start .text __start: diff --git a/lld/test/ELF/mips-gp-disp.s b/lld/test/ELF/mips-gp-disp.s index 7a0fd6409d18..1b4226d6022b 100644 --- a/lld/test/ELF/mips-gp-disp.s +++ b/lld/test/ELF/mips-gp-disp.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check that even if _gp_disp symbol is defined in the shared library # we use our own value. @@ -9,8 +10,6 @@ # RUN: llvm-objdump -d -t %t.so | FileCheck -check-prefix=DIS %s # RUN: llvm-readobj -relocations %t.so | FileCheck -check-prefix=REL %s -# REQUIRES: mips - # INT-SO: Name: _gp_disp # INT-SO-NEXT: Value: # INT-SO-NEXT: Size: diff --git a/lld/test/ELF/mips-gp-ext.s b/lld/test/ELF/mips-gp-ext.s index eb9788c2603b..fdf69beb821b 100644 --- a/lld/test/ELF/mips-gp-ext.s +++ b/lld/test/ELF/mips-gp-ext.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check that the linker use a value of _gp symbol defined # in a linker script to calculate GOT relocations. @@ -24,8 +25,6 @@ # RUN: ld.lld -shared -o %t.abs.so --script %t.abs.script %t.o # RUN: llvm-objdump -s -t %t.abs.so | FileCheck --check-prefix=ABS %s -# REQUIRES: mips - # REL: Contents of section .text: # REL-NEXT: 0030 3c080000 2108010c 8f82ffcc # ^-- %hi(_gp_disp) diff --git a/lld/test/ELF/mips-gp-local.s b/lld/test/ELF/mips-gp-local.s index 8bb3c236edf0..1146af8ff751 100644 --- a/lld/test/ELF/mips-gp-local.s +++ b/lld/test/ELF/mips-gp-local.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check handling of relocations against __gnu_local_gp symbol. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o # RUN: ld.lld -o %t.exe %t.o # RUN: llvm-objdump -d -t %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Disassembly of section .text: # CHECK-NEXT: __start: # CHECK-NEXT: 20000: 3c 08 00 03 lui $8, 3 diff --git a/lld/test/ELF/mips-gp-lowest.s b/lld/test/ELF/mips-gp-lowest.s index ecc5f7b1f287..46da50334f5a 100644 --- a/lld/test/ELF/mips-gp-lowest.s +++ b/lld/test/ELF/mips-gp-lowest.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check that default _gp value is calculated relative # to the GP-relative section with the lowest address. @@ -8,8 +9,6 @@ # RUN: ld.lld %t.o --script %t.rel.script -shared -o %t.so # RUN: llvm-readobj -s -t %t.so | FileCheck %s -# REQUIRES: mips - .text .global foo foo: diff --git a/lld/test/ELF/mips-gprel-sec.s b/lld/test/ELF/mips-gprel-sec.s index dc54f87216da..7517983895b8 100644 --- a/lld/test/ELF/mips-gprel-sec.s +++ b/lld/test/ELF/mips-gprel-sec.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check order of gp-relative sections, i.e. sections with SHF_MIPS_GPREL flag. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o # RUN: ld.lld %t.o -shared -o %t.so # RUN: llvm-readobj -s %t.so | FileCheck %s -# REQUIRES: mips - .text nop diff --git a/lld/test/ELF/mips-gprel32-relocs-gp0.s b/lld/test/ELF/mips-gprel32-relocs-gp0.s index f27caa330100..1abdeec1b11a 100644 --- a/lld/test/ELF/mips-gprel32-relocs-gp0.s +++ b/lld/test/ELF/mips-gprel32-relocs-gp0.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check that relocatable object produced by LLD has zero gp0 value. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o @@ -8,8 +9,6 @@ # RUN: llvm-readobj -mips-reginfo %t.so | FileCheck --check-prefix=DSO %s # RUN: llvm-objdump -s -t %t.so | FileCheck --check-prefix=DUMP %s -# REQUIRES: mips - # REL: GP: 0x0 # DSO: GP: 0x27FF0 diff --git a/lld/test/ELF/mips-gprel32-relocs.s b/lld/test/ELF/mips-gprel32-relocs.s index 047165f19ae4..8f31aa87411d 100644 --- a/lld/test/ELF/mips-gprel32-relocs.s +++ b/lld/test/ELF/mips-gprel32-relocs.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check R_MIPS_GPREL32 relocation calculation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o # RUN: ld.lld -shared -o %t.so %t.o # RUN: llvm-objdump -s -section=.rodata -t %t.so | FileCheck %s -# REQUIRES: mips - .text .globl __start __start: diff --git a/lld/test/ELF/mips-higher-highest.s b/lld/test/ELF/mips-higher-highest.s index 123b51a65add..3af7dcb4b527 100644 --- a/lld/test/ELF/mips-higher-highest.s +++ b/lld/test/ELF/mips-higher-highest.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_HIGHER / R_MIPS_HIGHEST relocations calculation. # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux %s -o %t1.o @@ -6,8 +7,6 @@ # RUN: ld.lld %t1.o %t2.o -o %t.exe # RUN: llvm-objdump -d %t.exe | FileCheck %s -# REQUIRES: mips - .global __start __start: lui $6, %highest(_foo+0x300047FFF7FF7) diff --git a/lld/test/ELF/mips-hilo-gp-disp.s b/lld/test/ELF/mips-hilo-gp-disp.s index c7229ee0da25..997074efff16 100644 --- a/lld/test/ELF/mips-hilo-gp-disp.s +++ b/lld/test/ELF/mips-hilo-gp-disp.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_HI16 / LO16 relocations calculation against _gp_disp. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t1.o @@ -8,8 +9,6 @@ # RUN: ld.lld %t1.o %t2.o -shared -o %t.so # RUN: llvm-objdump -d -t %t.so | FileCheck -check-prefix=SO %s -# REQUIRES: mips - .text .globl __start __start: diff --git a/lld/test/ELF/mips-hilo-hi-only.s b/lld/test/ELF/mips-hilo-hi-only.s index 0858e3f6cd17..6fd4c683fd91 100644 --- a/lld/test/ELF/mips-hilo-hi-only.s +++ b/lld/test/ELF/mips-hilo-hi-only.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check warning on orphaned R_MIPS_HI16 relocations. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o # RUN: ld.lld %t.o -o %t.exe 2>&1 | FileCheck -check-prefix=WARN %s # RUN: llvm-objdump -d -t %t.exe | FileCheck %s -# REQUIRES: mips - .text .globl __start __start: diff --git a/lld/test/ELF/mips-hilo.s b/lld/test/ELF/mips-hilo.s index d5de9422c427..a00ffaa9fb1c 100644 --- a/lld/test/ELF/mips-hilo.s +++ b/lld/test/ELF/mips-hilo.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check R_MIPS_HI16 / LO16 relocations calculation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o # RUN: ld.lld %t.o -o %t.exe # RUN: llvm-objdump -d -t %t.exe | FileCheck %s -# REQUIRES: mips - .text .globl __start __start: diff --git a/lld/test/ELF/mips-lo16-not-relative.s b/lld/test/ELF/mips-lo16-not-relative.s index 614e6396cc92..2af1eead8847 100644 --- a/lld/test/ELF/mips-lo16-not-relative.s +++ b/lld/test/ELF/mips-lo16-not-relative.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check that R_MIPS_LO16 relocation is handled as non-relative, # and if a target symbol is a DSO data symbol, LLD create a copy # relocation. @@ -9,8 +10,6 @@ # RUN: ld.lld %t.o %t.so -o %t.exe # RUN: llvm-readobj -r %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Relocations [ # CHECK-NEXT: Section (7) .rel.dyn { # CHECK-NEXT: 0x{{[0-9A-F]+}} R_MIPS_COPY data0 0x0 diff --git a/lld/test/ELF/mips-merge-abiflags.s b/lld/test/ELF/mips-merge-abiflags.s index 2e8b43bcc3b8..d061c1b022bd 100644 --- a/lld/test/ELF/mips-merge-abiflags.s +++ b/lld/test/ELF/mips-merge-abiflags.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Test that lld handles input files with concatenated .MIPS.abiflags sections # This happens e.g. with the FreeBSD BFD (BFD 2.17.50 [FreeBSD] 2007-07-03) @@ -8,7 +9,6 @@ # RUN: %p/Inputs/mips-concatenated-abiflags.o | \ # RUN: FileCheck --check-prefix=INPUT-OBJECT %s -# REQUIRES: mips .globl __start __start: nop diff --git a/lld/test/ELF/mips-mgot.s b/lld/test/ELF/mips-mgot.s index 2151b68fe0d9..0bb1a76ea8f5 100644 --- a/lld/test/ELF/mips-mgot.s +++ b/lld/test/ELF/mips-mgot.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check MIPS multi-GOT layout. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t0.o @@ -9,8 +10,6 @@ # RUN: llvm-objdump -s -section=.got -t %t.so | FileCheck %s # RUN: llvm-readobj -r -dt -mips-plt-got %t.so | FileCheck -check-prefix=GOT %s -# REQUIRES: mips - # CHECK: Contents of section .got: # CHECK-NEXT: 60000 00000000 80000000 00010000 00010030 # CHECK-NEXT: 60010 00000000 00000004 00020000 00030000 diff --git a/lld/test/ELF/mips-micro-got.s b/lld/test/ELF/mips-micro-got.s index 8d077f2800f1..a881e0ae5fcb 100644 --- a/lld/test/ELF/mips-micro-got.s +++ b/lld/test/ELF/mips-micro-got.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check microMIPS GOT relocations for O32 ABI. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux -mattr=micromips \ @@ -8,8 +9,6 @@ # RUN: ld.lld %t1.o %t.so -o %t.exe # RUN: llvm-readobj -mips-plt-got %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Local entries [ # CHECK-NEXT: Entry { # CHECK-NEXT: Address: diff --git a/lld/test/ELF/mips-micro-got64.s b/lld/test/ELF/mips-micro-got64.s index 1961bff9f271..28ee510eb45a 100644 --- a/lld/test/ELF/mips-micro-got64.s +++ b/lld/test/ELF/mips-micro-got64.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check microMIPS GOT relocations for N64 ABI. # microMIPS 64-bit is unsupported by LLVM starting from r335057. @@ -14,8 +15,6 @@ # RUN: ld.lld %t1.o %t.so -o %t.exe # RUN: llvm-readobj -mips-plt-got %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Local entries [ # CHECK-NEXT: Entry { # CHECK-NEXT: Address: diff --git a/lld/test/ELF/mips-micro-jal.s b/lld/test/ELF/mips-micro-jal.s index 83826126f766..18d41cf13cbc 100644 --- a/lld/test/ELF/mips-micro-jal.s +++ b/lld/test/ELF/mips-micro-jal.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check PLT creation for microMIPS to microMIPS calls. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ @@ -45,8 +46,6 @@ # RUN: llvm-objdump -d -mattr=micromips %teb.exe \ # RUN: | FileCheck --check-prefix=MIXED %s -# REQUIRES: mips - # EB: Disassembly of section .plt: # EB-NEXT: .plt: # EB-NEXT: 20010: 79 80 3f fd addiupc $3, 65524 diff --git a/lld/test/ELF/mips-micro-plt.s b/lld/test/ELF/mips-micro-plt.s index 16f3bd466445..6dcd6fbeec2d 100644 --- a/lld/test/ELF/mips-micro-plt.s +++ b/lld/test/ELF/mips-micro-plt.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check less-significant bit setup for microMIPS PLT. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ @@ -9,8 +10,6 @@ # RUN: llvm-readobj -t -dt -mips-plt-got %t.exe | FileCheck %s # RUN: llvm-objdump -d -mattr=micromips %t.exe | FileCheck --check-prefix=ASM %s -# REQUIRES: mips - # CHECK: Symbols [ # CHECK: Symbol { # CHECK: Name: foo diff --git a/lld/test/ELF/mips-micro-relocs.s b/lld/test/ELF/mips-micro-relocs.s index 3986711cc7f7..b539aa946763 100644 --- a/lld/test/ELF/mips-micro-relocs.s +++ b/lld/test/ELF/mips-micro-relocs.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check handling of microMIPS relocations. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ @@ -16,8 +17,6 @@ # RUN: llvm-objdump -d -t -mattr=micromips %tel.exe \ # RUN: | FileCheck --check-prefixes=EL,SYM %s -# REQUIRES: mips - # EB: __start: # EB-NEXT: 20010: 41 a3 00 01 lui $3, 1 # EB-NEXT: 20014: 30 63 7f df addiu $3, $3, 32735 diff --git a/lld/test/ELF/mips-micro-thunks.s b/lld/test/ELF/mips-micro-thunks.s index c8695cc3e163..0505361e4a66 100644 --- a/lld/test/ELF/mips-micro-thunks.s +++ b/lld/test/ELF/mips-micro-thunks.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check microMIPS thunk generation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ @@ -36,8 +37,6 @@ # RUN: llvm-objdump -d -mattr=+micromips %t-el-r6.exe \ # RUN: | FileCheck --check-prefix=EL-R6 %s -# REQUIRES: mips - # EB-R2: __start: # EB-R2-NEXT: 20000: f4 01 00 04 jal 131080 <__microLA25Thunk_foo> # EB-R2-NEXT: 20004: 00 00 00 00 nop diff --git a/lld/test/ELF/mips-n32-emul.s b/lld/test/ELF/mips-n32-emul.s index d0d81cc1c95f..fde9e3659478 100644 --- a/lld/test/ELF/mips-n32-emul.s +++ b/lld/test/ELF/mips-n32-emul.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check that LLD shows an error when N32 ABI emulation argument # is combined with non-N32 ABI object files. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t.o # RUN: not ld.lld -m elf32btsmipn32 %t.o -o %t.exe 2>&1 | FileCheck %s -# REQUIRES: mips - .text .global __start __start: diff --git a/lld/test/ELF/mips-n32-rels.s b/lld/test/ELF/mips-n32-rels.s index 954d4c30a157..33dda7f7e85d 100644 --- a/lld/test/ELF/mips-n32-rels.s +++ b/lld/test/ELF/mips-n32-rels.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check handling of N32 ABI relocation records. # For now llvm-mc generates incorrect object files for N32 ABI. @@ -8,8 +9,6 @@ # RUN: llvm-objdump -t -d -s %t.exe | FileCheck %s # RUN: llvm-readobj -h %t.exe | FileCheck -check-prefix=ELF %s -# REQUIRES: mips - # .text # .type __start, @function # .global __start diff --git a/lld/test/ELF/mips-nonalloc.s b/lld/test/ELF/mips-nonalloc.s index 7b0aa9469f9f..38d4599c689d 100644 --- a/lld/test/ELF/mips-nonalloc.s +++ b/lld/test/ELF/mips-nonalloc.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check reading addends for relocations in non-allocatable sections. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t1.o @@ -6,8 +7,6 @@ # RUN: ld.lld %t1.o %t2.o -o %t.exe # RUN: llvm-objdump -s %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Contents of section .debug_info: # CHECK-NEXT: 0000 ffffffff 00020000 00020000 # ^--------^-- __start diff --git a/lld/test/ELF/mips-options.s b/lld/test/ELF/mips-options.s index 18f5af8ece6e..ad634171eff7 100644 --- a/lld/test/ELF/mips-options.s +++ b/lld/test/ELF/mips-options.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check MIPS .MIPS.options section generation. # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux %s -o %t1.o @@ -9,8 +10,6 @@ # RUN: ld.lld %t1.o %t2.o --gc-sections --script %t.rel.script -shared -o %t.so # RUN: llvm-readobj -symbols -mips-options %t.so | FileCheck %s -# REQUIRES: mips - .text .globl __start __start: diff --git a/lld/test/ELF/mips-out-of-bounds-call16-reloc.s b/lld/test/ELF/mips-out-of-bounds-call16-reloc.s index 64e9ab3aa7e2..62f3964f02a2 100644 --- a/lld/test/ELF/mips-out-of-bounds-call16-reloc.s +++ b/lld/test/ELF/mips-out-of-bounds-call16-reloc.s @@ -1,6 +1,6 @@ +# REQUIRES: mips # Check that we create an error on an out-of-bounds R_MIPS_CALL_16 -# REQUIRES: mips # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux %s -o %t1.o # RUN: not ld.lld %t1.o -o %t.exe 2>&1 | FileCheck %s diff --git a/lld/test/ELF/mips-pc-relocs.s b/lld/test/ELF/mips-pc-relocs.s index e0f39e7ed7c4..46c2b75578d9 100644 --- a/lld/test/ELF/mips-pc-relocs.s +++ b/lld/test/ELF/mips-pc-relocs.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check R_MIPS_PCxxx relocations calculation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ @@ -7,8 +8,6 @@ # RUN: ld.lld %t1.o %t2.o -o %t.exe # RUN: llvm-objdump -mcpu=mips32r6 -d -t -s %t.exe | FileCheck %s -# REQUIRES: mips - .text .globl __start __start: diff --git a/lld/test/ELF/mips-plt-copy.s b/lld/test/ELF/mips-plt-copy.s index 26192163e755..e035c5bd588c 100644 --- a/lld/test/ELF/mips-plt-copy.s +++ b/lld/test/ELF/mips-plt-copy.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check creating of R_MIPS_COPY and R_MIPS_JUMP_SLOT dynamic relocations # and corresponding PLT entries. @@ -8,8 +9,6 @@ # RUN: ld.lld %t.o %t.so -o %t.exe # RUN: llvm-readobj -r -mips-plt-got %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Relocations [ # CHECK-NEXT: Section ({{.*}}) .rel.dyn { # CHECK-DAG: 0x{{[0-9A-F]+}} R_MIPS_COPY data0 0x0 diff --git a/lld/test/ELF/mips-plt-r6.s b/lld/test/ELF/mips-plt-r6.s index 34e63421a397..b0ceb8214f02 100644 --- a/lld/test/ELF/mips-plt-r6.s +++ b/lld/test/ELF/mips-plt-r6.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check PLT entries generation in case of R6 ABI version. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ @@ -11,8 +12,6 @@ # RUN: ld.lld %t1.o %t.so -o %t.exe -z hazardplt # RUN: llvm-objdump -d %t.exe | FileCheck %s --check-prefixes=HAZARDPLT,CHECK -# REQUIRES: mips - # CHECK: Disassembly of section .text: # CHECK-NEXT: __start: # CHECK-NEXT: 20000: 0c 00 80 0c jal 131120 diff --git a/lld/test/ELF/mips-reginfo.s b/lld/test/ELF/mips-reginfo.s index 4024a2f6634f..049950d7424b 100644 --- a/lld/test/ELF/mips-reginfo.s +++ b/lld/test/ELF/mips-reginfo.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check MIPS .reginfo section generation. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux %s -o %t1.o @@ -6,8 +7,6 @@ # RUN: ld.lld %t1.o %t2.o --gc-sections -shared -o %t.so # RUN: llvm-readobj -symbols -mips-reginfo %t.so | FileCheck %s -# REQUIRES: mips - .text .globl __start __start: diff --git a/lld/test/ELF/mips-relocatable.s b/lld/test/ELF/mips-relocatable.s index 168ddf736e1e..0ab62774a4d8 100644 --- a/lld/test/ELF/mips-relocatable.s +++ b/lld/test/ELF/mips-relocatable.s @@ -1,11 +1,10 @@ +# REQUIRES: mips # Check linking MIPS code in case of -r linker's option. # 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 -# REQUIRES: mips - .text .global __start __start: diff --git a/lld/test/ELF/mips-sto-pic-flag.s b/lld/test/ELF/mips-sto-pic-flag.s index 3960ba322387..ae496979f7c6 100644 --- a/lld/test/ELF/mips-sto-pic-flag.s +++ b/lld/test/ELF/mips-sto-pic-flag.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # In case of linking PIC and non-PIC code together and generation # of a relocatable object, all PIC symbols should have STO_MIPS_PIC # flag in the symbol table of the ouput file. @@ -8,8 +9,6 @@ # RUN: ld.lld -r %t-npic.o %t-pic.o -o %t-rel.o # RUN: llvm-readobj -t %t-rel.o | FileCheck %s -# REQUIRES: mips - # CHECK: Symbol { # CHECK: Name: main # CHECK-NEXT: Value: diff --git a/lld/test/ELF/mips-sto-plt.s b/lld/test/ELF/mips-sto-plt.s index d02d93ada08f..b4d3ee391414 100644 --- a/lld/test/ELF/mips-sto-plt.s +++ b/lld/test/ELF/mips-sto-plt.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check assigning STO_MIPS_PLT flag to symbol needs a pointer equality. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ @@ -7,8 +8,6 @@ # RUN: ld.lld %t.o %t.so -o %t.exe # RUN: llvm-readobj -dt -mips-plt-got %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Symbol { # CHECK: Name: foo0@ # CHECK-NEXT: Value: 0x0 diff --git a/lld/test/ELF/mips-tls-64.s b/lld/test/ELF/mips-tls-64.s index 32671370fd44..f000755b4e82 100644 --- a/lld/test/ELF/mips-tls-64.s +++ b/lld/test/ELF/mips-tls-64.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check MIPS TLS 64-bit relocations handling. # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux \ @@ -13,8 +14,6 @@ # RUN: llvm-objdump -d -s -t %t-out.so | FileCheck -check-prefix=DIS-SO %s # RUN: llvm-readobj -r -mips-plt-got %t-out.so | FileCheck -check-prefix=SO %s -# REQUIRES: mips - # DIS: __start: # DIS-NEXT: 20000: 24 62 80 30 addiu $2, $3, -32720 # DIS-NEXT: 20004: 24 62 80 20 addiu $2, $3, -32736 diff --git a/lld/test/ELF/mips-tls-hilo.s b/lld/test/ELF/mips-tls-hilo.s index 47fadaa34b80..ae54602327a9 100644 --- a/lld/test/ELF/mips-tls-hilo.s +++ b/lld/test/ELF/mips-tls-hilo.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check MIPS R_MIPS_TLS_DTPREL_HI16/LO16 and R_MIPS_TLS_TPREL_HI16/LO16 # relocations handling. @@ -9,8 +10,6 @@ # RUN: ld.lld %t.o -shared -o %t.so # RUN: llvm-readobj -r -mips-plt-got %t.so | FileCheck -check-prefix=SO %s -# REQUIRES: mips - # DIS: __start: # DIS-NEXT: 20000: 24 62 00 00 addiu $2, $3, 0 # %hi(loc0 - .tdata - 0x8000) --^ diff --git a/lld/test/ELF/mips-tls-static-64.s b/lld/test/ELF/mips-tls-static-64.s index 6f88e86a3f44..04f18fa57585 100644 --- a/lld/test/ELF/mips-tls-static-64.s +++ b/lld/test/ELF/mips-tls-static-64.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check handling TLS related relocations and symbols when linking # a 64-bit static executable. @@ -5,8 +6,6 @@ # RUN: ld.lld -static %t -o %t.exe # RUN: llvm-objdump -s -t %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Contents of section .data: # CHECK-NEXT: 30000 00020004 ffffffff ffff8004 ffffffff # CHECK-NEXT: 30010 ffff9004 diff --git a/lld/test/ELF/mips-tls-static.s b/lld/test/ELF/mips-tls-static.s index a880159338a5..b09f5516bc89 100644 --- a/lld/test/ELF/mips-tls-static.s +++ b/lld/test/ELF/mips-tls-static.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check handling TLS related relocations and symbols when linking # a static executable. @@ -5,8 +6,6 @@ # RUN: ld.lld -static %t -o %t.exe # RUN: llvm-objdump -s -t %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Contents of section .data: # CHECK-NEXT: 30000 0002000c ffff8004 ffff9004 # CHECK: Contents of section .got: diff --git a/lld/test/ELF/mips-tls.s b/lld/test/ELF/mips-tls.s index 5008c3757773..ece55c69b303 100644 --- a/lld/test/ELF/mips-tls.s +++ b/lld/test/ELF/mips-tls.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check MIPS TLS relocations handling. # RUN: llvm-mc -filetype=obj -triple=mips-unknown-linux \ @@ -13,8 +14,6 @@ # RUN: llvm-objdump -d -s -t %t-out.so | FileCheck -check-prefix=DIS-SO %s # RUN: llvm-readobj -r -mips-plt-got %t-out.so | FileCheck -check-prefix=SO %s -# REQUIRES: mips - # DIS: __start: # DIS-NEXT: 20000: 24 62 80 20 addiu $2, $3, -32736 # DIS-NEXT: 20004: 24 62 80 18 addiu $2, $3, -32744 diff --git a/lld/test/ELF/mips-xgot-order.s b/lld/test/ELF/mips-xgot-order.s index 911731c713cd..c44cf64edd5a 100644 --- a/lld/test/ELF/mips-xgot-order.s +++ b/lld/test/ELF/mips-xgot-order.s @@ -1,3 +1,4 @@ +# REQUIRES: mips # Check that GOT entries accessed via 16-bit indexing are allocated # in the beginning of the GOT. @@ -5,8 +6,6 @@ # RUN: ld.lld %t.o -o %t.exe # RUN: llvm-objdump -d -s -t %t.exe | FileCheck %s -# REQUIRES: mips - # CHECK: Disassembly of section .text: # CHECK-NEXT: __start: # CHECK-NEXT: 20000: 3c 02 00 00 lui $2, 0 diff --git a/lld/test/ELF/mips64-eh-abs-reloc.s b/lld/test/ELF/mips64-eh-abs-reloc.s index aa21a3769b12..7c31e1b51eda 100644 --- a/lld/test/ELF/mips64-eh-abs-reloc.s +++ b/lld/test/ELF/mips64-eh-abs-reloc.s @@ -1,5 +1,5 @@ -# Having an R_MIPS_64 relocation in eh_frame would previously crash LLD # REQUIRES: mips +# Having an R_MIPS_64 relocation in eh_frame would previously crash LLD # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-freebsd %s -o %t.o # RUN: llvm-readobj -r %t.o | FileCheck %s -check-prefix OBJ # RUN: ld.lld --eh-frame-hdr -shared -z notext -o %t.so %t.o diff --git a/lld/test/ELF/no-inhibit-exec.s b/lld/test/ELF/no-inhibit-exec.s index afb7aed94c12..1535f6e7b87e 100644 --- a/lld/test/ELF/no-inhibit-exec.s +++ b/lld/test/ELF/no-inhibit-exec.s @@ -1,9 +1,9 @@ +# REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t # RUN: not ld.lld %t -o %t2 # RUN: ld.lld %t --noinhibit-exec -o %t2 # RUN: llvm-objdump -d %t2 | FileCheck %s # RUN: llvm-readobj -r %t2 | FileCheck %s --check-prefix=RELOC -# REQUIRES: x86 # CHECK: Disassembly of section .text: # CHECK-NEXT: _start diff --git a/lld/test/ELF/ppc-relocs.s b/lld/test/ELF/ppc-relocs.s index 5aa3474e6339..26810008bd12 100644 --- a/lld/test/ELF/ppc-relocs.s +++ b/lld/test/ELF/ppc-relocs.s @@ -1,7 +1,7 @@ +# REQUIRES: ppc # RUN: llvm-mc -filetype=obj -triple=powerpc-unknown-freebsd %s -o %t # RUN: ld.lld %t -o %t2 # RUN: llvm-objdump -d %t2 | FileCheck %s -# REQUIRES: ppc .section .R_PPC_ADDR16_HA,"ax",@progbits .globl _start diff --git a/lld/test/ELF/program-header-layout.s b/lld/test/ELF/program-header-layout.s index 57759c946dac..949a96e4f438 100644 --- a/lld/test/ELF/program-header-layout.s +++ b/lld/test/ELF/program-header-layout.s @@ -1,7 +1,7 @@ +# REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t # RUN: ld.lld %t -o %t2 # RUN: llvm-readobj -sections -program-headers %t2 | FileCheck %s -# REQUIRES: x86 # Check that different output sections with the same flags are merged into a # single Read/Write PT_LOAD. diff --git a/lld/test/ELF/reproduce-error.s b/lld/test/ELF/reproduce-error.s index e2de8a4feeba..3a99815d7708 100644 --- a/lld/test/ELF/reproduce-error.s +++ b/lld/test/ELF/reproduce-error.s @@ -1,5 +1,5 @@ -# Extracting the tar archive can get over the path limit on windows. # REQUIRES: shell +# Extracting the tar archive can get over the path limit on windows. # RUN: rm -rf %t.dir # RUN: mkdir -p %t.dir diff --git a/lld/test/ELF/reproduce.s b/lld/test/ELF/reproduce.s index 69671a088473..94371e420177 100644 --- a/lld/test/ELF/reproduce.s +++ b/lld/test/ELF/reproduce.s @@ -1,7 +1,7 @@ +# REQUIRES: shell # REQUIRES: x86 # Extracting the tar archive can get over the path limit on windows. -# REQUIRES: shell # RUN: rm -rf %t.dir # RUN: mkdir -p %t.dir/build1 diff --git a/lld/test/ELF/resolution-end.s b/lld/test/ELF/resolution-end.s index 26858372ce09..c8c5a044e602 100644 --- a/lld/test/ELF/resolution-end.s +++ b/lld/test/ELF/resolution-end.s @@ -1,9 +1,9 @@ +# REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t1.o # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %p/Inputs/resolution-end.s -o %t2.o # RUN: ld.lld -shared -o %t2.so %t2.o # RUN: ld.lld --hash-style=sysv %t1.o %t2.so -o %t # RUN: llvm-readobj -t -s -section-data %t | FileCheck %s -# REQUIRES: x86 # Test that we resolve _end to the this executable. diff --git a/lld/test/ELF/section-layout.s b/lld/test/ELF/section-layout.s index 7febec85a629..143fc5e5fcf7 100644 --- a/lld/test/ELF/section-layout.s +++ b/lld/test/ELF/section-layout.s @@ -1,7 +1,7 @@ +# REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t # RUN: ld.lld %t -o %tout # RUN: llvm-readobj -sections %tout | FileCheck %s -# REQUIRES: x86 # Check that sections are laid out in the correct order. diff --git a/lld/test/ELF/section-name.s b/lld/test/ELF/section-name.s index caf574f2c106..4f010c81963c 100644 --- a/lld/test/ELF/section-name.s +++ b/lld/test/ELF/section-name.s @@ -1,7 +1,7 @@ +# REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t # RUN: ld.lld %t -o %tout # RUN: llvm-objdump --section-headers %tout | FileCheck %s -# REQUIRES: x86 .global _start .text diff --git a/lld/test/ELF/undefined-opt.s b/lld/test/ELF/undefined-opt.s index d8b793d7bab4..9e93e0fdce4d 100644 --- a/lld/test/ELF/undefined-opt.s +++ b/lld/test/ELF/undefined-opt.s @@ -1,3 +1,4 @@ +# REQUIRES: x86 # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t.o # RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux \ # RUN: %p/Inputs/abs.s -o %tabs.o @@ -5,7 +6,6 @@ # RUN: %p/Inputs/shared.s -o %tshared.o # RUN: rm -f %tar.a # RUN: llvm-ar rcs %tar.a %tabs.o %tshared.o -# REQUIRES: x86 # Symbols from the archive are not in if not needed # RUN: ld.lld -o %t1 %t.o %tar.a