mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 20:23:11 +01:00
bea54db865
Add the aarch64[_be]-*-gnu_ilp32 targets to support the GNU ILP32 ABI for AArch64. The needed codegen changes were mostly already implemented in D61259, which added support for the watchOS ILP32 ABI. The main changes are: - Wiring up the new target to enable ILP32 codegen and MC. - ILP32 va_list support. - ILP32 TLSDESC relocation support. There was existing MC support for ELF ILP32 relocations from D25159 which could be enabled by passing "-target-abi ilp32" to llvm-mc. This was changed to check for "gnu_ilp32" in the target triple instead. This shouldn't cause any issues since the existing support was slightly broken: it was generating ELF64 objects instead of the ELF32 object files expected by the GNU ILP32 toolchain. This target has been tested by running the full rustc testsuite on a big-endian ILP32 system based on the GCC ILP32 toolchain. Reviewed By: kristof.beyls Differential Revision: https://reviews.llvm.org/D94143
28 lines
1.1 KiB
ArmAsm
28 lines
1.1 KiB
ArmAsm
// RUN: llvm-mc -triple=aarch64-none-linux-gnu -filetype=obj %s -o - | \
|
|
// RUN: llvm-readobj -r - | FileCheck -check-prefix=OBJ %s
|
|
// RUN: llvm-mc -triple=aarch64-none-linux-gnu_ilp32 -filetype=obj %s -o - | \
|
|
// RUN: llvm-readobj -r - | FileCheck -check-prefix=OBJ-ILP32 %s
|
|
|
|
ldr x0, some_label
|
|
ldr w3, some_label
|
|
ldrsw x9, some_label
|
|
prfm pldl3keep, some_label
|
|
|
|
// OBJ: Relocations [
|
|
// OBJ-NEXT: Section {{.*}} .rela.text {
|
|
// OBJ-NEXT: 0x0 R_AARCH64_LD_PREL_LO19 some_label 0x0
|
|
// OBJ-NEXT: 0x4 R_AARCH64_LD_PREL_LO19 some_label 0x0
|
|
// OBJ-NEXT: 0x8 R_AARCH64_LD_PREL_LO19 some_label 0x0
|
|
// OBJ-NEXT: 0xC R_AARCH64_LD_PREL_LO19 some_label 0x0
|
|
// OBJ-NEXT: }
|
|
// OBJ-NEXT: ]
|
|
|
|
// OBJ-ILP32: Relocations [
|
|
// OBJ-ILP32-NEXT: Section {{.*}} .rela.text {
|
|
// OBJ-ILP32-NEXT: 0x0 R_AARCH64_P32_LD_PREL_LO19 some_label 0x0
|
|
// OBJ-ILP32-NEXT: 0x4 R_AARCH64_P32_LD_PREL_LO19 some_label 0x0
|
|
// OBJ-ILP32-NEXT: 0x8 R_AARCH64_P32_LD_PREL_LO19 some_label 0x0
|
|
// OBJ-ILP32-NEXT: 0xC R_AARCH64_P32_LD_PREL_LO19 some_label 0x0
|
|
// OBJ-ILP32-NEXT: }
|
|
// OBJ-ILP32-NEXT: ]
|