Files
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

49 lines
2.3 KiB
LLVM

; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5
; RUN: llc -mtriple=amdgcn -mcpu=gfx1100 < %s | FileCheck --check-prefixes=DEFAULT %s
; RUN: llc -mtriple=amdgcn -mcpu=gfx1100 -amdgpu-waitcnt-load-forcezero < %s | FileCheck --check-prefixes=LDZERO %s
define amdgpu_kernel void @copy(ptr addrspace(1) noalias nocapture readonly %src1, ptr addrspace(1) noalias nocapture readonly %src2, ptr addrspace(1) noalias nocapture writeonly %dst1, ptr addrspace(1) noalias nocapture writeonly %dst2) {
; DEFAULT-LABEL: copy:
; DEFAULT: ; %bb.0:
; DEFAULT-NEXT: s_load_b256 s[0:7], s[4:5], 0x24
; DEFAULT-NEXT: v_and_b32_e32 v0, 0x3ff, v0
; DEFAULT-NEXT: s_delay_alu instid0(VALU_DEP_1)
; DEFAULT-NEXT: v_lshlrev_b32_e32 v0, 2, v0
; DEFAULT-NEXT: s_waitcnt lgkmcnt(0)
; DEFAULT-NEXT: s_clause 0x1
; DEFAULT-NEXT: global_load_b32 v1, v0, s[0:1]
; DEFAULT-NEXT: global_load_b32 v2, v0, s[2:3]
; DEFAULT-NEXT: s_waitcnt vmcnt(1)
; DEFAULT-NEXT: global_store_b32 v0, v1, s[4:5]
; DEFAULT-NEXT: s_waitcnt vmcnt(0)
; DEFAULT-NEXT: global_store_b32 v0, v2, s[6:7]
; DEFAULT-NEXT: s_endpgm
;
; LDZERO-LABEL: copy:
; LDZERO: ; %bb.0:
; LDZERO-NEXT: s_load_b256 s[0:7], s[4:5], 0x24
; LDZERO-NEXT: v_and_b32_e32 v0, 0x3ff, v0
; LDZERO-NEXT: s_delay_alu instid0(VALU_DEP_1)
; LDZERO-NEXT: v_lshlrev_b32_e32 v0, 2, v0
; LDZERO-NEXT: s_waitcnt lgkmcnt(0)
; LDZERO-NEXT: s_clause 0x1
; LDZERO-NEXT: global_load_b32 v1, v0, s[0:1]
; LDZERO-NEXT: global_load_b32 v2, v0, s[2:3]
; LDZERO-NEXT: s_waitcnt vmcnt(0)
; LDZERO-NEXT: s_clause 0x1
; LDZERO-NEXT: global_store_b32 v0, v1, s[4:5]
; LDZERO-NEXT: global_store_b32 v0, v2, s[6:7]
; LDZERO-NEXT: s_endpgm
%id = tail call i32 @llvm.amdgcn.workitem.id.x()
%idx = zext i32 %id to i64
%gep.ld1 = getelementptr inbounds nuw float, ptr addrspace(1) %src1, i64 %idx
%v1 = load float, ptr addrspace(1) %gep.ld1, align 4
%gep.ld2 = getelementptr inbounds nuw float, ptr addrspace(1) %src2, i64 %idx
%v2 = load float, ptr addrspace(1) %gep.ld2, align 4
%gep.st1 = getelementptr inbounds nuw float, ptr addrspace(1) %dst1, i64 %idx
store float %v1, ptr addrspace(1) %gep.st1, align 4
%gep.st2 = getelementptr inbounds nuw float, ptr addrspace(1) %dst2, i64 %idx
store float %v2, ptr addrspace(1) %gep.st2, align 4
ret void
}