Files
TheRock/compiler/amd-llvm/llvm/test/MC/RISCV/zibi-valid.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

58 lines
2.5 KiB
ArmAsm

# RUN: llvm-mc -triple=riscv32 -show-encoding --mattr=+experimental-zibi %s \
# RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-ASM
# RUN: llvm-mc -triple=riscv64 -show-encoding --mattr=+experimental-zibi %s \
# RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-ASM
# RUN: not llvm-mc -triple=riscv32 -show-encoding %s 2>&1 \
# RUN: | FileCheck %s --check-prefix=CHECK-ERROR
# RUN: not llvm-mc -triple=riscv64 -show-encoding %s 2>&1 \
# RUN: | FileCheck %s --check-prefix=CHECK-ERROR
# RUN: llvm-mc -triple=riscv32 -filetype=obj --mattr=+experimental-zibi %s \
# RUN: | llvm-objdump -dr --mattr=+experimental-zibi --no-print-imm-hex - \
# RUN: | FileCheck %s --check-prefix=CHECK-OBJ
beqi a0, 1, 1024
# CHECK-OBJ: beqi a0, 1, 0x400
# CHECK-ASM: beqi a0, 1, 1024
# CHECK-ENCODING: [0x63,0x20,0x15,0x40]
# CHECK-ERROR: instruction requires the following: 'Zibi' (Branch with Immediate){{$}}
beqi a5, -1, -1024
# CHECK-OBJ: beqi a5, -1, 0xfffffc04
# CHECK-ASM: beqi a5, -1, -1024
# CHECK-ENCODING: [0xe3,0xa0,0x07,0xc0]
# CHECK-ERROR: instruction requires the following: 'Zibi' (Branch with Immediate){{$}}
beqi s0, 22, 0xffe
# CHECK-OBJ: beqi s0, 22, 0x1006
# CHECK-ASM: beqi s0, 22, 4094
# CHECK-ENCODING: [0xe3,0x2f,0x64,0x7f]
# CHECK-ERROR: instruction requires the following: 'Zibi' (Branch with Immediate){{$}}
beqi s1, 11, -4096
# CHECK-OBJ: beqi s1, 11, 0xfffff00c
# CHECK-ASM: beqi s1, 11, -4096
# CHECK-ENCODING: [0x63,0xa0,0xb4,0x80]
# CHECK-ERROR: instruction requires the following: 'Zibi' (Branch with Immediate){{$}}
bnei a0, 1, 1024
# CHECK-OBJ: bnei a0, 1, 0x410
# CHECK-ASM: bnei a0, 1, 1024
# CHECK-ENCODING: [0x63,0x30,0x15,0x40]
# CHECK-ERROR: instruction requires the following: 'Zibi' (Branch with Immediate){{$}}
bnei a5, -1, -1024
# CHECK-OBJ: bnei a5, -1, 0xfffffc14
# CHECK-ASM: bnei a5, -1, -1024
# CHECK-ENCODING: [0xe3,0xb0,0x07,0xc0]
# CHECK-ERROR: instruction requires the following: 'Zibi' (Branch with Immediate){{$}}
bnei s0, 22, 0xffe
# CHECK-OBJ: bnei s0, 22, 0x1016
# CHECK-ASM: bnei s0, 22, 4094
# CHECK-ENCODING: [0xe3,0x3f,0x64,0x7f]
# CHECK-ERROR: instruction requires the following: 'Zibi' (Branch with Immediate){{$}}
bnei s1, 11, -4096
# CHECK-OBJ: bnei s1, 11, 0xfffff01c
# CHECK-ASM: bnei s1, 11, -4096
# CHECK-ENCODING: [0x63,0xb0,0xb4,0x80]
# CHECK-ERROR: instruction requires the following: 'Zibi' (Branch with Immediate){{$}}
bnei s1, 12, undef+1
# CHECK-OBJ: beqi s1, 12, {{.*}}
# CHECK-OBJ-NEXT: j {{.*}}
# CHECK-OBJ-NEXT: R_RISCV_JAL undef+0x1
# CHECK-ASM: bnei s1, 12, undef+1