Files
TheRock/compiler/amd-llvm/llvm/test/MC/AArch64/label-arithmetic-darwin.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
1.6 KiB
ArmAsm

// RUN: llvm-mc -triple aarch64-darwin -filetype=obj %s -o - | llvm-objdump --no-print-imm-hex -r -d - | FileCheck %s
// RUN: llvm-mc -triple aarch64-ios -filetype=obj %s -o - | llvm-objdump --no-print-imm-hex -r -d - | FileCheck %s
visible:
.space 8
Lstart:
.space 8
Lend:
adds w0, w1, #(Lend - Lstart)
adds x0, x1, #(Lend - Lstart)
add w0, w1, #(Lend - Lstart)
add x0, x1, #(Lend - Lstart)
cmp w0, #(Lend - Lstart)
cmp x0, #(Lend - Lstart)
sub w0, w1, #(Lend - Lstart)
sub x0, x1, #(Lend - Lstart)
// CHECK: adds w0, w1, #8
// CHECK: adds x0, x1, #8
// CHECK: add w0, w1, #8
// CHECK: add x0, x1, #8
// CHECK: cmp w0, #8
// CHECK: cmp x0, #8
// CHECK: sub w0, w1, #8
// CHECK: sub x0, x1, #8
add w0, w1, #(Lend - Lstart), lsl #12
cmp w0, #(Lend - Lstart), lsl #12
// CHECK: add w0, w1, #8, lsl #12
// CHECK: cmp w0, #8, lsl #12
add w0, w1, #((Lend - Lstart) >> 2)
cmp w0, #((Lend - Lstart) >> 2)
// CHECK: add w0, w1, #2
// CHECK: cmp w0, #2
add w0, w1, #(Lend - Lstart + 12)
cmp w0, #(Lend - Lstart + 12)
// CHECK: add w0, w1, #20
// CHECK: cmp w0, #20
add w0, w1, #(Lforward - Lend)
cmp w0, #(Lforward - Lend)
// CHECK: add w0, w1, #320
// CHECK: cmp w0, #320
add w0, w1, #(Lstart - visible)
cmp w0, #(Lstart - visible)
// CHECK: add w0, w1, #8
// CHECK: cmp w0, #8
// Add some filler so we don't have to modify #(Lforward - Lend) if we add more
// instructions above
Lfiller:
.space 320 - (Lfiller - Lend)
Lforward:
.space 4
add w0, w1, #(. - Lforward)
cmp w0, #(. - Lforward)
// CHECK: add w0, w1, #4
// CHECK: cmp w0, #8