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
77 lines
3.5 KiB
LLVM
77 lines
3.5 KiB
LLVM
;
|
|
; Here all the branches are exiting ones. Checking that we dont have
|
|
; exponential behavior with any kind of controlling heuristics here.
|
|
;
|
|
; There we should have just a single loop.
|
|
;
|
|
; RUN: opt < %s -enable-unswitch-cost-multiplier=true \
|
|
; RUN: -unswitch-num-initial-unscaled-candidates=0 -unswitch-siblings-toplevel-div=1 \
|
|
; RUN: -passes='loop(simple-loop-unswitch<nontrivial>),print<loops>' -disable-output 2>&1 | FileCheck %s --check-prefixes=LOOP1
|
|
;
|
|
; RUN: opt < %s -enable-unswitch-cost-multiplier=true \
|
|
; RUN: -unswitch-num-initial-unscaled-candidates=0 -unswitch-siblings-toplevel-div=8 \
|
|
; RUN: -passes='loop(simple-loop-unswitch<nontrivial>),print<loops>' -disable-output 2>&1 | FileCheck %s --check-prefixes=LOOP1
|
|
;
|
|
; RUN: opt < %s -enable-unswitch-cost-multiplier=true \
|
|
; RUN: -unswitch-num-initial-unscaled-candidates=8 -unswitch-siblings-toplevel-div=1 \
|
|
; RUN: -passes='loop(simple-loop-unswitch<nontrivial>),print<loops>' -disable-output 2>&1 | FileCheck %s --check-prefixes=LOOP1
|
|
;
|
|
; RUN: opt < %s -enable-unswitch-cost-multiplier=true \
|
|
; RUN: -unswitch-num-initial-unscaled-candidates=8 -unswitch-siblings-toplevel-div=8 \
|
|
; RUN: -passes='loop(simple-loop-unswitch<nontrivial>),print<loops>' -disable-output 2>&1 | FileCheck %s --check-prefixes=LOOP1
|
|
;
|
|
; RUN: opt < %s -enable-unswitch-cost-multiplier=false \
|
|
; RUN: -passes='loop(simple-loop-unswitch<nontrivial>),print<loops>' -disable-output 2>&1 | FileCheck %s --check-prefixes=LOOP1
|
|
;
|
|
;
|
|
; RUN: opt < %s -enable-unswitch-cost-multiplier=true \
|
|
; RUN: -unswitch-num-initial-unscaled-candidates=0 -unswitch-siblings-toplevel-div=1 \
|
|
; RUN: -passes='loop-mssa(simple-loop-unswitch<nontrivial>),print<loops>' -disable-output 2>&1 | FileCheck %s --check-prefixes=LOOP1
|
|
;
|
|
; RUN: opt < %s -enable-unswitch-cost-multiplier=true \
|
|
; RUN: -unswitch-num-initial-unscaled-candidates=0 -unswitch-siblings-toplevel-div=8 \
|
|
; RUN: -passes='loop-mssa(simple-loop-unswitch<nontrivial>),print<loops>' -disable-output 2>&1 | FileCheck %s --check-prefixes=LOOP1
|
|
;
|
|
; RUN: opt < %s -enable-unswitch-cost-multiplier=true \
|
|
; RUN: -unswitch-num-initial-unscaled-candidates=8 -unswitch-siblings-toplevel-div=1 \
|
|
; RUN: -passes='loop-mssa(simple-loop-unswitch<nontrivial>),print<loops>' -disable-output 2>&1 | FileCheck %s --check-prefixes=LOOP1
|
|
;
|
|
; RUN: opt < %s -enable-unswitch-cost-multiplier=true \
|
|
; RUN: -unswitch-num-initial-unscaled-candidates=8 -unswitch-siblings-toplevel-div=8 \
|
|
; RUN: -passes='loop-mssa(simple-loop-unswitch<nontrivial>),print<loops>' -disable-output 2>&1 | FileCheck %s --check-prefixes=LOOP1
|
|
;
|
|
; RUN: opt < %s -enable-unswitch-cost-multiplier=false \
|
|
; RUN: -passes='loop-mssa(simple-loop-unswitch<nontrivial>),print<loops>' -disable-output 2>&1 | FileCheck %s --check-prefixes=LOOP1
|
|
;
|
|
;
|
|
; Single loop, not unswitched
|
|
; LOOP1: Loop at depth 1 containing:
|
|
; LOOP1-NOT: Loop at depth 1 containing:
|
|
|
|
declare void @bar()
|
|
|
|
define void @loop_simple5(ptr %addr, i1 %c1, i1 %c2, i1 %c3, i1 %c4, i1 %c5) {
|
|
entry:
|
|
br label %loop
|
|
loop:
|
|
%iv = phi i32 [0, %entry], [%iv.next, %loop_latch]
|
|
%iv.next = add i32 %iv, 1
|
|
;; disabling trivial unswitch
|
|
call void @bar()
|
|
br i1 %c1, label %loop_next1, label %exit
|
|
loop_next1:
|
|
br i1 %c2, label %loop_next2, label %exit
|
|
loop_next2:
|
|
br i1 %c3, label %loop_next3, label %exit
|
|
loop_next3:
|
|
br i1 %c4, label %loop_next4, label %exit
|
|
loop_next4:
|
|
br i1 %c5, label %loop_latch, label %exit
|
|
loop_latch:
|
|
store volatile i32 0, ptr %addr
|
|
%test_loop = icmp slt i32 %iv, 50
|
|
br i1 %test_loop, label %loop, label %exit
|
|
exit:
|
|
ret void
|
|
}
|