Files
TheRock/compiler/amd-llvm/llvm/test/MC/LoongArch/Directives/data.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

103 lines
2.9 KiB
ArmAsm

## Test data directives.
# RUN: llvm-mc --triple=loongarch32 < %s \
# RUN: | FileCheck --check-prefix=CHECK-ASM %s
# RUN: llvm-mc --triple=loongarch64 < %s \
# RUN: | FileCheck --check-prefix=CHECK-ASM %s
# RUN: llvm-mc --triple=loongarch32 --filetype=obj < %s | llvm-objdump -s - \
# RUN: | FileCheck --check-prefix=CHECK-DATA %s
# RUN: llvm-mc --triple=loongarch64 --filetype=obj < %s | llvm-objdump -s - \
# RUN: | FileCheck --check-prefix=CHECK-DATA %s
# RUN: not llvm-mc --triple=loongarch32 --defsym=ERR=1 < %s 2>&1 \
# RUN: | FileCheck %s --check-prefix=CHECK-ERR
# RUN: not llvm-mc --triple=loongarch64 --defsym=ERR=1 < %s 2>&1 \
# RUN: | FileCheck %s --check-prefix=CHECK-ERR
.data
# CHECK-ASM: .byte 0
# CHECK-ASM-NEXT: .byte 1
# CHECK-ASM-NEXT: .byte 171
# CHECK-ASM-NEXT: .byte 255
# CHECK-DATA: Contents of section .data:
# CHECK-DATA-NEXT: 0000 0001abff 0100ffff 0100ffff 0100ffff
.byte 0
.byte 1
.byte 0xab
.byte 0xff
# CHECK-ASM: .half 1
# CHECK-ASM-NEXT: .half 65535
.half 0x1
.half 0xffff
# CHECK-ASM: .half 1
# CHECK-ASM-NEXT: .half 65535
.2byte 0x1
.2byte 0xffff
# CHECK-ASM: .half 1
# CHECK-ASM-NEXT: .half 65535
.short 0x1
.short 0xffff
# CHECK-ASM: .half 0
# CHECK-ASM-NEXT: .half 1
# CHECK-ASM-NEXT: .half 4660
# CHECK-ASM-NEXT: .half 65535
# CHECK-DATA-NEXT: 0010 00000100 3412ffff 01000000 ffffffff
.hword 0
.hword 0x1
.hword 0x1234
.hword 0xffff
# CHECK-ASM: .word 1
# CHECK-ASM-NEXT: .word 4294967295
.word 0x1
.word 0xffffffff
# CHECK-ASM: .word 1
# CHECK-ASM-NEXT: .word 4294967295
# CHECK-DATA-NEXT: 0020 01000000 ffffffff 01000000 ffffffff
.long 0x1
.long 0xffffffff
# CHECK-ASM: .word 1
# CHECK-ASM-NEXT: .word 4294967295
.4byte 0x1
.4byte 0xffffffff
# CHECK-ASM: .dword 1
# CHECK-ASM-NEXT: .dword 1234605616436508552
# CHECK-DATA-NEXT: 0030 01000000 00000000 88776655 44332211
.dword 0x1
.dword 0x1122334455667788
# CHECK-ASM: .dword 1
# CHECK-ASM-NEXT: .dword 1234605616436508552
# CHECK-DATA-NEXT: 0040 01000000 00000000 88776655 44332211
.8byte 0x1
.8byte 0x1122334455667788
.ifdef ERR
# CHECK-ERR: :[[#@LINE+1]]:7: error: out of range literal value
.byte 0xffa
# CHECK-ERR: :[[#@LINE+1]]:7: error: out of range literal value
.half 0xffffa
# CHECK-ERR: :[[#@LINE+1]]:8: error: out of range literal value
.short 0xffffa
# CHECK-ERR: :[[#@LINE+1]]:8: error: out of range literal value
.hword 0xffffa
# CHECK-ERR: :[[#@LINE+1]]:8: error: out of range literal value
.2byte 0xffffa
# CHECK-ERR: :[[#@LINE+1]]:7: error: out of range literal value
.word 0xffffffffa
# CHECK-ERR: :[[#@LINE+1]]:7: error: out of range literal value
.long 0xffffffffa
# CHECK-ERR: :[[#@LINE+1]]:8: error: out of range literal value
.4byte 0xffffffffa
# CHECK-ERR: :[[#@LINE+1]]:8: error: literal value out of range for directive
.dword 0xffffffffffffffffa
# CHECK-ERR: :[[#@LINE+1]]:8: error: literal value out of range for directive
.8byte 0xffffffffffffffffa
.endif