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
43 lines
2.3 KiB
LLVM
43 lines
2.3 KiB
LLVM
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 2
|
|
; RUN: opt -passes=consthoist -consthoist-gep -S -o - %s | FileCheck %s
|
|
|
|
target datalayout = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64"
|
|
target triple = "thumbv6m-none--musleabi"
|
|
|
|
%0 = type { %1, %2, [9 x i16], %6, %7 }
|
|
%1 = type { i32, i32, i32, i32, i32, i32, i16, i16, i8, i8, i16, i32, i32, i16, i8, i8 }
|
|
%2 = type { i32, %3, i8, i8, i8, i8, i32, %4, %5, [16 x i8], i16, i16, i8, i8, i8, i8, i32, i32, i32 }
|
|
%3 = type { i16, i8, i8 }
|
|
%4 = type { i16, i8, i8 }
|
|
%5 = type { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8 }
|
|
%6 = type { i8, i8 }
|
|
%7 = type { [5 x i32], [3 x i32], [6 x i32], [3 x i32], [2 x i32], [4 x i32], [3 x i32], [2 x i32], [4 x i32], [5 x i32], [3 x i32], [6 x i32], [1 x i32], i32, i32, i32, i32, i32, i32 }
|
|
|
|
@global = external dso_local local_unnamed_addr global %0, align 4
|
|
|
|
; Check that constant GEP expressions are rewritten to one-dimensional
|
|
; (single-index) GEPs, whose base poiner is a multi-dimensional GEP.
|
|
define dso_local void @zot() {
|
|
; CHECK-LABEL: define dso_local void @zot() {
|
|
; CHECK-NEXT: bb:
|
|
; CHECK-NEXT: [[CONST1:%.*]] = bitcast ptr getelementptr inbounds ([[TMP0:%.*]], ptr @global, i32 0, i32 4, i32 11, i32 0) to ptr
|
|
; CHECK-NEXT: [[CONST:%.*]] = bitcast ptr getelementptr inbounds ([[TMP0]], ptr @global, i32 0, i32 4, i32 0, i32 0) to ptr
|
|
; CHECK-NEXT: store i32 undef, ptr [[CONST]], align 4
|
|
; CHECK-NEXT: [[MAT_GEP:%.*]] = getelementptr i8, ptr [[CONST]], i32 4
|
|
; CHECK-NEXT: [[MAT_BITCAST:%.*]] = bitcast ptr [[MAT_GEP]] to ptr
|
|
; CHECK-NEXT: store i32 undef, ptr [[MAT_BITCAST]], align 4
|
|
; CHECK-NEXT: store i32 undef, ptr [[CONST1]], align 4
|
|
; CHECK-NEXT: [[MAT_GEP2:%.*]] = getelementptr i8, ptr [[CONST1]], i32 4
|
|
; CHECK-NEXT: [[MAT_BITCAST3:%.*]] = bitcast ptr [[MAT_GEP2]] to ptr
|
|
; CHECK-NEXT: store i32 undef, ptr [[MAT_BITCAST3]], align 4
|
|
; CHECK-NEXT: ret void
|
|
;
|
|
bb:
|
|
store i32 undef, ptr getelementptr inbounds (%0, ptr @global, i32 0, i32 4, i32 0, i32 0), align 4
|
|
store i32 undef, ptr getelementptr inbounds (%0, ptr @global, i32 0, i32 4, i32 0, i32 1), align 4
|
|
store i32 undef, ptr getelementptr inbounds (%0, ptr @global, i32 0, i32 4, i32 11, i32 0), align 4
|
|
store i32 undef, ptr getelementptr inbounds (%0, ptr @global, i32 0, i32 4, i32 11, i32 1), align 4
|
|
ret void
|
|
}
|
|
|