Also fixes 80-column rule violations.
# RUN: rm -rf %t && mkdir -p %t
-# RUN: llvm-mc -triple=riscv64 -filetype=obj -o %t/elf_riscv64_non_pc_indirect_reloc.o %s
-# RUN: llvm-mc -triple=riscv32 -filetype=obj -o %t/elf_riscv32_non_pc_indirect_reloc.o %s
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000 -define-abs external_data=0xfff10000\
-# RUN: -check %s %t/elf_riscv64_non_pc_indirect_reloc.o
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000 -define-abs external_data=0xfff10000\
-# RUN: -check %s %t/elf_riscv32_non_pc_indirect_reloc.o
+# RUN: llvm-mc -triple=riscv64 -filetype=obj \
+# RUN: -o %t/elf_riscv64_non_pc_indirect_reloc.o %s
+# RUN: llvm-mc -triple=riscv32 -filetype=obj \
+# RUN: -o %t/elf_riscv32_non_pc_indirect_reloc.o %s
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
+# RUN: -define-abs external_data=0xfff10000 \
+# RUN: -check %s %t/elf_riscv64_non_pc_indirect_reloc.o
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
+# RUN: -define-abs external_data=0xfff10000 \
+# RUN: -check %s %t/elf_riscv32_non_pc_indirect_reloc.o
#
.text
# RUN: rm -rf %t && mkdir -p %t
-# RUN: llvm-mc -triple=riscv64 -position-independent -filetype=obj -o %t/elf_riscv64_sm_pic_reloc.o %s
-# RUN: llvm-mc -triple=riscv32 -position-independent -filetype=obj -o %t/elf_riscv32_sm_pic_reloc.o %s
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000 \
-# RUN: -define-abs external_func=0x1 -define-abs external_data=0x2 \
-# RUN: -check %s %t/elf_riscv64_sm_pic_reloc.o
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000\
-# RUN: -define-abs external_func=0x1 -define-abs external_data=0x2 \
-# RUN: -check %s %t/elf_riscv32_sm_pic_reloc.o
+# RUN: llvm-mc -triple=riscv64 -position-independent -filetype=obj \
+# RUN: -o %t/elf_riscv64_sm_pic_reloc.o %s
+# RUN: llvm-mc -triple=riscv32 -position-independent -filetype=obj \
+# RUN: -o %t/elf_riscv32_sm_pic_reloc.o %s
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
+# RUN: -define-abs external_func=0x1 -define-abs external_data=0x2 \
+# RUN: -check %s %t/elf_riscv64_sm_pic_reloc.o
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
+# RUN: -define-abs external_func=0x1 -define-abs external_data=0x2 \
+# RUN: -check %s %t/elf_riscv32_sm_pic_reloc.o
#
# Test ELF small/PIC relocations
# RUN: rm -rf %t && mkdir -p %t
-# RUN: llvm-mc -triple=riscv32 -position-independent -filetype=obj -o %t/elf_riscv32_got_plt_reloc.o %s
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000 \
-# RUN: -define-abs external_func=0x1 -define-abs external_data=0x2 \
-# RUN: -check %s %t/elf_riscv32_got_plt_reloc.o
-
+# RUN: llvm-mc -triple=riscv32 -position-independent -filetype=obj \
+# RUN: -o %t/elf_riscv32_got_plt_reloc.o %s
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
+# RUN: -define-abs external_func=0x1 -define-abs external_data=0x2 \
+# RUN: -check %s %t/elf_riscv32_got_plt_reloc.o
.text
.file "testcase.c"
# RUN: rm -rf %t && mkdir -p %t
-# RUN: llvm-mc -triple=riscv64 -position-independent -filetype=obj -o %t/elf_riscv64_got_plt_reloc.o %s
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000 \
-# RUN: -define-abs external_func=0x1 -define-abs external_data=0x2 \
-# RUN: -check %s %t/elf_riscv64_got_plt_reloc.o
+# RUN: llvm-mc -triple=riscv64 -position-independent -filetype=obj \
+# RUN: -o %t/elf_riscv64_got_plt_reloc.o %s
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
+# RUN: -define-abs external_func=0x1 -define-abs external_data=0x2 \
+# RUN: -check %s %t/elf_riscv64_got_plt_reloc.o
.text
# RUN: rm -rf %t && mkdir -p %t
-# RUN: llvm-mc -triple=x86_64-unknown-linux -position-independent -filetype=obj \
-# RUN: -o %t/elf_sm_pic_reloc.o %s
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000 \
-# RUN: -define-abs extern_in_range32=0xffe00000 \
-# RUN: -check %s %t/elf_sm_pic_reloc.o
+# RUN: llvm-mc -triple=x86_64-unknown-linux -position-independent \
+# RUN: -filetype=obj -o %t/elf_sm_pic_reloc.o %s
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
+# RUN: -define-abs extern_in_range32=0xffe00000 \
+# RUN: -check %s %t/elf_sm_pic_reloc.o
#
# RUN: rm -rf %t && mkdir -p %t
-# RUN: llvm-mc -triple=x86_64-unknown-linux -position-independent -filetype=obj \
-# RUN: -large-code-model -o %t/elf_lg_pic_reloc.o %s
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000 \
-# RUN: -check %s %t/elf_lg_pic_reloc.o
+# RUN: llvm-mc -triple=x86_64-unknown-linux -position-independent \
+# RUN: -filetype=obj -large-code-model -o %t/elf_lg_pic_reloc.o %s
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
+# RUN: -check %s %t/elf_lg_pic_reloc.o
#
# Test ELF large/PIC relocations.
# RUN: rm -rf %t && mkdir -p %t
-# RUN: llvm-mc -triple=x86_64-unknown-linux -position-independent -filetype=obj \
-# RUN: -o %t/elf_sm_pic_reloc.o %s
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000 \
-# RUN: -define-abs external_data=0x1 \
-# RUN: -define-abs extern_out_of_range32=0x7fff00000000 \
-# RUN: -check %s %t/elf_sm_pic_reloc.o
+# RUN: llvm-mc -triple=x86_64-unknown-linux -position-independent \
+# RUN: -filetype=obj -o %t/elf_sm_pic_reloc.o %s
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
+# RUN: -define-abs external_data=0x1 \
+# RUN: -define-abs extern_out_of_range32=0x7fff00000000 \
+# RUN: -check %s %t/elf_sm_pic_reloc.o
#
# Test ELF small/PIC relocations.
# RUN: rm -rf %t && mkdir -p %t
-# RUN: llvm-mc -triple=x86_64-unknown-linux -position-independent -filetype=obj \
-# RUN: -o %t/elf_abs_reloc.o %s
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000 \
-# RUN: -define-abs external_data_low=0x1 \
-# RUN: -define-abs external_data_high=0xffffffff80000000 \
-# RUN: -check %s %t/elf_abs_reloc.o
+# RUN: llvm-mc -triple=x86_64-unknown-linux -position-independent \
+# RUN: -filetype=obj -o %t/elf_abs_reloc.o %s
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
+# RUN: -define-abs external_data_low=0x1 \
+# RUN: -define-abs external_data_high=0xffffffff80000000 \
+# RUN: -check %s %t/elf_abs_reloc.o
#
# Test ELF absolute relocations.
# RUN: rm -rf %t && mkdir -p %t
# RUN: llvm-mc -triple=x86_64-apple-macos10.9 -filetype=obj \
-# RUN: -o %t/helper.o %S/Inputs/MachO_GOTAndStubsOptimizationHelper.s
+# RUN: -o %t/helper.o %S/Inputs/MachO_GOTAndStubsOptimizationHelper.s
# RUN: llvm-mc -triple=x86_64-apple-macos10.9 -filetype=obj \
-# RUN: -o %t/testcase.o %s
-# RUN: llvm-jitlink -noexec -slab-allocate 64Kb -entry=bypass_stub -check %s \
-# RUN: %t/testcase.o %t/helper.o
+# RUN: -o %t/testcase.o %s
+# RUN: llvm-jitlink -noexec -slab-allocate 64Kb -slab-page-size 4096 \
+# RUN: -entry=bypass_stub -check %s %t/testcase.o %t/helper.o
#
# Test that references to in-range GOT and stub targets can be bypassed.
# The helper file contains a function that uses the GOT for _x, and this file
# RUN: rm -rf %t && mkdir -p %t
# RUN: llvm-mc -triple=x86_64-apple-macosx10.9 -filetype=obj -o %t/macho_reloc.o %s
-# RUN: llvm-jitlink -noexec -slab-allocate 100Kb -slab-address 0xfff00000 \
+# RUN: llvm-jitlink -noexec \
+# RUN: -slab-allocate 100Kb -slab-address 0xfff00000 -slab-page-size 4096 \
# RUN: -define-abs external_data=0x1 -define-abs external_func=0x2 \
# RUN: -check=%s %t/macho_reloc.o
#