Files
TheRock/compiler/amd-llvm/llvm/test/CodeGen/AMDGPU/vectorize-global-local.ll
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

81 lines
4.2 KiB
LLVM

; RUN: llc -amdgpu-scalarize-global-loads=false -mtriple=amdgcn -mcpu=tonga < %s | FileCheck %s
; CHECK-DAG: flat_load_dwordx4
; CHECK-DAG: flat_load_dwordx4
; CHECK-DAG: flat_load_dwordx4
; CHECK-DAG: flat_load_dwordx4
; CHECK-DAG: ds_write2_b32
; CHECK-DAG: ds_write2_b32
; CHECK-DAG: ds_write2_b32
; CHECK-DAG: ds_write2_b32
; CHECK-DAG: ds_write2_b32
; CHECK-DAG: ds_write2_b32
; CHECK-DAG: ds_write2_b32
; CHECK-DAG: ds_write2_b32
define amdgpu_kernel void @vectorize_global_local(ptr addrspace(1) nocapture readonly %arg, ptr addrspace(3) nocapture %arg1) {
bb:
%tmp = load i32, ptr addrspace(1) %arg, align 4
store i32 %tmp, ptr addrspace(3) %arg1, align 4
%tmp2 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 1
%tmp3 = load i32, ptr addrspace(1) %tmp2, align 4
%tmp4 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 1
store i32 %tmp3, ptr addrspace(3) %tmp4, align 4
%tmp5 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 2
%tmp6 = load i32, ptr addrspace(1) %tmp5, align 4
%tmp7 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 2
store i32 %tmp6, ptr addrspace(3) %tmp7, align 4
%tmp8 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 3
%tmp9 = load i32, ptr addrspace(1) %tmp8, align 4
%tmp10 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 3
store i32 %tmp9, ptr addrspace(3) %tmp10, align 4
%tmp11 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 4
%tmp12 = load i32, ptr addrspace(1) %tmp11, align 4
%tmp13 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 4
store i32 %tmp12, ptr addrspace(3) %tmp13, align 4
%tmp14 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 5
%tmp15 = load i32, ptr addrspace(1) %tmp14, align 4
%tmp16 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 5
store i32 %tmp15, ptr addrspace(3) %tmp16, align 4
%tmp17 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 6
%tmp18 = load i32, ptr addrspace(1) %tmp17, align 4
%tmp19 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 6
store i32 %tmp18, ptr addrspace(3) %tmp19, align 4
%tmp20 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 7
%tmp21 = load i32, ptr addrspace(1) %tmp20, align 4
%tmp22 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 7
store i32 %tmp21, ptr addrspace(3) %tmp22, align 4
%tmp23 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 8
%tmp24 = load i32, ptr addrspace(1) %tmp23, align 4
%tmp25 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 8
store i32 %tmp24, ptr addrspace(3) %tmp25, align 4
%tmp26 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 9
%tmp27 = load i32, ptr addrspace(1) %tmp26, align 4
%tmp28 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 9
store i32 %tmp27, ptr addrspace(3) %tmp28, align 4
%tmp29 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 10
%tmp30 = load i32, ptr addrspace(1) %tmp29, align 4
%tmp31 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 10
store i32 %tmp30, ptr addrspace(3) %tmp31, align 4
%tmp32 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 11
%tmp33 = load i32, ptr addrspace(1) %tmp32, align 4
%tmp34 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 11
store i32 %tmp33, ptr addrspace(3) %tmp34, align 4
%tmp35 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 12
%tmp36 = load i32, ptr addrspace(1) %tmp35, align 4
%tmp37 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 12
store i32 %tmp36, ptr addrspace(3) %tmp37, align 4
%tmp38 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 13
%tmp39 = load i32, ptr addrspace(1) %tmp38, align 4
%tmp40 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 13
store i32 %tmp39, ptr addrspace(3) %tmp40, align 4
%tmp41 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 14
%tmp42 = load i32, ptr addrspace(1) %tmp41, align 4
%tmp43 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 14
store i32 %tmp42, ptr addrspace(3) %tmp43, align 4
%tmp44 = getelementptr inbounds i32, ptr addrspace(1) %arg, i64 15
%tmp45 = load i32, ptr addrspace(1) %tmp44, align 4
%tmp46 = getelementptr inbounds i32, ptr addrspace(3) %arg1, i32 15
store i32 %tmp45, ptr addrspace(3) %tmp46, align 4
ret void
}