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
63 lines
2.2 KiB
LLVM
63 lines
2.2 KiB
LLVM
; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx908 -stop-after=amdgpu-isel -o - %s | FileCheck -check-prefix=GCN %s
|
|
define void @test(i1 %c0) #1 {
|
|
; Clean up the unreachable blocks introduced with LowerSwitch pass.
|
|
; This test ensures that, in the pass flow, UnreachableBlockElim pass
|
|
; follows the LowerSwitch. Otherwise, this testcase will crash
|
|
; immediately after the instruction selection due to the incomplete
|
|
; PHI node in an MBB whose incoming values were never codegenerated.
|
|
;
|
|
; GCN-LABEL: name: test
|
|
; GCN: bb.{{[0-9]+}}.entry:
|
|
; GCN: bb.{{[0-9]+}}.Flow1:
|
|
; GCN: bb.{{[0-9]+}}.entry.true.blk:
|
|
; GCN: bb.{{[0-9]+}}.entry.false.blk:
|
|
; GCN: bb.{{[0-9]+}}.switch.blk:
|
|
|
|
; GCN-NOT: bb.{{[0-9]+}}.preheader.blk
|
|
; GCN-NOT: bb.{{[0-9]+}}.pre.false.blk:
|
|
; GCN-NOT: bb.{{[0-9]+}}.unreach.blk:
|
|
; GCN-NOT: PHI
|
|
|
|
; GCN: bb.{{[0-9]+}}.Flow:
|
|
; GCN: bb.{{[0-9]+}}.UnifiedReturnBlock:
|
|
entry:
|
|
%idx = tail call i32 @llvm.amdgcn.workitem.id.x() #0
|
|
br i1 %c0, label %entry.true.blk, label %entry.false.blk
|
|
|
|
entry.true.blk: ; preds = %entry
|
|
%exit.cmp = icmp ult i32 %idx, 3
|
|
br i1 %exit.cmp, label %switch.blk, label %exit
|
|
|
|
entry.false.blk: ; preds = %entry
|
|
unreachable
|
|
|
|
switch.blk: ; preds = %entry.true.blk
|
|
switch i32 %idx, label %preheader.blk [
|
|
i32 0, label %exit
|
|
i32 1, label %exit
|
|
i32 2, label %exit
|
|
]
|
|
|
|
preheader.blk: ; preds = %switch.blk
|
|
%pre.exit = icmp ult i32 %idx, 5
|
|
br i1 %pre.exit, label %unreach.blk, label %pre.false.blk
|
|
|
|
pre.false.blk: ; preds = %preheader.blk
|
|
%call.pre.false = tail call i32 @func(i32 %idx) #0
|
|
br label %unreach.blk
|
|
|
|
unreach.blk: ; preds = %preheader.blk, %pre.false.blk
|
|
%phi.val = phi i32 [ %call.pre.false, %pre.false.blk ], [ poison, %preheader.blk ]
|
|
store i32 %phi.val, ptr poison
|
|
unreachable
|
|
|
|
exit: ; preds = %switch.blk
|
|
ret void
|
|
}
|
|
|
|
declare i32 @llvm.amdgcn.workitem.id.x() #0
|
|
declare i32 @func(i32)#0
|
|
|
|
attributes #0 = { nounwind readnone }
|
|
attributes #1 = { nounwind }
|