Files
TheRock/compiler/amd-llvm/llvm/test/tools/llvm-objdump/X86/disassemble-zeroes-relocations.test
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

80 lines
2.9 KiB
Plaintext

# RUN: llvm-mc -filetype=obj -triple=x86_64 %s -o %t
## Check we do not skip zeroes blocks if have relocations pointed to these places.
# RUN: llvm-objdump -D --reloc -j .rodata %t | FileCheck %s
# RUN: llvm-objdump -D --reloc -j .rodata --disassemble-symbols=rodata3 %t | FileCheck %s --check-prefix=CHECK2
# CHECK: 0000000000000000 <rodata1>:
# CHECK-NEXT: 0: 00 00 addb %al, (%rax)
# CHECK-NEXT: 0000000000000000: R_X86_64_64 x0
# CHECK-NEXT: 2: 00 00 addb %al, (%rax)
# CHECK-NEXT: 4: 00 00 addb %al, (%rax)
# CHECK-NEXT: 6: 00 00 addb %al, (%rax)
# CHECK-NEXT: 8: 00 00 addb %al, (%rax)
# CHECK-NEXT: 0000000000000008: R_X86_64_64 x1
# CHECK-NEXT: ...
# CHECK-NEXT: 16: 00 00 addb %al, (%rax)
# CHECK-NEXT: 18: 00 00 addb %al, (%rax)
# CHECK-NEXT: 0000000000000018: R_X86_64_64 x2
# CHECK-NEXT: 1a: 00 00 addb %al, (%rax)
# CHECK-NEXT: 1c: 00 00 addb %al, (%rax)
# CHECK-NEXT: 1e: 00 00 addb %al, (%rax)
# CHECK-EMPTY:
# CHECK-NEXT: 000000000000001f <rodata2>:
# CHECK-NEXT: ...
# CHECK-EMPTY:
# CHECK-NEXT: 0000000000000037 <rodata3>:
# CHECK-NEXT: ...
# CHECK-NEXT: 3f: 00 00 addb %al, (%rax)
# CHECK-NEXT: 000000000000003f: R_X86_64_64 x3
# CHECK-NEXT: 41: 00 00 addb %al, (%rax)
# CHECK-NEXT: 43: 00 00 addb %al, (%rax)
# CHECK-NEXT: 45: 00 00 addb %al, (%rax)
# CHECK2: Disassembly of section .rodata:
# CHECK2-EMPTY:
# CHECK2-NEXT: 0000000000000037 <rodata3>:
# CHECK2-NEXT: ...
# CHECK2-NEXT: 3f: 00 00 addb %al, (%rax)
# CHECK2-NEXT: 000000000000003f: R_X86_64_64 x3
# CHECK2-NEXT: 41: 00 00 addb %al, (%rax)
# CHECK2-NEXT: 43: 00 00 addb %al, (%rax)
# CHECK2-NEXT: 45: 00 00 addb %al, (%rax)
# CHECK2-NOT: {{.}}
## Check that without -reloc all zeroes would be omitted.
# RUN: llvm-objdump -D %t | FileCheck %s --check-prefix=SKIP
# SKIP: Disassembly of section .rodata:
# SKIP-EMPTY:
# SKIP-NEXT: 0000000000000000 <rodata1>:
# SKIP-NEXT: ...
# SKIP-NEXT: 1c: 00 00 addb %al, (%rax)
# SKIP-NEXT: 1e: 00 00 addb %al, (%rax)
# SKIP-EMPTY:
# SKIP-NEXT: 000000000000001f <rodata2>:
# SKIP-NEXT: ...
# SKIP-EMPTY:
# SKIP-NEXT: 0000000000000037 <rodata3>:
# SKIP-NEXT: ...
# SKIP-EMPTY:
# SKIP-NEXT: Disassembly of section .rela.rodata:
.rodata
.globl rodata1, rodata2
rodata1:
.reloc ., BFD_RELOC_64, x0
.space 8
.reloc ., BFD_RELOC_64, x1
.space 16
.reloc ., BFD_RELOC_64, x2
.space 7
rodata2:
.space 24
rodata3:
.space 8
.reloc ., BFD_RELOC_64, x3
.space 8