Files
TheRock/compiler/amd-llvm/llvm/test/MC/ELF/reloc-section-sym.s
T
derek.holloway 7502bf64a4
CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
Flatten subprojects into a single base monorepo
2026-09-02 16:34:47 -07:00

62 lines
2.3 KiB
ArmAsm

# RUN: llvm-mc -filetype=obj -triple x86_64 %s -o %t.all
# RUN: llvm-mc -filetype=obj -triple x86_64 --reloc-section-sym=all %s -o %t.all2
# RUN: llvm-mc -filetype=obj -triple x86_64 --reloc-section-sym=internal %s -o %t.internal
# RUN: llvm-mc -filetype=obj -triple x86_64 --reloc-section-sym=none %s -o %t.none
# RUN: llvm-mc -filetype=obj -triple x86_64 --reloc-section-sym=internal --save-temp-labels %s -o %t.internal-stl
# RUN: llvm-readelf -rs %t.all | FileCheck %s --check-prefix=ALL
# RUN: cmp %t.all %t.all2
# RUN: llvm-readelf -rs %t.internal | FileCheck %s --check-prefixes=INT,INTERNAL
# RUN: llvm-readelf -rs %t.none | FileCheck %s --check-prefix=NONE
# RUN: llvm-readelf -rs %t.internal-stl | FileCheck %s --check-prefixes=INT,INTERNAL2
.text
nop
local:
nop
.Ltemp:
nop
.section .text1,"ax"
call local
call .Ltemp
.section .rodata,"a"
.long local + 16
.long .Ltemp + 16
## =all (default): relocations to all eligible local binding symbols are
## converted to relocations to section symbols.
# ALL: .rela.text1
# ALL: R_X86_64_PLT32 {{.*}} .text - 3
# ALL-NEXT: R_X86_64_PLT32 {{.*}} .text - 2
# ALL: .rela.rodata
# ALL: R_X86_64_32 {{.*}} .text + 11
# ALL-NEXT: R_X86_64_32 {{.*}} .text + 12
# ALL: SECTION LOCAL DEFAULT {{.*}} .text
# ALL: NOTYPE LOCAL DEFAULT {{.*}} local
## =internal: internal symbols (.L) are converted to section symbols.
## With --save-temp-labels, .Ltemp is still converted but remains in the symbol table.
# INT: .rela.text1
# INT: R_X86_64_PLT32 {{.*}} local - 4
# INT-NEXT: R_X86_64_PLT32 {{.*}} .text - 2
# INT: .rela.rodata
# INT: R_X86_64_32 {{.*}} local + 10
# INT-NEXT: R_X86_64_32 {{.*}} .text + 12
# INT: SECTION LOCAL DEFAULT {{.*}} .text
# INTERNAL: NOTYPE LOCAL DEFAULT {{.*}} local
# INTERNAL-NOT: {{.}}
# INTERNAL2: NOTYPE LOCAL DEFAULT {{.*}} local
# INTERNAL2-NEXT: NOTYPE LOCAL DEFAULT {{.*}} .Ltemp
## =none: no symbol-to-section conversion.
# NONE: .rela.text1
# NONE: R_X86_64_PLT32 {{.*}} local - 4
# NONE-NEXT: R_X86_64_PLT32 {{.*}} .Ltemp - 4
# NONE: .rela.rodata
# NONE: R_X86_64_32 {{.*}} local + 10
# NONE-NEXT: R_X86_64_32 {{.*}} .Ltemp + 10
# NONE-NOT: SECTION
# NONE: NOTYPE LOCAL DEFAULT {{.*}} local
# NONE-NEXT: NOTYPE LOCAL DEFAULT {{.*}} .Ltemp