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
49 lines
2.2 KiB
LLVM
49 lines
2.2 KiB
LLVM
; REQUIRES: x86
|
|
; RUN: opt -module-summary %s -o %t.obj
|
|
|
|
; Test SLP and Loop Vectorization are enabled by default at O2 and O3.
|
|
; RUN: lld-link -opt:lldlto=0 -dll -noentry -opt:ltodebugpassmanager -lldsavetemps -out:%t1.dll %t.obj 2>&1 | FileCheck %s --check-prefix=CHECK-O0-SLP
|
|
; RUN: llvm-dis %t.obj.4.opt.bc -o - | FileCheck %s --check-prefix=CHECK-O0-LPV
|
|
|
|
; RUN: lld-link -opt:lldlto=1 -dll -noentry -opt:ltodebugpassmanager -lldsavetemps -out:%t2.dll %t.obj 2>&1 | FileCheck %s --check-prefix=CHECK-O1-SLP
|
|
; RUN: llvm-dis %t.obj.4.opt.bc -o - | FileCheck %s --check-prefix=CHECK-O1-LPV
|
|
|
|
; RUN: lld-link -opt:lldlto=2 -dll -noentry -opt:ltodebugpassmanager -lldsavetemps -out:%t3.dll %t.obj 2>&1 | FileCheck %s --check-prefix=CHECK-O2-SLP
|
|
; RUN: llvm-dis %t.obj.4.opt.bc -o - | FileCheck %s --check-prefix=CHECK-O2-LPV
|
|
|
|
; RUN: lld-link -opt:lldlto=3 -dll -noentry -opt:ltodebugpassmanager -lldsavetemps -out:%t4.dll %t.obj 2>&1 | FileCheck %s --check-prefix=CHECK-O3-SLP
|
|
; RUN: llvm-dis %t.obj.4.opt.bc -o - | FileCheck %s --check-prefix=CHECK-O3-LPV
|
|
|
|
; CHECK-O0-SLP-NOT: Running pass: SLPVectorizerPass
|
|
; CHECK-O1-SLP-NOT: Running pass: SLPVectorizerPass
|
|
; CHECK-O2-SLP: Running pass: SLPVectorizerPass
|
|
; CHECK-O3-SLP: Running pass: SLPVectorizerPass
|
|
; CHECK-O0-LPV-NOT: = !{!"llvm.loop.isvectorized", i32 1}
|
|
; CHECK-O1-LPV-NOT: = !{!"llvm.loop.isvectorized", i32 1}
|
|
; CHECK-O2-LPV: = !{!"llvm.loop.isvectorized", i32 1}
|
|
; CHECK-O3-LPV: = !{!"llvm.loop.isvectorized", i32 1}
|
|
|
|
target datalayout = "e-m:w-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
|
|
target triple = "x86_64-pc-windows-msvc"
|
|
|
|
define dllexport i32 @foo(ptr %a) {
|
|
entry:
|
|
br label %for.body
|
|
|
|
for.body:
|
|
%indvars.iv = phi i64 [ 0, %entry ], [ %indvars.iv.next, %for.body ]
|
|
%red.05 = phi i32 [ 0, %entry ], [ %add, %for.body ]
|
|
%arrayidx = getelementptr inbounds i32, ptr %a, i64 %indvars.iv
|
|
%0 = load i32, ptr %arrayidx, align 4
|
|
%add = add nsw i32 %0, %red.05
|
|
%indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
|
|
%exitcond = icmp eq i64 %indvars.iv.next, 255
|
|
br i1 %exitcond, label %for.end, label %for.body, !llvm.loop !0
|
|
|
|
for.end:
|
|
ret i32 %add
|
|
}
|
|
|
|
!0 = distinct !{!0, !1}
|
|
!1 = !{!"llvm.loop.unroll.disable", i1 true}
|